Download MetaTrader 5

How to Add New UI Languages to the MetaTrader 5 Platform

11 July 2011, 13:01
MetaQuotes Software Corp.
3
6 544

Introduction

User interface of the MetaTrader 5 platform is translated into majority of the most popular languages. Don't worry if your native language is not among the supported ones. MetaTrader 5 originally incorporates the complete Unicode support, and the special MultiLanguage Pack utility is used for translating user interface. This utility allows anyone to translate client components of the MetaTrader 5 platform into any language of the world.

In this article we will consider the entire process of adding a new language of the user interface. You will learn how to download, install and start using the MetaTrader 5 MultiLanguage Pack utility. We will cover the specifics of usage and then will see the final result.


MultiLanguage Pack - Download, Install and Configure

The latest version of the MetaTrader 5 MultiLanguage Pack can always be downloaded from MetaQuotes Software Corp. website at the following link: https://download.mql5.com/cdn/web/metaquotes.software.corp/mt5/mt5mlpsetup.exe. The installation procedure is standard and does not cause any problems. By default, the utility is installed to the "C:\Program Files\MetaTrader 5 MultiLanguage Pack\" folder and all the necessary shortcuts are added to the Start menu.

Shortcuts in the Start menu

The installation also includes the User Guide in CHM format and two translation projects: the MetaTrader 5 Client Terminal ("\MetaTrader 5 MultiLanguage Pack\Projects\terminal5.prl") and the MetaEditor 5 ("\MetaTrader 5 MultiLanguage Pack\Projects\metaeditor5.prl").

A translation project includes all available languages ​​of the user interface of a MetaTrader 5 product. When you first start MultiLanguage Pack the translation project of Client Terminal is opened by default and looks as follows.

MultiLanguage Pack after the first start

Translation project files have the PRL extension and are associated with the MetaTrader 5 MultiLanguage Pack application by default.

MetaTrader 5 translation projects are constantly updated to reflect the latest changes in the user interface. If for any reason you have to restart a previously initiated translation, you can always get the latest version of translation projects by downloading the updated MultiLanguage Pack.


MultiLanguage Pack - User Interface

The MultiLanguage Pack has a simple and user-friendly interface. It consists of the Main Menu (1), the Toolbar (2), the Project Browser (3) and the Workspace (4).

MultiLanguage Pack user interface

The Main Menu provides basic commands of project management. Some of them are duplicated on the Toolbar. Certain commands are invoked from the corresponding context menus.

Many commands have their keyboard shortcuts. You can find the complete description of all available commands and shortcuts in the User Guide.

The Project Browser provides navigation through a project and contains language subprojects. Each subproject is a translation into a particular language, containing three main resource groups: Strings, Menus and Dialogs.

  • Menus. The Menus section incorporates texts of all the menus (main and context) appearing in program. The structure of Menus has a clear hierarchy: all the menus and their items are numbered, submenus are represented as subsections. The ampersand (&) - is a special character that precedes a selected letter in the name of a menu item. This letter being pressed together with the Alt key activates a command or opens a submenu, while the letter is underlined.

    Translating a menu

  • Dialogs. The Dialogs section lists all the dialog boxes or their parts (tabs). Text strings in dialog boxes are also numbered.

    Translating a dialog box

  • Strings. Strings contain all other texts that don't fall into the Menus or Dialogs categories. These may be names of buttons, dialog boxes and their tabs, column headers, tooltips, texts in the Status bar, texts of various messages, etc.

The Workspace is used to actually translate user interface elements. The translation process is very simple: select a language, then a subgroup of resources and then start translating line by line in the Workspace.

While you are translating, you can see how a dialog box or a menu will look like using the Preview feature. This command is available in the Main Menu, on the Toolbar and by pressing the F8 key. Preview is not available for the Strings.


MultiLanguage Pack - How It Works

The process of getting a new UI language can be represented as the following flowchart.

MultiLanguage Pack working scheme

1. Adding a Language. The MetaTrader 5 platform fully supports the Unicode encoding, so the user interface of its components can be easily translated into any language in the world. After adding a language, the resources from the source English language are copied into a target language subproject. After that these resource become available for translation.

2. Translation. This is the most time consuming stage. The default language in the MetaTrader 5 platform is English, and all translations are carried out from it consistently line by line. Once finished, you have to compile your project.

3. Compilation. Compiling a project creates target files for each language. Target files have the LNG extension and have the following naming scheme: <module>_<language>.lng. For example, the language file of the client terminal translation into Russian will be named "terminal_russian.lng". Compiled language files must be placed in the "\Languages" ​​subfolder of a MetaTrader 5 product.

For example, if the Client Terminal is installed in the "C:\Program Files\MetaTrader 5\" folder, then translations of its user interface should be placed in the "C:\Program Files\MetaTrader 5\Languages\" folder. You should overwrite LNG files every time you update translations in a project.

4. Checking Translations. Certainly you have to check the quality of your translations. In addition to spelling errors, translations often don't fit in the allocated space. In this case you should either express your translations more laconically, or abbreviate some words without losing their meaning. This is especially true for Strings, since preview is not available for them.

5. Publishing Translation. When translation of interface is completed and tested, you can send it to MetaQuotes Software Corp. using the "Send" command. After the technical checking, your translation can be included into a standard distribution of a MetaTrader 5 product.


Translation Example

Consider all the stages of translating user interface on the example of MetaEditor. For this we will need the MetaEditor 5 translation project that is installed together with MultiLanguage Pack. As an example we will add German translations of various UI elements.

MetaEditor translation project

1. Adding a Language

Add a new language to the project. To do this, select "Add New Language" from the "Edit" menu, or click the Add New Language button on the Toolbar, or press Ctrl+A.

In the "Add new language" dialog box select "German" and click OK. A new language branch is then created in the Project Browser.

German Language in MetaEditor Translation Project

2. Translation

Consider the process of translating various UI elements.

Menus

Expand the "Menus" category, then select menu [128]. Translate the first menu item.

Translating a menu

The ampersand mark & before N designates the corresponding shortcut used with the Alt key. Right after the command name comes the \t escape symbol and then the Ctrl+N shortcut. In MetaEditor 5 user interface the translation will look as follows.

Special characters in menu translation

Letter N is emphasized when used in conjunction with the Alt key. The tab character separates the command text from the shortcut text, right aligning the latter.

Alway keep position of the tab character (\t) and shortcut text. However, position of the & sign do not necessarily coincide with original text. The main thing is that shortcut keys must be unique for each command within a menu.

If a translated text is exactly repeated in other resources, MultiLanguage Pack will offer you to substitute translations in appropriate places. In our case, it offers to translate the same menu item in menu [133].

Translating repeated sentences

Message in the Status Bar and Button on the Toolbar

In the Strings group browse to the line 57600 and translate it. This resource contains text appearing in the Status bar, when you hover your mouse over the "New" command, that we have already translated. After the command description comes the familiar text of hot keys. Then comes the \n escape character designating the new line, and text of a button on the Toolbar.

Translating text in the Status bar and button on the Toolbar

In the MetaEditor 5 UI the translation will look as follows.

Command description in the Status bar Button name on the Toolbar

Dialog Box

In the Dialogs group open the [349] Introduction page dialog box. Translate all the lines in this dialog box.

Translating a dialog box

For your convenience, you can use the Preview feature to see how the translated dialog box will look like.

Dialog box preview

And this is how it will look like in the program.

Translated dialog box in MetaEditor UI

Text of some standard buttons (Back, Next, Cancel, etc.) depends on the operating system language. These particular buttons are not available for translation in MultiLanguage Pack.

During translation process you may encounter strings containing special characters, such as %s, %d, \n, \t, etc. Be careful, as these characters have special meaning when displaying text strings in user interface. For example, %s is replaced with a line of text, %d is replaced with an integer number, \n means a line break, etc. You can find the complete list of untranslatable words in Appendix B of the User Guide.

3. Compilation

Compile the project. To do this click the Compile button, or select "Compile Project" from the "Tools" menu, or press the F9 key.

Successful compilation

In the same folder with your project file (in our example it is "C:\Program Files \MetaTrader 5 MultiLanguage Pack\Projects") the MultiLanguage Pack generates target LNG files for all languages ​​of the project. With every subsequent compilation existing target files are updated.

Compiled translation files

4. Checking Translations

In the standard delivery package of MetaTrader 5 terminal, all user interface translations are located inside the executable files. For client terminal it is terminal.exe, for editor of source codes - metaeditor.exe. To test the intermediate versions of translations there is a special mechanism to run executable files with a dedicated key /language:

executable_file_name.exe /language:<path to translation file>

For example, if our client terminal is installed in the "C:\Program Files\MetaTrader 5\" folder, in order to test our MetaEditor translation into German, use the following command:

C:\Program Files\MetaTrader 5\metaeditor.exe "/language:C:\Program Files\MetaTrader 5 MultiLanguage Pack\Projects\metaeditor_German.lng"

This command opens the MetaEditor 5 with German translation enabled. Since the path to the file with the translation contains spaces, the whole /language key is enclosed in double quotes. If there are no spaces in file path, then double quotes are optional. For example, if you copy a translation file to the terminal installation directory, then the command is reduced to the following:

metaeditor.exe /language:metaeditor_German.lng

Unfortunately, MultiLanguage Pack has no built-in spell checker. However, you can export your translations and check them for spelling errors in any word processor like Microsoft Word. To do this, in the project browser right-click on the language subproject and select "Save as text".

Export translation into a text file

All the resources for selected language (strings, menus and dialogs) are exported to the specified text file.

5. Publishing Translation

Thoroughly check your translation. Make sure that all UI elements are displayed correctly and without errors.

Press the Send button on the Toolbar or select "Send to MetaQuotes ServiceDesk" from the "Tools" menu.

Enter your name and e-mail to contact you, and then click the "Send" button.

Sending translation to MetaQuotes Software Corp.

Your translation will be sent as an incoming request to our TeamWox groupware. After a technical check, your translation will be included into the standard delivery of a MetaTrader 5 product.

Please use the standard function of publishing translations and DO NOT send your translations as compiled LNG files by e-mail.


Dictionary

To increase the speed and consistency of translations, MultiLanguage Pack offers the Dictionary feature. Dictionary allows you to quickly translate repetitive phrases. If you are sure you have translated a given string before, you can try to quickly substitute translation by selecting the "Translate from Dictionary" command from the context menu (or by pressing Ctrl+D).

Translating using dictionary

If a string has a translation, it will be substituted automatically.

Substituting translation

Translations are recorded into the Dictionary for all languages, ​​when project is compiled.

The Dictionary allows you to translate user interface in batch mode. To do this, click the Dictionary button on the Toolbar or select the same command from the "Edit" menu.

Dictionary contents

In this window you can select lines for which you want to use translations from Dictionary, and then click "Apply".


Useful Tips

  • Always translate according to context.
  • Use the search feature (the "Find" and "Find next" commands in the "Edit" menu).
  • Searching is case sensitive. Also, the phrase you are searching may contain special characters like &, \t, \n, etc.
  • Remember the importance of special characters.
  • The Tab key allows you to switch between the Project Browser and the Workspace.
  • To start editing the line of text you can use the F2 key in addition to double-clicking.
  • For easy navigation in the Workspace use the "Next" (Alt+Right) and the "Previous" (Alt+Left) commands.
  • The "Statistics" command, available in the "Tools" menu and on the Toolbar, displays detailed statistics on the number of translated words for each language.


Conclusion

We hope that this article will inspire you to translate the MetaTrader 5 user interface into your native language. MetaQuotes Software Corp. takes interest in the largest possible number of languages ​​supported in its products, and provides all the necessary tools for this.

Translated from Russian by MetaQuotes Software Corp.
Original article: https://www.mql5.com/ru/articles/311

Last comments | Go to discussion (3)
MetaQuotes Software Corp.
MetaQuotes Software Corp. | 23 Aug 2011 at 16:42

MultiLanguage Pack installation has been updated. Translation projects now include the latest changes in user interface. Also new languages have been added.

If you are a translator, please download and install MultiLanguage Pack again using the same hyper-link https://download.mql5.com/cdn/web/metaquotes.software.corp/mt5/mt5mlpsetup.exe.

Balachandran Chandrasekar
Balachandran Chandrasekar | 17 Sep 2013 at 06:18
very useful article. it helped me a lot.
Alex Key
Alex Key | 24 Apr 2014 at 11:36

The article has been updated in the Checking Translations section:

4. Checking Translations

In the standard delivery package of MetaTrader 5 terminal, all user interface translations are located inside the executable files. For client terminal it is terminal.exe, for editor of source codes - metaeditor.exe. To test the intermediate versions of translations there is a special mechanism to run executable files with a dedicated key /language:

executable_file_name.exe /language:<path to translation file>

For example, if our client terminal is installed in the "C:\Program Files\MetaTrader 5\" folder, in order to test our MetaEditor translation into German, use the following command:

C:\Program Files\MetaTrader 5\metaeditor.exe "/language:C:\Program Files\MetaTrader 5 MultiLanguage Pack\Projects\metaeditor_German.lng"

This command opens the MetaEditor 5 with German translation enabled. Since the path to the file with the translation contains spaces, the whole /language key is enclosed in double quotes. If there are no spaces in file path, then double quotes are optional. For example, if you copy a translation file to the terminal installation directory, then the command is reduced to the following:

metaeditor.exe /language:metaeditor_German.lng
Step on New Rails: Custom Indicators in MQL5 Step on New Rails: Custom Indicators in MQL5

I will not list all of the new possibilities and features of the new terminal and language. They are numerous, and some novelties are worth the discussion in a separate article. Also there is no code here, written with object-oriented programming, it is a too serous topic to be simply mentioned in a context as additional advantages for developers. In this article we will consider the indicators, their structure, drawing, types and their programming details, as compared to MQL4. I hope that this article will be useful both for beginners and experienced developers, maybe some of them will find something new.

Here Comes the New MetaTrader 5 and MQL5 Here Comes the New MetaTrader 5 and MQL5

This is just a brief review of MetaTrader 5. I can't describe all the system's new features for such a short time period - the testing started on 2009.09.09. This is a symbolical date, and I am sure it will be a lucky number. A few days have passed since I got the beta version of the MetaTrader 5 terminal and MQL5. I haven't managed to try all its features, but I am already impressed.

Using text files for storing input parameters of Expert Advisors, indicators and scripts Using text files for storing input parameters of Expert Advisors, indicators and scripts

The article describes the application of text files for storing dynamic objects, arrays and other variables used as properties of Expert Advisors, indicators and scripts. The files serve as a convenient addition to the functionality of standard tools offered by MQL languages.

How to create an indicator of non-standard charts for MetaTrader Market How to create an indicator of non-standard charts for MetaTrader Market

Through offline charts, programming in MQL4, and reasonable willingness, you can get a variety of chart types: "Point & Figure", "Renko", "Kagi", "Range bars", equivolume charts, etc. In this article, we will show how this can be achieved without using DLL, and therefore such "two-for-one" indicators can be published and purchased from the Market.