Internationalization
The modules described in this chapter help you write software that is independent of language and locale by providing mechanisms for selecting a language to be used in program messages or by tailoring output to match local conventions.
The list of modules described in this chapter is:
gettext
— Multilingual internationalization services- GNU gettext API
- Class-based API
find()
translation()
install()
- The
NullTranslations
classNullTranslations
NullTranslations._parse()
NullTranslations.add_fallback()
NullTranslations.gettext()
NullTranslations.ngettext()
NullTranslations.pgettext()
NullTranslations.npgettext()
NullTranslations.lgettext()
NullTranslations.lngettext()
NullTranslations.info()
NullTranslations.charset()
NullTranslations.output_charset()
NullTranslations.set_output_charset()
NullTranslations.install()
- The
GNUTranslations
class - Solaris message catalog support
- The Catalog constructor
- Internationalizing your programs and modules
- Acknowledgements
locale
— Internationalization servicesError
setlocale()
localeconv()
nl_langinfo()
getdefaultlocale()
getlocale()
getpreferredencoding()
normalize()
resetlocale()
strcoll()
strxfrm()
format_string()
format()
currency()
str()
delocalize()
atof()
atoi()
LC_CTYPE
LC_COLLATE
LC_TIME
LC_MONETARY
LC_MESSAGES
LC_NUMERIC
LC_ALL
CHAR_MAX
- Background, details, hints, tips and caveats
- For extension writers and programs that embed Python
- Access to message catalogs