Skip to main content

iX Developer 2.52

Language Management

iX Developer supports multilingual applications. Translation of texts and system texts can be performed directly in the application, or via export to a text file to be translated in other software. The file is imported to the application after translation.

The application language can be changed in runtime, for example based on a tag value.

Setting Up Multiple Languages

The multiple languages function is included in the application by default and is located in the Functions folder in the Project Explorer.

The multiple languages configuration pages consist of the Texts, System Texts and Languages tabs.

Adding Languages

  1. Click on the Multiple Languages function to open its configuration pages.

  2. Select the Languages tab.

  3. Add languages by selecting them from the drop-down list.

image338.jpeg

The Use in Runtime setting makes the language available in runtime. Under Keyboard Layout, it is possible to select different layouts for the virtual keyboard, used for alphanumerical input in runtime.

Note

The size of the virtual keyboards vary between languages.

Examples of keyboard sizes (the values are approximative)

  • Arabic: 18 MB

  • Chinese - simplified: 12 MB

  • Chinese - traditional: 36 MB

  • Hebrew: 6 MB

  • Korean: 21 MB

  • Latin alphabets: 0.1 MB

Each added language is assigned an index number. Index number 0 is reserved for the default language (the language that the application was first created in).

The Add and Delete buttons can be used to add and delete languages.

The Settings button allows connecting the language to a tag. This makes it possible to change the project language based on a changed value.

Use the Show Selection/Show All button if you want to filter the languages in the current view.

Note

If scripting is done against texts which are mentioned in the Multiple Languages, the value mentioned by scripting can be overridden by the text value in the Multi Language Server.

If the user tries to change the text value through scripting, there is a risk of it being overridden by the values mentioned in the Texts tab in the Multiple Languages screen.

If the user want the value mentioned through the script to have priority, the entry for those texts in the Text column in the Texts tab should be left empty. Make sure to add all multi lingual alternatives in the script.

image339.png

MultiLanguage Font Template Feature

Font templates will allow the user to choose a different font and font scaling for a given language that will then override most texts within a project during runtime. When switching from one language to another, the texts on screen will change to the font and font scaling associated with the language.

Activating the feature

Within the properties window that’s displayed when pressing the settings button under the languages tab, is a “Font Template Settings” section. Under which are 2 check boxes, the first is used to enable the font template generally throughout the project. This will have an effect on most objects during runtime (view limitations). With the first checkbox enabled, a secondary checkbox will become available that is by default checked. Unchecking this will ensure that system dialogs are also affected by the Font Templates.

image340.jpeg

Once the “Enable Font Templates” has been checked in the settings, two columns will be made available in the languages tab (Font and Font Scaling). The font column will provide a drop down menu in which the user can select a font from a list of installed fonts on the local PC. Font Scaling is a percentage value in which the font size can scale up or down (Max increase of 500% and max decrease is -99%.). Notice that scaling up or down will be based on the value given to each object during design time. A positive Font Scaling value will increase the size while a negative value will decrease it.

image341.jpeg

Note

If the font template settings have been enabled for a project containing objects using the Font Size dynamic, then the dynamic setting will take precedence over the font template and as a result switching language will have no effect during runtime for these objects.

Note

User is responsible of ensuring the Font and Font Scaling selected is suitable for the given project.

Limitations

Design Time Limitation:

  • Switching Design Language still functions as previously however Font and Font Scaling set in the Languages tab will have no effect.

Unsupported PC and CE Runtime objects:

  • RollerPanel does not support Font Scaling.

  • MediaPlayer is not supported.

  • PDF Viewer is not supported

Unsupported CE Runtime objects:

  • Windows controls are not supported (except TextBox).

  • TagMonitor is not supported.

  • GroupBox containing windows controls is not supported.

  • Objects using scales is not supported (e.g Linear meter, circular meter).

  • Web browser is not supported

System Texts

Select the System Texts tab in the Multiple Languages configuration pages to edit system texts.

Several pre-installed translations of the system texts are available for selection:

  • English

  • German

  • French

  • Brazilian Portuguese

  • Chinese, traditional

  • Chinese, simplified

image342.jpeg

Use the Show Selection/Show All button if you want to filter the current view.

The Import/Export button can be used to export a system language to a text file for translation, and then import the language after translation.

Note

Regional expressions for time, date, and weekdays are by default equal to the settings in the system account, but can to some extent be changed in the Date, Time and Region Group under the System Ribbon tab.

User Texts

Texts that have been added to objects by the developer are available from the Texts tab in the Multiple Languages configuration pages. The texts in the default language can be edited as well.

image343.jpeg

Use the Show Selection/Show All button if you want to filter the current view.

The Import/Export button can be used to export a system language to a text file for translation, and then import the language after translation.

Note

When an object is connected to a text in the Text library, the object’s internal denomination (that is not displayed in runtime) will be presented in grey color in the Texts list, to indicate that editing the text will not affect the runtime project.

Text ID

The Text ID function is available from the Text IDs tab on the Multiple Languages configuration page.

To enable the Text ID function, check the Text IDs enabled check box on the Text IDs tab.

image344.jpeg

The Text IDs tab consist of the following columns: Text ID, Default Text and one column for each language. The text in the column Default Text corresponds to the default language used in iX Developer.

Clicking Add adds a row with a Text ID that is equal to the highest existing Text ID plus 1.

Use the Show Selection/Show All button if you want to filter the current view.

The Import/Export button can be used to export a system language to a text file for translation, and then import the language after translation.

Text ID Browser

If the Text ID function is enabled, all text box controls in iX Developer, including texts used in iX Runtime, will be replaced with the Text ID browser control.

The Text IDs are accessed from a popup list by clicking the combo box arrow next to the Text ID browser control.

The Text ID browser consists of two tabs, one for using Text ID and one for using Dynamic Text ID.

  • If the requested Text ID text is known in iX Developer, the Text ID tab should be used.

  • If the requested Text ID text is to be decided dynamically in runtime, then the Dynamic Text ID tab should be used.

Text ID

The popup list consist of the following columns: Text ID, Default Text and one column for each language. Right-clicking the column header opens up a context menu that lists all available columns. The context menu offers a possibility to configure which columns to be displayed in the popup list.

image345.png

Parameter

Description

Add

Adds a row with a Text ID that equals to the highest existing

Text ID plus 1

Reset

Removes the Text ID connection and the text falls back to the previously unconnected text

OK

Connects the object text to the selected Text ID

Cancel

Closes the popup list. No changes are made.

When an object is connected to a Text ID, the displayed text in the Text ID browser control will be presented in the following manner:

“Text ID – Text”

Text corresponds to the default language used in iX Developer.

image346.png

When opening the popup list, the text field acts as a filter for the popup list.

The object itself will only show the corresponding text, without Text ID, which is disabled for editing.

When the language in iX Developer or in iX Runtime is changed, a text connected to a Text ID will be updated to the corresponding text entered in the Text IDs tab.

Dynamic Text ID

The Dynamic Text ID tab consist of two tabs — Tags and Aliases — and acts as a normal tag/alias selector.

image347.jpeg

In addition, it is also possible for the graphical components to set a Default Value Used in Design Mode. This value will be displayed in the object in design time, but not be used in runtime.

Parameter

Description

Add

Adds a tag/alias

Reset

Removes the Dynamic Text ID connection and the text falls back to the previously unconnected text

OK

Connects the object text to the selected tag/alias

Cancel

Closes the popup list. No changes are made.

When an object is connected to a tag, the displayed text in the Text ID browser control will be presented as “TagName”, where TagName is the name of the tag.

When an object is connected to an alias, the displayed text in the Text ID browser control will be presented as “#AliasName”, where AliasName is the name of the alias.

When configured, the tag value in runtime represents the key (Text ID) to the Text ID table. The displayed text is the corresponding translation for current language for the given key (Text ID). If the tag value is not found as a key in the Text ID table, an empty text is displayed.

Automatic Translation

iX Developer includes a translation tool that uses Microsoft Translator (www.microsoft.com/translator) or Google Translate (translate.google.com) to offer quick translations of user-defined texts or system texts. Due to license requirements, an account at least one of the translation providers to get the required keys.

Note

Automatic translations provide limited functionality; especially combination of words or words with synonyms may be returned as incorrect translations.

The translation tool is available by clicking Translate on the Texts or System Texts tabs of the Multiple Languages configuration pages. Each language is translated separately.

image348.png

Parameter

Description

Translation Provider

Select translation provider among available providers.

Microsoft Translator Azure Key

Enter your Azure Key.

To gain access to the Microsoft Translator service, sign up for an account on Microsoft Azure and add a subscription to the Microsoft Translator API.

Google user Key

Type a Public API Access Sever key. You need to create a Google Developers account and use the product Google Translate API to get the key.

Save Key

Saves the Microsoft Translator Id and Client Secret or the Google user Key in your user profile on the development PC.

Translatate from

Selection of source language for the translation operation; the default language (reference language) or one of the languages that have been added to the project.

Translate to

Selection of target language for the translation operation.

Reference Language

Select reference language; i.e. the language in which the project was created.

Only translate items that have not yet been translated

Clear the check box to replace also already translated items in the project.

Note

Since the translation tool accesses online translation providers, the translation operation may sometimes be paused or delayed due to an excess of online users.

Exporting Languages

Languages can be exported to a text file for e.g. translation.

  1. Select Export from the Import/Export button.

  2. Specify format, location, delimiter (for text file format) and language selection, and click OK.

image350.png

Parameter

Description

Format

Select format of the exported file; text file or Excel file.

Path

Browse to the location for the exported file

Delimiter

If Text file format was selected, select delimiter from the drop-down list; comma, semicolon, space or tab

Languages

Select which languages to export

The exported file will also include the default language.

Note

To display certain characters (such as Chinese or Arabic) correctly in Excel select Unicode (UTF-8) in the Excel import dialog.

Importing Languages

After translation or other editing, the updated language file can be imported to the project again.

  1. Select Import from the Import/Export button.

  2. Specify location and language selection, and click OK.

image351.png

Parameter

Description

Format

Select format of the file to import; text file or Excel file.

Path

Browse to the location of the file to import

Languages

Select which languages to import

Import Strategy

Selecting Key performs the import according to the Designer and Object columns in the multiple languages configuration page. Reference Text performs the import according to the Text column. If you have changed

the texts of the default language after exporting the languages, it is recommended to select Key.

The imported file will also include the default language.

Note

Make sure to make a backup copy of the project before importing languages, in case there are mismatches between the existing and the imported languages.