Multilingual text constants
T("…", …)
The processing of texts in ClassiX is generally multilingual. The corresponding objects store a single string for each language and decide which string is output depending on the selected language.
These are maintained by the user via the widgets MLString and MLText. However, if a developer wants to specify such an object in the InstantView code - for example in error messages or other interface texts - this is possible with the help of the keyword T. This is followed by 1 to n strings which refer to the set languages. This is followed by 1 to n strings, which refer to the set languages:
T("textlanguage0", "textlanguage1", ..., "textlanguageN")
Code example:
T("Diese Eingabe war falsch.", "This input was wrong.") Attention(, ERROR) 1 T("De", "En") GetElement // -> "En"
The individual languages of an ML_STRING can be accessed via GetElement or iterate .
A monolingual string in the current language can be created from an ML_STRING using String .
Overwrite
Instead of taking the multilingual text constants from the InstantView® code, they can be redefined using a custom file. The text pair of the first two languages acts as the key. The substitution happens transparently.
The outsourcing of the multilingual texts from the InstantView® code into an external file (see also Text Literal Browser for system messages and the Text Literal for the AppsWarehouse®) is an important part of the internationalization of the Atlas BIT applications.