Internationalisation

From Jmol
Revision as of 13:31, 30 August 2008 by AngelHerraez (talk | contribs) (link to status in body)
Jump to navigation Jump to search
Jmol/JSmol Development

Jmol Internationalisation and Localisation

Several pieces of Jmol can be translated into your local language:

You can check the current status of translations.



Translating this Wiki

The articles in this Wiki can be translated into your own language.

The explanation below will take two different situations:

  • When the page you want to translate is already translated into an other language.
  • When the page you want to translate is not translated into any other language.

We will suppose in the explanation that you want to translate a page named English_Page into XXXXX (language code: xx).


Page already translated into an other language

  • In the Template namespace, edit the existing page Lang:English_Page, add your language in it and save the page:
----
{| border="0" cellspacing="1"
|-
! valign="middle" | [[Image:Geographylogo.png]]
| valign="middle" align="left" | <span style="font-size:smaller">
Reference:
'''[[English_Page|English]]''' – 
Other:
<!--es-->[[English_Page/es|Español]] · 
<!--fr-->[[English_Page/fr|Français]] · 
<!--xx-->[[English_Page/xx|XXXXX]] · 
</span>
|}
----
  • Edit the English_Page to have the source code of the page, copy the entire source code (Ctrl+A, Ctrl+C) and cancel the page editing.
  • Start editing the page in your language (English_Page/xx), paste the source code (Ctrl+V) and then translate the page.


Page not translated into any other language

  • Edit the template page (Template:Lang:English_Page) and initialize it:
----
{| border="0" cellspacing="1"
|-
! valign="middle" | [[Image:Geographylogo.png]]
| valign="middle" align="left" | <span style="font-size:smaller">
Reference:
'''[[English_Page|English]]''' – 
Other:
<!--xx-->[[English_Page/xx|XXXXX]] · 
</span>
|}
----
  • Edit the English_Page, insert {{Lang:English_Page}} at the beginning, copy the entire source code (Ctrl+A, Ctrl+C) and save the page.
  • Start editing the page in your language (English_Page/xx), paste the source code (Ctrl+V) and then translate the page.


Translating the application/applet

In Jmol version 10.00.12 we changed from an unhandy (but well-known) translation process to a more powerful one using GNU's gettext suite. The following paragraphs contain a detailed explanation of this process. More documentation is available here.

See the current status of the translations.

Participating in the translation of the application or the applet can be achieved in several ways:


Geographylogo.png

Reference: English – Other: 日本語 ·


  • Online: by editing directly the translation through Launchpad web site. You just need to register but no installation is required.
    • Description needs to be completed when everything is setup on the Launchpad web site

Geographylogo.png

Reference: English – Other: 日本語 ·


Translation of the Export to Web module

Although this module is part of the application, and therefore instructions above are applicable, there are some special characteristics that call for some precautions and a partially different procedure.



Translating the Applet-, User- and Developers-Guide

The guides are written in XML. ...


1. First install and download:

Note for Linux users: Linux users should ALWAYS try to use their package management to install (software-)packages.

Note for Windows users: Windows users MUST add an environment variable PYTHON_PATH, which contains the directory where you installed Python, e.g. set PYTHON_PATH=C:\Program Files\Python24.

Now you are done with the prerequisites.


2. All targets related to internationalisation and localisation of the documentation are part of File icon.gifbuild-doc-i18n.xml. To create PO-template files, run ant -f build-doc-i18n.xml create-pot. All File icon.gifJmol*Guide.LANG.po files (which contain the translation and are maintained by the translator himself) are updated with ant -f build-doc-i18n.xml update-po. To create the final (translated) XML file File icon.gifJmol*Guide_LANG.docbook.xml, run ant -f build-doc-i18n.xml update-xml.


3. To create a translation in your language, go to doc/source/po and copy File icon.gifJmol*Guide.pot to File icon.gifJmol*Guide.LANG.po - LANG means your language code: e.g. de for German, fr for French and so on.


4. The rest is similar to the above Howto.



Translating the Jmol and FAH websites

... to write