| 1 |
Guide to writing fre:ac language files |
| 2 |
-------------------------------------- |
| 3 |
|
| 4 |
People had some problems writing new language files for fre:ac in the past. Most |
| 5 |
were related to the text encoding in the language files. |
| 6 |
|
| 7 |
The language files and items |
| 8 |
---------------------------- |
| 9 |
|
| 10 |
If you are doing a completely new translation, you can take the freac.xml file as |
| 11 |
a starting point. It includes all the strings that need to be translated for fre:ac. |
| 12 |
|
| 13 |
The Changes file provides information about which entries have been updated since the |
| 14 |
last release. So if you are updating a translation, you know where to look at. |
| 15 |
|
| 16 |
Character encoding |
| 17 |
------------------ |
| 18 |
|
| 19 |
The preferred encoding to use in fre:ac language files is UTF-8 (Multibyte Unicode). |
| 20 |
UTF-8 allows all characters of the 7-Bit ASCII charset plus all special characters |
| 21 |
of some European languages like the German umlauts or the 'sz' character and all |
| 22 |
characters used in Asian languages (Kanji, Kana, etc). |
| 23 |
|
| 24 |
If you cannot use UTF-8 for some reason, you can use nearly any charset you like. |
| 25 |
For Western European languages, you should use ISO-8859-1 or ISO-8859-15. |
| 26 |
|
| 27 |
Hint: The 'NotePad' of Windows XP and later supports UTF-8 and UCS-2. When you click |
| 28 |
'Save as...' you can select the encoding to be used to save the file. |
| 29 |
|
| 30 |
If you use a different charset than UTF-8, you need to change the first line of the |
| 31 |
XML file. It usually is: <?xml version="1.0" encoding="UTF-8"?> |
| 32 |
Replace UTF-8 with whatever encoding you used in the file. |
| 33 |
|
| 34 |
If you use 16 or 32 bit Unicode (UCS-2, UCS-4), you should specify if the file is |
| 35 |
big endian or little endian and write UCS-2BE or UCS-2LE. |
| 36 |
|
| 37 |
The 'info' node |
| 38 |
--------------- |
| 39 |
|
| 40 |
The 'info' node of the language file includes meta information about the language |
| 41 |
and author of the file. |
| 42 |
|
| 43 |
The 'program' field must always be 'freac', the 'version' field should be the |
| 44 |
version number of the fre:ac release you tested the file with. |
| 45 |
|
| 46 |
The 'language' field contains the language name in the English and local form. I.e. |
| 47 |
for a German translation this field would contain the string 'German / Deutsch'. You |
| 48 |
can append other information to the language name (like 'Spanish (Latin American)'). |
| 49 |
The whole string will be displayed in fre:ac. |
| 50 |
|
| 51 |
The 'righttoleft' field specifies how the application windows and dialogs will be |
| 52 |
laid out. Possible values are 'true' for right-to-left scripts like Arabic and 'false' |
| 53 |
for left-to-right scripts as in most Latin or Asian languages. |
| 54 |
|
| 55 |
The 'encoding' field should contain the name of the encoding used in the file. The |
| 56 |
same as in the first line of the XML file. |
| 57 |
|
| 58 |
The 'author' field should contain the name of the translator. You can append additional |
| 59 |
information like your eMail address. |
| 60 |
|
| 61 |
The 'url' field can contain the address of the translators personal homepage. If you |
| 62 |
do not have a homepage, you should set it to 'https://www.freac.org'. |
| 63 |
|
| 64 |
The smooth Translator utility |
| 65 |
----------------------------- |
| 66 |
|
| 67 |
The smooth Translator can be used to create and edit language files. It supports full |
| 68 |
Unicode on Windows XP and later and automatically saves in UTF-8 on all systems. |
| 69 |
|
| 70 |
|
| 71 |
Robert Kausch, |
| 72 |
<[email protected]> |