Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members

Languages::Language Class Reference

Entry of the language list. More...

#include <language.hpp>

List of all members.

Public Member Functions

wxString getName () const
 Gets the name of the language.

wxString getShortName () const
 Gets the main language short name.

wxArrayString getShortNames () const
 Gets the language shorts names.

wxString getTranslatedName () const
 Gets the translated name of the language.

wxString getTranslatorName () const
 Gets the name of the translator (in latin-1 characters).

wxString getTranslatorNameInLocale () const
 Gets the name of the translator in the language.

 Language (const wxString &langName, const wxString &langNameTranslated, const wxArrayString &shortNames, const wxArrayInt &id, const wxString &locName, const wxString &translatorLat, const wxString &translatorLocale)
 Constructor.

 Language (const wxString &langName, const wxString &langNameTranslated, const wxString &shortName, const int id, const wxString &locName, const wxString &translatorLat, const wxString &translatorLocale)
 Constructor.

bool setLocale (wxLocale &loc, const wxString &shortName) const
 Changes the locale of the application with the given language.

bool setLocale (wxLocale &loc, const int language) const
 Changes the locale of the application with the given language.


Protected Attributes

wxArrayInt ids
 Identifiers for the languages.

wxString localeName
 Name of the locale (compiler dependant).

wxString name
 Name of the language.

wxString nameTranslated
 Name of the language (translated).

wxArrayString shorts
 Short names that can be used for the language.

wxString translator
 Name of the translator (in latin-1 characters).

wxString translatorLoc
 Name of the translator (in UTF-8 charset).


Private Member Functions

 Language ()
 Default constructor.


Detailed Description

Entry of the language list.

Never pass an instance of this class by value, always pass by reference or by adress.

Definition at line 65 of file language.hpp.


Constructor & Destructor Documentation

Languages::Language::Language  )  [inline, private]
 

Default constructor.

Definition at line 78 of file language.hpp.

Languages::Language::Language const wxString &  langName,
const wxString &  langNameTranslated,
const wxString &  shortName,
const int  id,
const wxString &  locName,
const wxString &  translatorLat,
const wxString &  translatorLocale
 

Constructor.

Parameters:
langName Name of the language.
langNameTranslated Name of the language (translated).
shortName Short name of the language.
id wxWidgets identifier of the language.
locName Name of the locale (dependant compiler). If empty, the wxWidgets identifier will be used to set the locale, else it is this locale name that will be used.
translatorLat Name of the translator (in latin-1 characters).
translatorLocale Name of the translator (in UTF-8 charset).

Definition at line 71 of file language.cpp.

References ids, localeName, name, nameTranslated, shorts, translator, and translatorLoc.

Languages::Language::Language const wxString &  langName,
const wxString &  langNameTranslated,
const wxArrayString &  shortNames,
const wxArrayInt &  id,
const wxString &  locName,
const wxString &  translatorLat,
const wxString &  translatorLocale
 

Constructor.

Caller must provide one or more short names and one or more language ids. This is not verified by this constructor.

Parameters:
langName Name of the language.
langNameTranslated Name of the language (translated).
shortNames Short names of the language.
id wxWidgets identifiers of the language.
locName Name of the locale (dependant compiler). If empty, the wxWidgets identifier will be used to set the locale, else it is this locale name that will be used.
translatorLat Name of the translator (in latin-1 characters).
translatorLocale Name of the translator (in UTF-8 charset).

Definition at line 105 of file language.cpp.

References ids, localeName, name, nameTranslated, shorts, translator, and translatorLoc.


Member Function Documentation

wxString Languages::Language::getName  )  const
 

Gets the name of the language.

Returns:
The name of the language.

Definition at line 189 of file language.cpp.

References name.

wxString Languages::Language::getShortName  )  const
 

Gets the main language short name.

Returns:
The main language short name.

Definition at line 225 of file language.cpp.

References shorts.

wxArrayString Languages::Language::getShortNames  )  const
 

Gets the language shorts names.

Returns:
The language shorts names.

Definition at line 213 of file language.cpp.

References shorts.

wxString Languages::Language::getTranslatedName  )  const
 

Gets the translated name of the language.

Returns:
The translated name of the language.

Definition at line 201 of file language.cpp.

References nameTranslated.

wxString Languages::Language::getTranslatorName  )  const
 

Gets the name of the translator (in latin-1 characters).

Returns:
The name of the translator (in latin-1 characters).

Definition at line 237 of file language.cpp.

References translator.

wxString Languages::Language::getTranslatorNameInLocale  )  const
 

Gets the name of the translator in the language.

Returns:
The name of the translator in the language.

Definition at line 249 of file language.cpp.

References translatorLoc.

bool Languages::Language::setLocale wxLocale &  loc,
const wxString &  shortName
const
 

Changes the locale of the application with the given language.

The locale is changed only if the given short name is present in this language instance.

Parameters:
loc The locale to change.
shortName Short name of the language.
Returns:
true if the locale has been changed, false otherwise.

Definition at line 165 of file language.cpp.

References ids, localeName, name, setLocale(), and shorts.

bool Languages::Language::setLocale wxLocale &  loc,
const int  language
const
 

Changes the locale of the application with the given language.

The locale is changed only if the given language id is present in this language instance.

Parameters:
loc The locale to change.
language Identifier of the language.
Returns:
true if the locale has been changed, false otherwise.

Definition at line 135 of file language.cpp.

References ids, localeName, name, setLocale(), and shorts.

Referenced by setLocale().


Member Data Documentation

wxArrayInt Languages::Language::ids [protected]
 

Identifiers for the languages.

Definition at line 71 of file language.hpp.

Referenced by Language(), and setLocale().

wxString Languages::Language::localeName [protected]
 

Name of the locale (compiler dependant).

Definition at line 72 of file language.hpp.

Referenced by Language(), and setLocale().

wxString Languages::Language::name [protected]
 

Name of the language.

Definition at line 68 of file language.hpp.

Referenced by getName(), Language(), and setLocale().

wxString Languages::Language::nameTranslated [protected]
 

Name of the language (translated).

Definition at line 69 of file language.hpp.

Referenced by getTranslatedName(), and Language().

wxArrayString Languages::Language::shorts [protected]
 

Short names that can be used for the language.

Definition at line 70 of file language.hpp.

Referenced by getShortName(), getShortNames(), Language(), and setLocale().

wxString Languages::Language::translator [protected]
 

Name of the translator (in latin-1 characters).

Definition at line 73 of file language.hpp.

Referenced by getTranslatorName(), and Language().

wxString Languages::Language::translatorLoc [protected]
 

Name of the translator (in UTF-8 charset).

Definition at line 74 of file language.hpp.

Referenced by getTranslatorNameInLocale(), and Language().


The documentation for this class was generated from the following files:
Generated on Sun May 30 13:38:05 2004 for wxChecksums by doxygen 1.3.7