Translation

Revision 7 as of 2005-09-16 14:21:20

Clear message

Introduction

This page is a description of how the Documentation Team work gets translated and inserted into Ubuntu. It is primarily intended for reference of the Documentation Team: translators do not need to know all this information.

If you are a translator, and are interested in helping out translating the Ubuntu documentation into your language, all you need to know is how to use the [http://launchpad.net/rosetta Rosetta translation system]. You can find out how to use that on the ["Rosetta"] wiki page. Once you have learnt all of this, the docteam documents can be found [https://launchpad.net/products/ubuntu-doc here] (don't forget to login).

Package Requirements

  • gnome-doc-utils
  • gettext

Process

  1. When English XML document is ready for translation, make a POT file. We use the command xml2po -e -o output.pot input.xml.

  2. The pot file should then be uploaded to rosetta. This is done automatically if the pot is in a source deb package uploaded into the current version of Ubuntu, if not, it must be done manually with the help of the Rosetta Administrators.
  3. Documents are translated via the [http://launchpad.net/rosetta Rosetta] interface.

  4. Automatic exporting from Rosetta into the docteam tree is not implemented, and it seems that it will be difficult to implement it in the future. Therefore a member of the docteam will check the status of translations in the documents and when they are ready, export them from Rosetta and commit them to the relevant section of the Docteam Repository.
  5. The po files come in the format cc.po, where cc is the [http://www.w3.org/WAI/ER/IG/ert/iso639.htm two letter language code]. These can be converted back to xml using the command xml2po -p cc.po path/to/original/document.xml > path/to/translated/document-cc.xml

File Naming Convention

  • English document names may contain one hyphen. Example:
    • Correct "xxx-xxx.xml" "release-notes.xml
    • Incorrect "xxx-xxx-xxx.xml"
  • POT file name is same as English filename but with .pot extension. Example:
    • Correct "xxx-xxx.pot" "release-notes.pot"
    • Incorrect "xxx-xxx-xxx.pot"
  • PO file name must be in the following format
    • Correct "nn.po" (where nn = two letter country code) e.g. "fr.po"
    • Incorrect "xxxxxx-nn.pot"

Note::

Problems

Some of the following problems may be encountered while using Rosetta as a translating interface. We are hoping that Rosetta will be a suitable way of getting Docteam documentation translated by the maximum number of people, but it is normal that we will have some teething problems, which may be solved by amending our make pot / make po scripts or by filing bugs with the Rosetta guys. If you come across an error which isn't listed here, please list it here and report it to the [mailto:ubuntu-doc@lists.ubuntu.com Docteam] and [mailto:rosetta-users@lists.ubuntu.com Rosetta-users] lists.

  • PO file may contain syntax errors. These are shown when running make-po script. For example:

msgfmt: releasenotes/release-notes-fr.po: some header fields still have the initial default value
msgfmt: releasenotes/release-notes-fr.po: warning: PO file header fuzzy
                                          warning: older versions of msgfmt will give an error on this
msgfmt: found 1 fatal error
124 translated messages.
  • In this case:
  • Check that the header has been modified. Sometimes people forget to complete the "Last-Translator" field.
  • Strip the line #, fuzzy from the file.
  • Locate and resolve any fatal message string errors.
  • Languages such as German have special characters such as ü and ß. Instead of using the "Entity" use the "Decimal." For example: replace ß with ß. Use [http://zvon.org/other/charSearch/PHP/search.php] to resolve an "Entity" to a "Decimal."

How to check a translation when another language is installed

sudo dpkg-reconfigure locales

Choose the locale of your choice. Then :

LANG=<locale>
yelp ghelp:about-ubuntu

Replace about-ubuntu by either document of your choice.

Todo

  • Translation of screenshots - The current method that we have for doing this is to install the relevant language packs and to take the screenshots manually (see TakingScreenshots). This is obviously not the easiest way, so any suggestions are welcome. Thanks!


CategoryDocteam