Index: openacs-4/packages/acs-core-docs/www/xml/developers-guide/i18n.xml =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-core-docs/www/xml/developers-guide/i18n.xml,v diff -u -r1.11 -r1.12 --- openacs-4/packages/acs-core-docs/www/xml/developers-guide/i18n.xml 18 Feb 2004 14:43:05 -0000 1.11 +++ openacs-4/packages/acs-core-docs/www/xml/developers-guide/i18n.xml 20 Feb 2004 15:13:49 -0000 1.12 @@ -1,10 +1,10 @@ - %myvars; ]> - + Internationalization @@ -14,10 +14,111 @@ - + + + Internationalization and Localization + + + + + + + Stage + Task + Who + + + + + Internationalization + Package Developer uses the acs-lang tools to replace all visible text in a package with message keys. (More information) + Package Developer + + + Release Management + The newly internationalized package is released. + Package Developer + + + The translation server is updated with the new package. + Translation server maintainers + + + Localization + Translators work in their respective locales to write text for each message key. (More information) + Translators + + + Release Management + The translated text in the database of the translation server is compared to the current translations in the OpenACS code base, conflicts are resolved, and the new text is written to catalog files on the translation server. + Translation server maintainers + + + The catalog files are committed to the OpenACS code base. + Translation server maintainers + + + A new version of OpenACS core and/or affected packages is released and published in the OpenACS.org repository. + Release Manager + + + Upgrading + Site Administrators upgrade their OpenACS sites, either via the automatic upgrade from the Repository or via tarball or CVS + Site Administrators + + + Site Administrators import the new translations. Existing local translations, if they exist, are not overwritten. + Site Administrators + + + +
+
- Introduction + + Translator's Guide + Most translators use the OpenACS Public Translation Server, because the process of getting new message keys onto the server and getting new translations back into the distribution are handled by the maintainers of that machine. You can also do translation work on your own OpenACS site; this makes your own translations more readily available to you but also means that your work will not be shared with other users unless you take extra steps (contacting an OpenACS core developer or submitting a patch) to get your work back to the OpenACS core. + The basic steps for translators: + + + Go to the Localization page and choose the locale that you are translating to. If the locale is not present you need to visit Administration of Localization and create the locale. + + + + Translating with Translator Mode + To translate messages in the pages they appear, Toggle Translator Mode and then browse to the page you want to translate. Untranslated messages will have a yellow background and a red star that you click to translate the message. Translated messages have a green star next to them that is a hyperlink to editing your translation. There is a history mechanism that allows you to see previous translations in case you would want to revert a translation. + + + + + + + While in Translator mode, a list of all message keys appears at the bottom of each page. + + + + + + + + + Batch translation + To translate many messages at once, go to Administration of Localization, click on the locale to translate, then click on a package, and then click Batch edit these messages. + + + + + + + + + + + + + Introduction to Developing Internationalized Packages + This document describes how to develop internationalized OpenACS packages, including writing new packages with @@ -48,8 +149,6 @@ numbers must use internationalized functions. -
- AOLserver Configuration for Multilingual Sites @@ -59,7 +158,7 @@ charset. In order for AOLserver to use utf8 you need to set the config parameters OutputCharset and URLCharset to utf-8 in your AOLserver config file (use the etc/config.tcl - template file). For sites running on Oracle you need to make + template file). This is the default for OpenACS 5.1 and later. For sites running on Oracle you need to make sure that AOLserver is running with the NLS_LANG environment variable set to .UTF8. You should set this variable in the nsd-oracle run script (use the @@ -429,10 +528,8 @@ + - - - Dates, Times, and Numbers @@ -523,14 +620,15 @@ To internationalize numbers, use lc_numeric $value, which formats the number using the appropriate decimal point and thousand separator for the locale. - + Internationalizing Forms When coding forms, remember to use message keys for each piece of text that is user-visible, including form option labels and button labels. - + +
- + Internationalizing Existing Packages @@ -582,9 +680,9 @@ - + - + Design Notes User locale is a property of ad_conn, ad_conn locale. The request processor sets this by calling lang::conn::locale, which looks for the following in order of precedence: @@ -598,6 +696,6 @@ For ADP pages, message key lookup occurs in the templating engine. For TCL pages, message key lookup happens with the _ function. In both cases, if the requested locale is not found but a locale which is the default for the language which matches your locale's language is found, then that locale is offered instead. - + - +