AU3Text-HowTo.txt | Au3Text v1.0
09-09-2012 | dany

Step by step to convert your scripts for AU3Text.

1.  #include <AU3Text.au3>
2.  #include <AU3TextGUI.au3> to enable users to change the language.
3.  Bind a language to your program with _AU3Text_BindTextSection(). The first
    parameter is the INI section to use and the second the locale to use.
    See AU3Text-Demo.au3 for a basic example on how to store and load locales
    in your configuration.
4.  Wrap all strings that should be translated in the appropriate _AU3Text*
    function. Most of the time you're best off with _AU3Text() or _() if you
    prefer the shorthand functions.
5.  Do not concatenate variables or constants into your strings! Variables are
    ambiguous by definition and AU3Text-Extractor.exe won't parse them. Rewrite
    your strings to use StringFormat or _StringFormatEx instead.
6.  In case there is a string that could have several plural variants, use
    _AU3Text_Plural or _P.
7.  Provide clear and consistent keys. This will make it easier for others to
    translate your files.
    Alternately you can run in 'MD5' mode. IN this case, simply omit the key.
    Then the key will be generated by hashing the message string with MD5. These
    language files will be less friendly to read and maintain!
8.  After wrapping all strings, create a language menu or combo with one of the
    functions in AU3TextGUI.au3 so that users can change the language. See
    AU3Text-Demo.au3 for an example on how to use AU3Text_GUI* functions in your
    program.
9.  Now use SciTe to compile AU3Text-Extractor.au3.
10. Once compiled run the following command:
    AU3Text-Extractor.exe MyScriptName.au3 en
    This will create an english language file called MyScriptName.en.lng in the
    I18n directory. AU3Text-Extractor will tell you about any strings that failed
    to extraxt along the way.
11. Proofread the language file to make sure all string were properly extracted.
    If there are any plural cases, make sure they are correct. By default,
    AU3Text-Extractor.exe will create cases for 0, 1 and PLURAL, which is the
    generic plural variant. Make sure all special cases for the current language
    are in place. Now is also the time to do some re-oredering if necessary.

Finished! Your program is now ready for internationalization. Now Users just need
to copy the language file they best understand, give it the appropriate locale
extension and translate all the messages. UA3Text will automatically pick up any
new language files in I18n.
