Module languageHandler
[hide private]
[frames] | no frames]

Module languageHandler

source code

Functions [hide private]
integer
localeNameToWindowsLCID(localeName)
Retreave the Windows locale identifier (LCID) for the given locale name
source code
 
getLanguageDescription(language)
Finds out the description (licalized full name) of a given local name
source code
list of tuples
getAvailableLanguages()
generates a list of locale names, plus their full localized language and country names.
source code
 
setLanguage(lang) source code
 
getLanguage() source code
 
normalizeLanguage(lang)
Normalizes a language-dialect string in to a standard form we can deal with.
source code
Variables [hide private]
  LOCALE_SLANGUAGE = 0x2
  LOCALE_SLANGDISPLAYNAME = 0x6f
  curLang = "en"
Function Details [hide private]

localeNameToWindowsLCID(localeName)

source code 

Retreave the Windows locale identifier (LCID) for the given locale name

Parameters:
  • localeName (string) - a string of 2letterLanguage_2letterCountry or or just 2letterLanguage
Returns: integer
a Windows LCID

normalizeLanguage(lang)

source code 

Normalizes a language-dialect string in to a standard form we can deal with. Converts any dash to underline, and makes sure that language is lowercase and dialect is upercase.