Many of the messages or strings in Profound UI are configurable for different languages or cultures. You can customize these strings yourself, or even define new languages with configuration options.
Configuring a Language
For example, to set your language to "English, USA" you would code the following:
The following languages are provided with Profound UI:
- en_US = English, USA (default)
- en_UK = English, UK
- de_DE = German, Germany
- pt_PT = Portuguese, Portugal
- pt_BR = Portuguese, Brazil
- es_ES = Spanish, Spain
- es_MX = Spanish, Mexico
- fr_FR = French, France
- fr_CA = French, Canada
- it_IT = Italian, Italy
- nl_NL = Dutch, Netherlands
- zh_HK = Chinese (Traditional) Hong Kong
Setting pui["language"] is all that's necessary for Profound UI to provide text or messages in the language of your choice.
Customizing a Language
Any of the strings that are provided in the language dictionary of Profound UI may be customized. To do that, you can define a string as follows:
For example, to customize the message that occurs when there's no connection to the server in USA English you can code:
This can be set separately for each language. For example, in German you might prefer:
You can find a list of the possible dictionary and message id values under "Defining a new language", below.
Defining a New Language
If Profound UI does not come with your preferred language already defined, you can add a new language yourself by coding all of the needed strings as configuration settings. To do that, your settings file should set the language you wish to use. You can pick any string you like for the language name. Then, define empty objects for the runtimeMsg and runtimeText dictionaries, as follows:
Then, define a message for each message ID in each dictionary. Here is a list of all of the messages you can define:
You should only translate the text on the right-hand side of the equal sign. Do not translate the message IDs (such as "no connection message" or "signature overflow") because Profound UI will not be able to find your message in the dictionary if you change the dictionary name or the message id.
Where do you save this configuration option? Here.