Features overview
Here is the overview of important or interesting features of the Precision Language Suite product.
Benefits of used implementation and the file format
- Precision Language Suite allows you to implement the localization for your product in only four easy steps
- Implementation is very flexible and supports the dynamic usage if required (ie. loading only selected part of product)
- Language files are stored in a clear, easy to use text format
- It allows fast and uncomplicated verification of changes during the development of your product
- A compressed, binary format of language files is also available
- Language files can be shared between your projects (products)
- With the help of so called "user language files" you can adapt your product to a specific requirements of certain customers, without altering the distribution package of the product
- Besides own implementation of localizing the string constants, the product supports also a standard localization method for resource strings
- Precision Language Suite allows localization of error messages, informational messages and return values from a dynamically linked third-party libraries (DLL, BPL, ...)
- Basic system dialogs with localization support are included in the supplied source code
Four steps to localize your application
To get an idea of how to localize your application, read the following procedure. The more detailed description can be found in the product help.
-
Create an instance of TLanguageManager class
Use the unit plsLangMan anywhere in the project. This unit initializes a global LanguageManager variable of the class TLanguageManager.
Now assign a language code value to the LanguageManager.LanguageCode property.
TLanguageManager supports also other options, such as filtering the names of used language files (FileNames), location of the language files folder (Folder), and more.
-
Determine a list of available languages and present it to the user
To get a list of available languages, use a method LanguageManager.GetAvailableLanguages. It fills the specified list with values in the format "language_code = language_name".
This list can be presented to the user in the form of menu items, or in any other chosen form. When a user switches the language, you need to simply assign selected language code to the LanguageManager.LanguageCode property.
-
Define OnLanguageChanged event
The method assigned to the LanguageManager.OnLanguageChanged event is very important when you want to change the language during the application run.
It serves not only to change the localization of components on the form, but also as a central method to change the language in all active forms, data modules and other components of the application.
Setting localized texts of chosen language to the components on the form is ensured simply by calling the method LanguageManager.LangVCL.
-
Choose your way to use the text constants
The ideal way to use localized text strings (constants) is to let the Editor of localization projects generate a special source file (ie. LangConsts.pas) for you.
Editor will create all the necessary declarations, LanguageChanged method and default text assignments, so everything what you have to do, is using the constants identifiers when you need them.
However, if you want, you can access the constants with the help of LanguageManager.LangText method. This method may return not only constant texts, but also a property values of VCL Components from the current language.
Besides own implementation of using the text constants (mentioned above), Precision Language Suite supports also the standard method for localizing the resource strings. So, you can use the resourcestring declaration in your Delphi code, and then you can define and translate the identifiers in language files. An example of using the resource strings is also presented in LangSuiteDemo project.
More about how to use localization source codes can be found in the product help. Help is also available online and contains, for example, tutorials for localizing inherited forms, localizing DevExpress, BusinessSkinForm and DynamicSkinForm components, and more.
About the Editor
Although you can define a language files of your products in an ordinary text editor, specialized tool always will provide much more comfort and better ergonomy, what is mainly appreciated in the preparation of larger projects. And when any new functionality is added to the "localization source codes", this editor is updated simultaneously with them.
Basic editor features
- List of your projects
- Quick searching and filtering of items
- Item tags, including an automatated tagging (translate, do not localize, automatically translated, etc.)
- Finding and replacing the texts
- Automatic synchronization with defined source code files
- One-time import of resource strings and component properties
- Export and import of the translation table (using the CSV file format)
- By using the clipboard it allows the insertion of selected components and their properties from the development environment directly into the project
- Automatic preparation of the source file for the text constants identifiers (including the default texts)
- Indicative proposals of localization source code for your application
- Support for translation into other languages using the web services and/or custom dictionaries
- Microsoft Terminology Collection dictionaries (basic languages are provided in the installation package, complete dictionary with 94 languages can be downloaded from our web site)
- Pre-processing and post-processing of the project by executing your own defined external application (before opening and after saving the project)
- The package system for defining the default constants, messages, language codes, supported properties, etc.
Creating a new project with the Editor
When creating a localization (language) files for your product, you can use the following tentative procedure. The more detailed description can be found in the editor help.
- Create a new localization project at any time during the development process of your product
- Add new languages to the project by selecting from the predefined list
- Add VCL components for the localization (by manual addition of identifiers, by copying the components in Delphi and pasting them into the project from clipboard, or by adding the VCL file links into the localization project)
- Add text constants
- Localize the system messages
- Translate your texts
- Save the project and now you can use the resulting language files in your product
Embedded localization feature
Besides the standard possibilities of localization, the Precision Language Suite offers an embedded localization feature, that allows you to define localized texts directly in your running application.
You can simply click the elements in your application and enter the captions and texts in the currently selected language. This feature is suitable for minor corrections, as well as for a complex localization by an external translator, or also (in the so called UserMode) for your end users.
Althought this feature is available for registered users only (users with the purchased license of localization editor), the compiled demo applications are part of the distribution package, that is freely available for download. So any user can try the basic possibilities of an embedded localization feature of Precision Language Suite.
How embedded localization works?
Standard implementation of this feature is as follows:
And that's all folks! Now your product allows user to modify a component labels and other text strings, including the saving into the localization files.
To load back a newly entered texts, you have to implement also the standard localization functions. Along with these standard options of localization, you can change the texts in the currently selected language of user interface and make the corrections, or to enter labels of components "from scratch".
Of course, the installation and usage of "embedded localization" feature can be conditionally defined, ie. by command-line switch, by menu option, or completely separated by compilation directive.
In the plsEmbedded unit, there are also other methods, functions and variables, that can be used to setup a behaviour and the look of "embedded localization" feature.
Customization of embedded localization feature
Screenshots on this web site and the product demonstration projects present a default appearance and the behaviour of "embedded localization" dialog. Globaly defined variables and methods in plsEmbedded unit, allow you to customize the behaviour in many ways, and by implementing your own code in the plsEmbedded unit, you can completely rewrite the functionality and the look and feel of this feature. Source codes that support an "embedded localization" (plsEmbedded unit) you gain together with a purchased Precision Language Suite product license (see License agreement).
Other possibilities
As was mentioned above, an "embedded localization" is suitable for minor corrections, as well as for a complex localization by an external translator. But an interesting option is the combination of this feature along with the user language files format, because by this way you can provide an easy to use tool localization tool for your end-users. They can create their own localizations (themes or profiles resp.), and this without a risk, that it would have been overwritten a distribution localization files (whether on the client side or on your side, when you will take back and test such a translation).
All available informations and description of embedded localization feature can be found in the product help reference.
JS SiteSearch Generator
X-SQLT
Precision Builder Express
Precision Helper
Precision Language Suite
Technical support
Precision Competitions
Draw Designer
pdScript / pdScript IDE
TagCloud for VCL
DecoCharts for VCL
Send your comments to www pages.
Narodnich mucedniku 447
738 01 Frydek-Mistek
Czech Republic
















