Home > Developers > Wiki > Mifos Localization
Views

Edit history

Edit: -1 of 1
Time: 2007-10-17 10:04:38
Note: /Mifos/www/developers/wiki/MifosLocalization/edit

changed:
-
Localizing Mifos into Other Languages
=====================================

Mifos is currently available only in English. We would like to translate the text and error messages that appear in the Mifos application into other languages. The top priorities are probably Spanish and French although we would also like to translate Mifos into either Chinese or Arabic in order to test a non-Roman character set. 

Mifos has (theoretically) been built to make language localization an easy process. However, this has not yet been tested nor has the process of "how to localize Mifos" been documented. We're looking for volunteers to both localize Mifos and create a "how-to" wiki page to instruct others on how to localize Mifos. This page would document step-by-step instructions and any known issues or bugs. We'd also welcome volunteers to identify (and implement) code changes that would improve the localization process. 

Technical Background
++++++++++++++++++++

Most of the strings to be translated are located in .properties files. Each module has their own properties file containing all the strings used in that module. For example `!BulkEntryUIResources.properties <https://mifos.dev.java.net/source/browse/mifos/trunk/mifos/src/org/mifos/application/bulkentry/util/resources/BulkEntryUIResources.properties>`_ contains the line:

 * bulkEntry.revnsub=Review & submit 

The Spanish translation in `!BulkEntryUIResources_es_ES.properties <https://mifos.dev.java.net/source/browse/mifos/trunk/mifos/src/org/mifos/application/bulkentry/util/resources/BulkEntryUIResources_es_ES.properties>`_ has the translated message: 


 * bulkEntry.revnsub=Repase y someta 

Please note, however, that most modules dont yet have a spanish properties file-- these will have to be created. 

Values for look-up options and configured labels are in the database (set from latest-data.sql on new installations). These will also have to be translated (and checked into latest-data in subversion). The relevant tables have the ability to have different versions of these labels for different languages - so translated versions of these labels should be `submitted <http://mifos.prod2.ifpeople.net/developers/technical-orientation/code-submission-process>`_ for inclusion in Mifos (also see `Database Standards <http://mifos.prod2.ifpeople.net/developers/technical-orientation/coding-standards#databasestandards>`_). Also see `How to Configure Mifos <http://mifos.prod2.ifpeople.net/knowledge/support-for-common-tasks/deploying-mifos/configuring-mifos>`_. 

From the functional perspective - some things to keep in mind:
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 

* Most users will generally want their numbers displayed in international numbers ``(0123456789)``, not localized into Chinese ``(零一二三四五六七八九十)``, Eastern Arabic ``(٠١٢٣٤٥٦٧٨٩)``, Devanagari ``(०१२३४५६७८९)``, etc. This may change, and one future enhancement might be to allow an MFI to configure localization of numbers separately, but initially, this isn't a requirement. 
* The same/similiar phrases are repeated across the various modules. We've tried to keep phrasing consistent across the properties files. For example, when a desired value is not selected for a field, we don't want the application to say "Please select Loan Officer" and "Please specify Loan Officer" in another. I'm sure there will be inconsistencies found (please fix!), but when translating the various properties files, we want to try to keep phrasing consistent across the site. 
* Please review the functional specification for both language and how users can select their user-preferred language. 
* Any other functional questions-- feel free to post them to the mailing list or send them to emilytucker @ dev.java.net.

From a technical perspective, some things to keep in mind:
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 

* `Working with Composite Messages <http://www.w3.org/International/articles/composite-messages>`_ - Mifos has some of these -- look for {0} and the like in the .properties files for one mechanism by which we do it. 
* `Re-using Strings in Scripted Content <http://www.w3.org/International/articles/text-reuse>`_ (another good article which covers similar subjects). 
* Related to the articles above, please refer to the thread on the mifos-developer list "Issues with Localizing Mifos" 
* Appropriate entries will need to be made into mifosmasterdata.sql. 

Localization/Translation Tools and Approaches
+++++++++++++++++++++++++++++++++++++++++++++

It is useful to develop a common glossary of terms that can be shared and reused during translation. In computer aided translation (CAT) this is referred to as the Translation Memory. There are two open source CAT tools that would be worth exploring: 

* `!OmegaT <http://www.omegat.org/omegat/omegat_en/omegat.html>`_
* `Open Language Tools <https://open-language-tools.dev.java.net>`_

The goal of these tools is to help speed translation and to aid in consistency of translation. They will both work for java ".properties" files and for documentation (though some conversion may be necessary). 

To make use of tools like these for translating text in the database would require some work to implement an import/export capability into a format that can be used by these tools. 

One approach to streamlining the localization process would be to move most or all of the text requiring translation from the database and into .properties files so that translation can be done on a uniform file set. 

There are also some simpler tools available just for editing .properties files such as: 


* `I18NEdit <http://www.cantamen.de/i18nedit.php?lang=en>`_
* https://prbeditor.dev.java.net/prbeditor

The .properties tools won't help with translating documentation and don't support the idea of a standard translation memory. 

One other point to be aware of is that it is likely that there will be some code changes (java & JSP) required to make translations show up completely correctly even after the text itself has been translated. Once the text has been translated, then it will be clearer from looking at the application web pages where further work is needed. 

----

See Also
========

* At !MIFOSHowToHelp there are a list of a few other things which might be worth translating, although those are of significantly lower priority. 
* `Localization <http://mifos.prod2.ifpeople.net/knowledge/functional-specs/localizing-of-mifos>`_ - functional specification 
* MifosLocalizationStories is a list of stories related to the localization effort.
* MifosInternationalizationProject tracks work done on Internationalization to prepare Mifos for localization

Grameen logo