This package provides internationalization ("i18n" = "i" + 18 characters + "n) services for the OpenACS base system. I18n services include:
lib/change-locale-bar.adp lib/change-locale-bar.tcl lib/conflict-link.adp lib/conflict-link.tcl lib/messages-to-translate.adp lib/messages-to-translate.tcl tcl/apm-callback-procs.tcl APM callbacks library tcl/lang-audit-procs.tcl Auditing of lang_messages tcl/lang-catalog-procs.tcl <p> Routines for importing/exporting messages from/to XML message catalog files. tcl/lang-install-procs.tcl Support procedures for install.xml actions. tcl/lang-message-procs.tcl Routines for displaying web pages in multiple languages <p> This is free software distributed under the terms of the GNU Public License. tcl/lang-util-procs.tcl Utility routines for translating pages. tcl/lang-widget-procs.tcl Widgets for acs-lang. tcl/locale-procs.tcl Localization procedures for OpenACS <p> This is free software distributed under the terms of the GNU Public License. tcl/localization-procs.tcl Routines for localizing numbers, dates and monetary amounts <p> This is free software distributed under the terms of the GNU Public License.
_ Short hand proc that invokes the lang::message::lookup proc. _mr Registers a message in a given locale or language. ad_locale_get_label Returns the label (name) of locale To be removed in 5.3 clock_to_ansi Convert a time in the Tcl internal clock seeconds format to ANSI format, usable by lc_time_fmt. install::xml::action::disable-locale Disable a locale <code><disable-locale locale="en_US"></code> install::xml::action::enable-locale Enable a locale <code><enable-locale locale="en_US"></code> install::xml::action::set-system-locale set the systewide locale <code><set-system-locale locale="en_US"></code> lang::apm::after_install After install callback lang::apm::after_upgrade After upgrade callback for acs-lang lang::audit::changed_message Save a message that is overwritten. lang::catalog::all_messages_for_package_and_locale Set a multirow with name all_messages locally in the callers scope with the columns message_key and message for all message keys that do not have an upgrade status of deleted. lang::catalog::assert_catalog_file Throws an error if the given path is not valid for a catalog file. lang::catalog::default_charset_if_unsupported Will return the system default charset and issue a warning in the log file if the given charset is not supported by tcl. lang::catalog::export Exports I18N messages from the database to XML catalog files. lang::catalog::export_to_file Export messages for a certain locale and package from the database to a given XML catalog file. lang::catalog::get_catalog_file_path Get the full path of the catalog file for a given package, and locale. lang::catalog::get_catalog_files Return the full paths of all message catalog files of the given package. lang::catalog::get_catalog_paths_for_import Return a list of file paths for the catalog files of the given package. lang::catalog::get_required_xml_attribute Return the value of the given attribute and raise an error if the value is missing or empty. lang::catalog::import Import messages from catalog files to the database. lang::catalog::import_from_file <p> Import messages for a certain locale and package from a given XML catalog file to the database. lang::catalog::import_messages <p> Import a given set of messages from a catalog file to the database for a certain package and locale. lang::catalog::is_upgrade_backup_file Given a file path return 1 if the path represents a file with messages backed up from message catalog upgrade. lang::catalog::last_sync_messages For a certain package, and locale, return the messages in the database the last time catalog files and db were in sync. lang::catalog::message_backup_file_prefix The prefix used for files where we store old messages that were overwritten during message catalog upgrade. lang::catalog::messages_in_db Return a list of all messages for a certain package and locale. lang::catalog::package_catalog_dir Return the catalog directory of the given package. lang::catalog::package_delete Unregister the I18N messages for the package. lang::catalog::package_has_files_in_locale_p Return 1 if the given package has any catalog files for the given locale and 0 otherwise. lang::catalog::parse Parse the given catalog file xml contents and return the data as an array. lang::catalog::read_file Returns the contents of the given catalog file as a string reading the file with the charset given in the filename. lang::catalog::translate Translates all untranslated strings in a message catalog from English into Spanish, French and German using Babelfish. lang::catalog::uninitialized_packages Return a list of keys for installed and enabled packages that do not have any message keys associated with them. lang::conn::browser_locale Get the users preferred locale from the accept-language HTTP header. lang::conn::charset Returns the MIME charset name corresponding to the current connection's locale. lang::conn::get_accept_language_header Obtain a list of locals from the request headers. lang::conn::language Get the language for this request, perhaps for a given package instance. lang::conn::locale Get the locale for this request, perhaps for a given package instance. lang::conn::timezone Get this connection's timezone. lang::conn::valid_locale_p Check, of the provided locale is syntactically correct lang::message::cache Loads the entire message catalog from the database into the cache. lang::message::check <p> Check a message for semantic and sanity correctness (usually called just before a message is registered). lang::message::conflict_count Return the number of messages with conflicts (conflict_p=t) resulting from catalog imports. lang::message::delete Deletes a message in a particular locale. lang::message::edit Edit properties (meta data) of a language catalog message, but not the message text itself. lang::message::embedded_vars_regexp The regexp pattern used to loop over variables embedded in message catalog texts. lang::message::format Substitute all occurencies of %array_key% in the given localized message with the value from a lookup in the value_array_list with array_key (what's between the percentage sings). lang::message::get Get all properties of a message in a particular locale. lang::message::get_element Get value of a single attribute of a message. lang::message::get_embedded_vars Returns a list of embedded substitution variables on the form %varname% in a message. lang::message::lookup This proc is normally accessed through the _ procedure. lang::message::message_exists_p Return 1 if message exists in given locale, 0 otherwise. lang::message::register <p> Registers a message for a given locale and package. lang::message::remove_from_cache Delete a certain message key from the cache for all locales. lang::message::revert Revert a message to the last overwritten version of it, i.e. lang::message::translate Translates an English string into a different language using Babelfish. lang::message::unregister Unregisters a message key, i.e. lang::message::update_description lang::system::get_locale_options Return all enabled locales in the system in a format suitable for the options argument of a form. lang::system::get_locale_options_not_cached Return all enabled locales in the system in a format suitable for the options argument of a form. lang::system::get_locales Return all enabled locales in the system. lang::system::get_locales_not_cached Return all enabled locales in the system. lang::system::language Get system language setting for a given package instance. lang::system::locale Get system locale setting for a given package instance. lang::system::locale_set_enabled Enables or disables a locale. lang::system::package_level_locale lang::system::package_level_locale_not_cached lang::system::set_locale Set system locale setting for a given package instance, or the site-wide system locale. lang::system::set_timezone Tell OpenACS what timezone we think it's running in. lang::system::site_wide_locale Get the site wide system locale setting. lang::system::timezone Ask OpenACS what it thinks our timezone is. lang::system::timezone_support_p Return 1 if this installation of acs-lang offers timezone services and 0 otherwise. lang::system::timezone_utc_offset lang::system::use_package_level_locales_p Returns whether we're using package level locales. lang::user::language Get user language preference for a given package instance. lang::user::locale Get user locale preference for a given package instance. lang::user::package_level_locale Get the user's preferred package level locale for a package given by its package id. lang::user::package_level_locale_not_cached Get the user's preferred package level locale for a package given by its package id. lang::user::set_locale Set user locale setting for a given package instance. lang::user::set_timezone Set the user's timezone setting. lang::user::site_wide_locale Get the user's preferred site wide locale. lang::user::site_wide_locale_not_cached Get the user's preferred site wide locale. lang::user::timezone Get the user's timezone. lang::user::timezone_no_cache lang::util::charset_for_locale Returns the MIME charset name corresponding to a locale. lang::util::convert_adp_variables_to_percentage_signs Convert ADP variables to percentage_signs - the notation used to interpolate variable values into acs-lang messages. lang::util::convert_percentage_signs_to_adp_variables Convert percentage_signs message vars to adp var syntax. lang::util::convert_to_i18n Internationalising of Attributes. lang::util::default_locale_from_lang Returns an enabled default locale for a language. lang::util::default_locale_from_lang_not_cached Returns the default locale for a language. lang::util::edit_lang_key_url lang::util::escape_vars_if_not_null Processes a list of variables before they are passed into a regexp command. lang::util::get_hash_indices Returns a list of two element lists containing the start and end indices of a #message_key# match in the multilingual string. lang::util::get_label Returns the label (name) of locale lang::util::get_locale_options Return a list of locales know to the system lang::util::get_locale_options_not_cached Return all enabled locales in the system in a format suitable for the options argument of a form. lang::util::get_message_lookups Get the list of all message keys looked up so far during the current request. lang::util::get_regexp_indices Returns a list of two element lists containing the start and end indices of what is captured by the first parenthesis in the given regexp pattern in the multilingual string. lang::util::get_temporary_tags_indices Given the contents of an adp file return the indices of the start and end chars of embedded message keys on the syntax: <#package_key.message_key Some en_US text#> lang::util::iso6392_from_language Returns the ISO-639-2 code for a language. lang::util::iso6392_from_locale Returns the ISO-639-2 code for a locale. lang::util::lang_sort Each locale can have a different alphabetical sort order. lang::util::language_label Returns the ISO-639 label for a language code. lang::util::localize Takes a string with embedded message keys on the format #message_key_name# and returns the same string but with the message keys (and their surrounding hash marks) replaced with the corresponding value in the message catalog. lang::util::localize_list_of_lists localize the elements of a list_of_lists lang::util::message_key_regexp Regular expression for recognizing message keys in the form <span>#</span>package_name.key#. lang::util::message_tag_regexp The regexp expression used by proc get_temporary_tags_indices and elsewhere to extract temporary message catalog tags (<#...#>) from ADP and Tcl files. lang::util::nls_language_from_language Returns the nls_language name for a language lang::util::record_message_lookup Record a message lookup in translator mode. lang::util::remove_gt_lt Removes < > and replaces them with < > lang::util::replace_adp_text_with_message_tags Prepares an .adp-file for localization by inserting temporary hash-tags around text strings that looks like unlocalized plain text. lang::util::replace_temporary_tags_with_lookups Modify the given ADP or Tcl files by replacing occurencies of message keys with message lookups (i.e. lang::util::suggest_key Suggest a key for given text. lang::util::translator_mode_p Whether translator mode is enabled for this session or not. lang::util::translator_mode_set Sets whether translator mode is enabled for this session or not. lc_get Get a certain format string for the current locale. lc_leading_space Inserts a leading space for numbers less than 10. lc_leading_zeros Adds leading zeros to an integer to give it the desired number of digits lc_list_all_timezones lc_numeric Given a number and a locale return a formatted version of the number for that locale. lc_parse_number Converts a number to its canonical representation by stripping everything but the decimal separator and triming left 0's so it won't be octal. lc_sepfmt Called by lc_numeric and lc_monetary. lc_time_conn_to_system Converts a date from the connection's timezone to the system (database) timezone, using the OpenACS timezone setting and user's preference lc_time_drop_meridian Converts HH24 to HH12. lc_time_fmt Formats a time for the specified locale. lc_time_fmt_compile Compiles ISO 14652 LC_TIME style formatting string to variable substitions and proc calls. lc_time_local_to_utc Converts a local time to a UTC time for the specified timezone. lc_time_name_meridian Returns locale data depending on AM or PM. lc_time_system_to_conn Converts a date from the system (database) to the connection's timezone, using the OpenACS timezone setting and user's preference lc_time_tz_convert Converts a date from one timezone to another. lc_time_utc_to_local Converts a Universal Time to local time for the specified timezone. lc_wrap_sunday To go from 0(Sun) - 6(Sat) to 1(Mon) - 7(Sun) template::widget::select_locales Generate a select widget for locales.
www/ | |
admin/ | |
audit-include.adp | |
audit-include.tcl | |
batch-editor.adp | |
batch-editor.tcl | A quick and dirty batch editor for translation. |
edit-description.adp | |
edit-description.tcl | Edit description of message key. |
edit-history.adp | |
edit-history.tcl | A page displaying recent editing of translations. |
edit-localized-message.adp | |
edit-localized-message.tcl | Displays the localized message from the database for translation (displays an individual message) |
export-locale-to-files.adp | |
export-locale-to-files.tcl | Export all catalog messages for a given locale to the file system. |
export-messages.adp | |
export-messages.tcl | Export messages from the database to catalog files. |
import-locale-from-files.adp | |
import-locale-from-files.tcl | Import all catalog messages for a given locale from the file system. |
import-messages.adp | |
import-messages.tcl | Import messages from catalog files to the database. |
index.adp | |
index.tcl | Administration of the localized messages |
load-catalog-files.tcl | Load all catalog files. |
locale-delete.adp | |
locale-delete.tcl | Deletes a locale |
locale-edit.adp | |
locale-edit.tcl | Edits a locale |
locale-make-default.tcl | Makes a locale the default for its language |
locale-new.adp | |
locale-new.tcl | Creates a new locale |
locale-set-enabled-p.tcl | Sets enabled_p for a locale. |
locales-tabs.adp | |
localized-message-new.adp | |
localized-message-new.tcl | Displays the form for the creation of a new localized message. |
lookup.adp | |
lookup.tcl | Test message lookup |
lookups-include.adp | |
lookups-include.tcl | |
message-conflict-resolve.tcl | Mark conflict of an I18N message as resolved, i.e. |
message-conflict-revert.tcl | Revert the a message to the last overwritten version. |
message-conflicts.adp | |
message-conflicts.tcl | Show message conflicts resulting from message catalog imports. |
message-delete.adp | |
message-delete.tcl | Delete a message |
message-list.adp | |
message-list.tcl | Displays messages for translation |
message-search.adp | |
message-search.tcl | Search for localized messages containing a certain substring, in order to help translators ensure consistent terminology. |
message-usage-include.adp | |
message-usage-include.tcl | |
package-list.adp | |
package-list.tcl | Displays packages that contain messages. |
reload-cache.tcl | Load all catalog files. |
set-system-timezone.adp | |
set-system-timezone.tcl | Set the acs-lang system parameter which says what the local timezone offset is |
test/ | |
catalog-test.adp | |
catalog-test.tcl | Tests procedures in the lang package |
compile.tcl | |
format-test.adp | |
format-test.tcl | Tests procedures in the lang package |
show-catalog.adp | |
show-catalog.tcl | List contents of message catalog |
show.tcl | |
test.adp | |
test.tcl | Tests procedures in the lang package |
timezone.adp | |
timezone.tcl | Tests procedures in the lang package |
translator-mode.adp | |
translator-mode.tcl | Testing translator mode. |
tz-test.tcl | Test system timezone offset mechanism |
translator-mode-toggle.tcl | Toggle translator mode on/off. |
change-locale-include.adp | |
change-locale-include.tcl | |
change-locale.tcl | |
index.adp | |
index.tcl | Localization home |
locale-set.tcl | Sets a locale for the browser |
Calle Aprestadora 19, 12o-2a
08902 Hospitalet de Llobregat (Barcelona)
Spain
Tel Europe: +34 609 953 751
Tel US: +1 415 200 2465
Mail: info@project-open.com