Tuesday, 7 October 2014

Runtime Translation Facility

A key aspect of the design of Rapide was to enable the development of multi-lingual applications without needing to design a separate window design for each language. This becomes especially important when you want your application to support many languages and the translation will probably be performed by different people and who will not be skilled in CA Gen development.

The solution we adopted was to give each string (literals, prompts, exit state messages, etc.) a string ID and then externalise the actual string values into a separate string property file which could be translated into multiple languages and then the correct translated string file used at runtime based on the user's locale.

Because the strings are stored outside of the model, the translations can be performed by someone who has the necessary translation skills without also needing to use the Gen toolset.

A string translation tool is available with Rapide that can be used by a non-developer, but one issue with this is that the strings are not presented in the context of the application which can make translation difficult if you cannot see the strings on the actual window.

To make it easier to translate the application, Rapide now provides a Runtime Translation Facility.

When enabled, the Rapide runtime provides a right-click facility when you are actually executing the application in a browser or desktop environment on most types of controls in order to dynamically enter translation strings for the item clicked on.  

This can vastly simplify the process of translation for the majority of UI designs, providing an intuitive method of translating.

In the example below, whilst the user is running in a French locale, the text is only available in English.

With the Runtime Translation Facility enabled, they can right-click on a text string and provide the translation.

The window immediately reflects the changed string. These runtime translations are stored in a file containing the changed strings which can then be merged back into the translated strings in the development machine to become part of the next release of the application. 

No comments: