# strings_type.h

Go to the documentation of this file.

    00001 /* $Id: strings_type.h 17629 2009-09-24 19:22:32Z rubidium $ */
    00002
    00005 #ifndef STRINGS_TYPE_H
    00006 #define STRINGS_TYPE_H
    00007
    00011 typedef uint16 StringID;
    00012 static const StringID INVALID_STRING_ID = 0xFFFF;
    00013 static const int MAX_CHAR_LENGTH = 4;
    00014
    00015 enum {
    00016   MAX_LANG = 64,
    00017 };
    00018
    00020 enum TextDirection {
    00021   TD_LTR,
    00022   TD_RTL,
    00023 };
    00024
    00026 struct Language {
    00027   char *name;
    00028   char *file;
    00029 };
    00030
    00032 struct DynamicLanguages {
    00033   int num;
    00034   int curr;
    00035   char curr_file[MAX_PATH];
    00036   TextDirection text_dir;
    00037   Language ent[MAX_LANG];
    00038 };
    00039
    00041 enum SpecialStrings {
    00042
    00043   /* special strings for town names. the town name is generated dynamically on request. */
    00044   SPECSTR_TOWNNAME_START     = 0x20C0,
    00045   SPECSTR_TOWNNAME_ENGLISH   = SPECSTR_TOWNNAME_START,
    00046   SPECSTR_TOWNNAME_FRENCH,
    00047   SPECSTR_TOWNNAME_GERMAN,
    00048   SPECSTR_TOWNNAME_AMERICAN,
    00049   SPECSTR_TOWNNAME_LATIN,
    00050   SPECSTR_TOWNNAME_SILLY,
    00051   SPECSTR_TOWNNAME_SWEDISH,
    00052   SPECSTR_TOWNNAME_DUTCH,
    00053   SPECSTR_TOWNNAME_FINNISH,
    00054   SPECSTR_TOWNNAME_POLISH,
    00055   SPECSTR_TOWNNAME_SLOVAK,
    00056   SPECSTR_TOWNNAME_NORWEGIAN,
    00057   SPECSTR_TOWNNAME_HUNGARIAN,
    00058   SPECSTR_TOWNNAME_AUSTRIAN,
    00059   SPECSTR_TOWNNAME_ROMANIAN,
    00060   SPECSTR_TOWNNAME_CZECH,
    00061   SPECSTR_TOWNNAME_SWISS,
    00062   SPECSTR_TOWNNAME_DANISH,
    00063   SPECSTR_TOWNNAME_TURKISH,
    00064   SPECSTR_TOWNNAME_ITALIAN,
    00065   SPECSTR_TOWNNAME_CATALAN,
    00066   SPECSTR_TOWNNAME_LAST      = SPECSTR_TOWNNAME_CATALAN,
    00067
    00068   /* special strings for player names on the form "TownName transport". */
    00069   SPECSTR_PLAYERNAME_START   = 0x70EA,
    00070   SPECSTR_PLAYERNAME_ENGLISH = SPECSTR_PLAYERNAME_START,
    00071   SPECSTR_PLAYERNAME_FRENCH,
    00072   SPECSTR_PLAYERNAME_GERMAN,
    00073   SPECSTR_PLAYERNAME_AMERICAN,
    00074   SPECSTR_PLAYERNAME_LATIN,
    00075   SPECSTR_PLAYERNAME_SILLY,
    00076   SPECSTR_PLAYERNAME_LAST    = SPECSTR_PLAYERNAME_SILLY,
    00077
    00078   SPECSTR_ANDCO_NAME         = 0x70E6,
    00079   SPECSTR_PRESIDENT_NAME     = 0x70E7,
    00080   SPECSTR_SONGNAME           = 0x70E8,
    00081
    00082   /* reserve MAX_LANG strings for the *.lng files */
    00083   SPECSTR_LANGUAGE_START     = 0x7100,
    00084   SPECSTR_LANGUAGE_END       = SPECSTR_LANGUAGE_START + MAX_LANG - 1,
    00085
    00086   /* reserve 32 strings for various screen resolutions */
    00087   SPECSTR_RESOLUTION_START   = SPECSTR_LANGUAGE_END + 1,
    00088   SPECSTR_RESOLUTION_END     = SPECSTR_RESOLUTION_START + 0x1F,
    00089
    00090   /* reserve 32 strings for screenshot formats */
    00091   SPECSTR_SCREENSHOT_START   = SPECSTR_RESOLUTION_END + 1,
    00092   SPECSTR_SCREENSHOT_END     = SPECSTR_SCREENSHOT_START + 0x1F,
    00093 };
    00094
    00095 #endif /* STRINGS_TYPE_H */