Translation
Available Translations are
Language | Code | Remark |
---|---|---|
English | en | default language |
French | fr | |
German | de | |
Hungarian | hu | |
Italian | it | |
Polish | pl | |
Romanian | ro | |
Russian | ru | |
Spanish | es | |
Tamil | ta | not complete |
Telugu | te | update required |
Singalese | si | Only chart graphics |
Language Setup
Windows: Open the configuration dialog/tab general. Chose the language from the choice box. Restart the program.
Linux/OS x, BSD: you must configure the environment variable LANG. The required command on the (Bash-) shell looks like
export LANG = de_DE.UTF-8
Examples for supported languages are
Language | LANG |
---|---|
English (default) | en_US.UTF-8 |
German | de_DE.UTF-8 |
Polish | pl_PL.UTF-8 |
Russian | ru_RU.UTF-8 |
Telugu | te_IN.UTF-8 |
Please restart the application after changing the language.
How to Translate the Program
Translation of the program is done with GNU gettext. There are free translation tools that make translation easy.
First Steps
Find out the correct language code (iso code) of your language. There is a 2 letter short code for almost every language, e.g. de for German language, etc. A list of these codes can be found in the Gettext Documentation.
Getting the PO File
The required PO file is
- maitreya[version].pot: if you want to create a new translation
- [lang].po: if you want to modify a translation that already exists
The PO file is part of the source code release. e.g. the file maitreya[version].zip that can be downloaded from the source code distribution. It can be found in the directory "po".
It can also be downloaded from the Github source code repository. The root URL of the repository is http://github.com/martin-pe/maitreya8/tree/master/po.
Configuration on Windows Systems
Quit the program if it is running.
Open the configuration file which is located in in the configuration directory, see the Directory Layout chapter. Find the key General/langList. Add the code of your language with space separation.
Start the program and open the configuration dialog. Your language should be visible in the language list.
Make a new directory named like the code of your language in the program's folder, e.g. c:Program FilesMaitreyaLANG.
Copy the file maitreya8.pot to that directory an rename it to LANG.po.
Configuration on Linux/Unix Systems
Go to the po directory of the source code tree. Edit the file LINGUAS and add the code of your language. Copy the file maitreya8.pot to lang.po. Go to the root or the source tree and type
automake && autoconf && configure && make
The compiler will complain about missing header entries. Add these entries and try again.
Note: if you want to test your translation from the source code tree: create a directory named like the language code in the gui directory. Go into that directory and link the gmo file to maitreya8.mo, e.g. ln -s ../../po/lang.gmo maitreya8.mo.
Write the Translation
Get a po file editor like poEdit or KBabel (available as package on most Linux/Unix systems).
Open the LANG.po file and translate the messages. There about 1000 messages. Compile the message catalogue to lang/maitreya8.mo (Windows) or lang.gmo (Linux/Unix) and test your translation.
You are encouraged to publish your translation for the benefit of the community.
Note: Non European languages should use a Unicode character set (UTF-8).