Translating SARTrack
Information for translators of the SARTrack Terminal and the SARTrack Database Server. Thank you for helping!
How it works
SARTrack and the Database Server read their texts from a translation file for each language. You translate this file with the free program PoEdit. Please first contact info@sartrack.nz: I will e-mail you the file to start with, named default.po.
1. Put the file in the right folder
The translation files live in the locale folder:
- SARTrack Terminal:
C:\Users\<your Windows account>\AppData\Roaming\SARTrack\exe2\locale\
The quickest way there: type%APPDATA%\SARTrack\exe2\localein the address bar of File Explorer. You can also open%APPDATA%\SARTrackfrom SARTrack itself: Setup, the Tools tab, Open Application Directory. - Database Server: the
localefolder in the Server's program folder.
The AppData folder is hidden in Windows. To see it while browsing, switch on Hidden items in File Explorer's View menu.
In the locale folder, make a folder with your language code, and in that folder a folder named
LC_MESSAGES. For Dutch (code nl) the result is:
%APPDATA%\SARTrack\exe2\locale\nl\LC_MESSAGES\
The language code is usually 2 characters, sometimes more. Find yours in this list: languagecodes.txt.
Then copy the default.po file into the LC_MESSAGES folder.
2. Install PoEdit
Download the latest PoEdit from poedit.net/download and install it. I recommend the Pro version: it offers many ready-made translations from the Internet, which makes the work much easier.
Double-click the .po file to open it in PoEdit. The first time, fill in the Catalog Properties:
- Project name: a suitable name.
- Language: your language.
- Plural forms: leave as it is.
- Team: your name.
- Team's e-mail address: the e-mail address to use for translation matters.
- Charset and Source code charset: UTF-8.
Click OK, then Save. You are ready to start translating. When you save, PoEdit also writes the .mo file next to the .po file: that is the file SARTrack reads.
3. Important when translating
Select an entry, and PoEdit shows the Notes for Translators (bottom right). These tell you where the text is used in SARTrack, sometimes with a note from me.
- ..Caption: a fixed-size text or a button (..Button..Caption) in a SARTrack window. Your translation must fit in the space available. If there is no way to make it fit, please contact me and I will try to make the space or the button larger.
- ..Hint: the text shown when the mouse is over a button or another control. The hint grows with the text, so the translation can be longer or shorter.
- One word, many places: a word such as "Cancel" is used in many places, and your translation is used in all of them. When the Notes for Translators show many places, please check that the text fits in each one.
- Spaces: when the text starts or ends with spaces, your translation must have the same spaces.
- Line breaks: each
\nin a text is a new line, for exampleLine one\nLine two. Your translation must have the same line breaks.
Start with the Main Menu: it shows up as SARTrackForm2 in the Notes for Translators.
4. See the result in SARTrack
- Save in PoEdit.
- In SARTrack, choose your own language: Setup, the General tab, Change Language. In the Database Server: Setup, Change Language. Choosing the language again also reloads the file.
Optional: a Reload Language button in SARTrack's Debug window refreshes every window with your latest
translation at once. To get the button, save an empty file named language.ini in
%APPDATA%\SARTrack\, then restart SARTrack. (In Notepad, choose All Files when saving, or it
becomes language.ini.txt.) The Debug window is in the About box: the bottom button of the Main Menu.
If something doesn't work, please let me know.
5. Send it back
Please e-mail your translated .po file to info@sartrack.nz.
Updates of the texts
SARTrack keeps developing, and now and then new texts are added. I will then e-mail you the new template file, sartrack.pot or sartrackserver.pot. Merge it into your translated file: in PoEdit choose Translation > Update from POT File (older versions: Catalogue > Update from POT file) and open the .pot file. The new texts then show up, ready to translate. Please don't mix up the SARTrack and Database Server files.
Thanks for your support,
Bart Kindt
Developer
