Translation Portal
This page describes the xTuple Translation Portal--a tool for translating the xTuple ERP user interface--and provides instructions for:
Contents
-
Translation Portal
- Getting a Translation File
-
Translator Help
- How does the Translation Portal work?
- How do I become a translator for xTuple?
- How do I start a new language?
- What version should I work on?
- What is a context? What is a source?
- Why do some sources require special characters? (“&” and “...”)
- What do I do if I make a mistake in the translation?
- How do I become a Translation Manager?
- Translation Manager Help
Getting a Translation File
How do I get a language translation file?
To obtain a translation file, go to the Translation Portal web page and log in to the site. You'll see a section titled "Download translation file (.qm)." Select the language you want and the version of xTuple ERP that you are using and click "Download .qm file." The file will be saved to your computer.
How do I use a translation (.qm) file?
To use it, you'll need to place the .qm file in the same folder as your xTuple ERP executable file. The exact location of the .qm file varies slightly depending on your operating system. The following screenshot shows how a sample Spanish .qm file ("xTuple.es.qm") should be located next to the xTuple ERP executable file ("xtuple.exe") under Windows:
Placing .QM File on Windows
Placing the .qm file on a Mac requires a few simple steps:
- Right-click on the xTuple application icon
- Select the "Show Package Contents" option
- Open the MacOS folder
- Place the .qm file in the MacOS folder
The following screenshots illustrate how to place a .qm file on a Mac:
xTuple Application Icon on Mac
Right-click To Reach "Show Package Contents"
Package Contents for xTuple Application
Placing .QM File in MacOS Folder
What are Locales? And how do they work?
Locales are associated with users and define the format for date, time, and numbers. Locales are also used to search for translation files and to specify decimal precision and some of the colors that the user sees on the screen. You can read more about Locales in the Reference Guide section on Locales.
You need to understand how Locales work if you want to use the translation (.qm) files generated by the Translation Portal. If you do not get the results you expect, it is likely there are problems with your Locale setup. It is also possible you renamed the .qm file you downloaded from the Translation Portal. For best results, you should not rename the translation (.qm) file.
The setup for Locales can be found in the System > Master Information section of xTuple ERP. The following screen shows a sample list of Locales:
Sample Locales Master List
Two fields on the Locale setup are especially important to consider: Language and Country. Here are some points to remember when you are trying to figure out which Locale settings to use:
Language: If you are using a generic language file (i.e., generic French xTuple.fr.qm or generic Spanish xTuple.es.qm), then the language field is the only field you need to set. The country field should remain as "Any" when using generic language files. So, in these examples, you would set the language to either "French" or "Spanish; Castilian" and the country would be "Any."
Country: The country setting is important if the language is specific to a particular country. A good example for this is Canadian French. In this case, the language field should be set to "French" and the country field set to "Canada." Accordingly, the translation (.qm) file is constructed differently if the language is specific to a particular country. The following examples illustrate how the .qm files differ for generic French and Canadian French
xTuple.fr.qm: This is generic French. Notice how the only indicator is the "fr" in the name. xTuple uses the ISO standard two-letter language codes when it builds .qm files.
xTuple.fr_ca.qm: This is Canadian French. Notice how the country indicator "ca" follows directly after the "fr" language indicator. xTuple uses the ISO standard two-letter country codes when it builds .qm files.
Sample Locale for Generic Language
Sample Locale for Country-Specific Language
Finally, once the Locale is defined, you must link the Locale to your system user. To link your user with a Locale, go to System > Maintain Users. Simply select the Locale you want to link to your user from the drop-down list, as shown in the next screenshot:
Linking User to Locale
You must log out/log in before you will see changes to the Locale linked to your user.
How do translation files work?
Qt allows you to load language translation files into an application at run-time. The result is that application text (i.e., screen titles, field labels, help files, etc.) will be displayed in the language of the translation file. Qt handles this internally by using a tr() function. This function wraps any literal text found in an application and allows for dictionary lookup and replacements to be performed at run time. These tr()'s are also used to identify text needed to build the translation files.
There are two files used for the translation process:
- the first is a .ts file
- the second is a .qm file.
The .ts file is the translation source files. This file is an XML based file which can be updated and edited using the lupdate and Qt Linguist tools. Every instance of text in an application that is translated has its own context, source, and translation field. The context changes usually from screen-to-screen and allows you to have two identical texts translated differently in different contexts. The translation field includes the text you want to show in place of the source text for a given context.
The .qm file is created from the .ts file using the lrelease tool and is a more compact and efficient file used by the application at run-time. Once the .qm file is generated, the OpenMFG application can be made to use it simply by using the system's Locale configuration. In practice, when a user logs into OpenMFG using a specified Locale, the language (i.e., translation) corresponding to that Locale will be displayed. In addition, the application supports the placement of a translation file called default.qm in the same directory as the executable. If a system is set up this way, OpenMFG will use that default file and no additional configuration will be required. When do I use “Override Warnings”? If you receive a warning when you submit a translation, you may have missed a required character, such as ampersand or ellipsis. Check to make sure you have included these characters if they are required. There may be cases where the warnings are incorrect for the specific language you are translating, in which case you should check the Override Warnings box and submit the translation again.
Translator Help
How does the Translation Portal work?
The xTuple Translation Portal is designed to allow multiple users to edit a translation file at the same time.
- Users first select the language and the xTuple product version they wish to translate.
- The next screen shows all the sections of the product and allows the translator to select specific sections (called "contexts") to work on.
- Once a translation is complete, users can download the translation file for that language and install it on their local machine. A translation file is called a .qm file.
How do I become a translator for xTuple?
If you are interested in helping to translate, please sign up for an xTuple.org account and then email us at <translate@xtuple.com>. Tell us your username and we'll set you up as an authorized translator. Translators will find the TranslationGlossary helpful for finding explanations for unfamiliar words/terms.
How do I start a new language?
If you don't see your language in our list of current translation projects--and you'd like to volunteer to start a new one--please email us at <translate@xtuple.com>. We are open to hosting any and all language projects, but we need to hear from you by email first....
To learn more about the process for starting a new translation project, please see the StartingNewTranslation page.
What version should I work on?
Generally you should work on translating the most current version of the software. xTuple regularly releases updates to our products, identified by version numbers. Each version may contain new sections or changes to old sections. Generally, translators should translate the most recent version of the product, but if your installation uses an older version of the product you may want to work on translating that version.
What is a context? What is a source?
Within the Translation Portal you will see references to "contexts" and "sources."
A context is a section of the software, such as BOM (Bill of Materials). A context will contain text related to the specified section.
A source is a specific item of text within a context, e.g., the “Bill of Materials” context contains 56 sources, including “Print”, “Save”, “Revision Date”, etc.
Why do some sources require special characters? (“&” and “...”)
As you view each source you will notice that some sources contain special characters, such as the ampersand (&) and the ellipsis (…). These are used by the program to identify hotkeys. For example, the source &Print is text that would appear in a dropdown menu. The & would not appear on the screen, but it allows the program to target the menu with a hotkey. The & character is used in menu items and commands, not in explanatory text. If there is a special character in the source, it must be maintained in the translation.
What do I do if I make a mistake in the translation?
If you make an error in your translation, just correct the error in the translation field and submit it again.
How do I become a Translation Manager?
If you are interested in receiving manager privileges (the ability to review and approve translations submitted by translators), please send a request to <translate@xtuple.com>. We'll review the request and get back to you.
Translation Manager Help
