Skip to content

How to translate Náboj source files

Kvík edited this page Jun 9, 2021 · 24 revisions

General guidelines

  • Feel free to alter the story of the problems, but keep the solution consistent with your translation.
  • Some stories may include inside jokes or puns.
  • Names of the characters are usually not important, if they do not make sense or are inappropriate in your language, you should change them.
  • Line length should not exceed 80-100 characters, including math and captions. This is mostly to make changes more readily visible in Git.

File properties

Important: always save your files in UTF-8 encoding (this causes many problems if not observed). Use Unix line endings (LF), not Windows (CRLF) nor Macintosh (CR).

Formatting

  • Please keep the spacing around pictures. There should be one empty line before and after the @NP tag:
...as seen in the picture:

![A fancy picture](picture.svg){fig:fancy height=40mm}

Next, we may add...
  • Block math should be attached to the preceding paragraph, but not to the following one. It is considered to be a normal sentence, so it should end with a comma or a full stop.
...we may conclude that
$$
    E = mc^2.
$$

Now we may continue to solving the problem of dark matter, ...
  • The sentence may be continued after a math block. In this case, do not split the paragraph.
...and we arrive at the final result
$$
    a^2 + b^2 = c^2
$$
and this proves Pythagoras was actually right.
  • In math, please break lines before operators (only if the line would be too long otherwise)
$$
    S = \Int[0][2\pi]{r}{r}
      = \pi r^2.
$$

Quotation marks

Please keep quotation marks as " characters (\x22). DeGeŠ will automatically find opening and closing quotation marks and replace them with appropriate symbols for the selected language.

Тинка уже 2 недели валяется на "пляже" в тропических областях.

will be output as Тинка уже 2 недели валяется на «пляже» в тропических областях.

SI units

The siunitx package is configured for every language. You should always use dots . as decimal separators in \SI and \num commands, they will be output correctly in the PDF files. In Russian, keep units as original, they will be output in Cyrillic.

\SI{2.5}{\kilo\gram\per\metre}

will be output as 2.5 кг/м in Russian and 2,5 kg/m in Czech.

TL;DR

Please do translate

  • direct text, wherever applicable
  • picture captions:
![Freddy's supersonic car](supercar.svg}{#fig:freddycar height=40mm}

should become

![Freddieho nadzvukové auto](supercar.svg}{#fig:freddycar height=40mm}

Please do not translate

  • custom tags @E themselves
  • LaTeX commands, such as \text, \left(, \right), \mathrm, \begin{aligned}, \end{aligned}...
  • problem directory names or any file names (problem.md, meta.yaml, picture files...)
  • cross-reference labels, such as {#eq:angles} or [-@fig:wheel]