#include <nls.h>
Static Public Member Functions | |
| static void | init (config &myconfig) |
| Initialize national language support. | |
| static void | set_language (const string &language) |
| Set or change the language to use. | |
| static const char * | translate (const string &text) |
| Translate the given string if it's found in the message catalogue. | |
Definition at line 34 of file nls.h.
| void nls::init | ( | config & | myconfig | ) | [static] |
| void nls::set_language | ( | const string & | language | ) | [static] |
Set or change the language to use.
Setting the language will never fail, but only if there is a binary message catalogue in <gamedir>/po/<country code>="">LC_MESSAGES/ named <gamename>.mo the desired language will be actually used.
| language | The country code of the desired language. |
| const char * nls::translate | ( | const string & | text | ) | [static] |
Translate the given string if it's found in the message catalogue.
This is just a wrapper around the GNU gettext function for older versions of Python.
| text | The text to translate |
1.5.6