diff -r 000000000000 -r d5ce4c64ef88 Docs/ExperienceUI/pages/lang.htm --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Docs/ExperienceUI/pages/lang.htm Tue Oct 16 00:07:41 2007 -0400 @@ -0,0 +1,109 @@ + + + ExperienceUI Documentation Content Frame + + + + + + + + + + + + + + + + + + + + + +
+ +

Multiple Languages

+ +

+ + + Since version 1.04, the ExperienceUI features support for multiple languages. The platform is based on that of the Modern UI's + (Joost does it again!) with a few modifications to make it work with the XPUI. To use multiple languges in your installer, simply + insert the XPUI_LANGUAGE macro, with 1 parameter, which should be the filename, minus the extension, of the language. + (ex: !insertmacro XPUI_LANGUAGE Spanish)
+
+ To write a language file, you can follow the English language file included with the XPUI, and, if necessary, write an NLF (Nullsoft + Language File; the NSIS side of the XPUI multi-language system) and make sure that your .NSH file has the same name as the NLF + file.
+
+

+ +

Translating the ExperienceUI

+

+ + + If you are fluent a language other than English, I would greatly appreciate it you would spend some time translating the ExperienceUI into your native language. You can edit the strings in <NSIS>\Contrib\ExperienceUI\Language Files\English.nsh, and save them in a new file. If you translate the ExperienceUI, I (and the many people that speak your native language) would sincerely appreciate it if you e-mail it to me.
+
+ Any language you can help with would be appreciated, but the languages I am looking for the most right now are Spanish, French, German, Chinese (Simplified and Traditional), Arabic, and Portuguese. The ExperienceUI already has a Brazilian Portuguese translation, courtesy of Jenner Modesto.
+
+ You can send translated language files to me at . +

+ + + +

Language Commands

+ +

+ + + Macros
+
+ XPUI_LANGUAGE Langfile(no_ext) - Adds a language to your installer. Don't insert the same + language twice. (ex: !insertmacro XPUI_LANGUAGE French)
+
+ XPUI_LANGDLL_DISPLAY - Shows the language selection dialog. Use this in .onInit. This should + eventually be a page.
+
+ XPUI_LANGPAGE_DISPLAY - Insert this macro in your .onInit function to show a page that asks the user + which language to use. At compile time, a custom EXE is built and any visual settings you use are carried over. At runtime this + custom EXE is extracted and run. If you insert this anywhere except in .onInit, the page will compile and show but the selected + language will not be changed because of limitations in NSIS. To manually change settings with the language page, edit <NSIS>\Contrib\ExperienceUI\LangPage.nsi. + Because of a bug in this page, you must only use languages that have 4-digit identifiers. Most languages have 4-digit IDs, but a few + do not. The only known language that uses a 5-digit ID is currently Breton. An example of a language with a 4-digit ID is English, whose + ID is 1033.
+
+ XPUI_UNGETLANGUAGE - Retrieves the saved language from the user's Registry, and, if the language is invalid, asks the user + to select his/her preferred language.
+
+ Defines
+
+

+ XPUI_LANGDLL_REGISTRY_ROOT (HKCR|HKLM|HKCC|HKCU|HKU|HKDD) - The registry root to store the user's + language preference in. (ex: HKLM)
+
+ XPUI_LANGDLL_REGISTRY_KEY My\Registry\Key - The registry key to store the user's + language preference in. (ex: SOFTWARE\MyProgram\Setup)
+
+ XPUI_LANGDLL_REGISTRY_VALUE MyRegValue - The registry value to store the user's + language preference in. (ex: LanguagePrefID)
+
+
+

+ +
+ + + +
+ + + +