User:Claus chr/Translation

From KDE UserBase Wiki
Revision as of 11:47, 9 August 2012 by Claus chr (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Translating templates

Information

This is just an example of template usage


In these pages we use a number of templates. You saw one example in the info box above. It was entered this way:

{{Info|1=This is just an example of template usage}}

The content between "1=" and "}}" is simply translated like any other text. However, some templates (like the one above) also contain text as part of the template itself. To translate that you have to do the following:

  1. Add your language code (lg in this example) to the name of the template like this
    {{Note/lg|...}}
  2. When you save the translation, a red link will appear instead of the template. Click that to start editing the translated template.
  3. Find the definition of the original template. This can be done as follows
    1. Go to the English version of the page you are translating
    2. Open it for editing (click the edit button on the top right of the page)
    3. Move below the buttons under the editing field. There you'll see a list of templates used in this page
    4. Find the template in question and click the edit link (in paranthesis - the link text may be translated)
  4. Copy the content of the original template into the translation of the template
  5. Translate the text. You should also change [[Category:Template]] to [[Category:Template/lg]]
  6. Save the translated template and close the editing boxes of the original template and the original page without saving!

Translated units are marked as fuzzy

Sometimes it may happen that you have translated a page, but the translation is marked as incomplete. Certain errors in the markup of the original page can cause this. The most common type of error is the appearance of unbalanced brackets or parentheses. The translation system requires that alle opening brackets ('[', '{' or '(' ) have a matching closing bracket (']', '}' or ')' ) in the same translation unit, otherwise the translation is considered incomplete.

The same rule is not enforced by the wiki software, so it is easy for writers to miss those mistakes. If a bracket characte is simply missing, just add it. However, sometimes the bracketed content extends over more than one translation unit, so that the matching closing bracket is in later unit. In this case you need to balance brackets in both units, but you can't simply add bracket characters without changing the meaning or formatting, so you must must comment out the added bracket character, like this

{{Info|1=Beginning of long info box... <!--}}-->

and in a later unit

<!--{{--> ...end of long info box}}

If the offending bracket is part of a smiley, you can replace it with an emoticon icon. For the standard smiley, :-), you can use the template {{Smiley}}

Please also correct the original page so other translators won't have the same problem, or leave a message on the discussion page.