src/strgen/strgen.h
author translators
Wed, 03 Dec 2008 19:31:15 +0000
changeset 10402 39aa6c6579b6
parent 10367 0098392a5560
permissions -rw-r--r--
(svn r14653) -Update: WebTranslator2 update to 2008-12-03 19:27:43
danish - 10 fixed by ThomasA (10)
indonesian - 48 fixed by fanioz (48)
-Fix: WebTranslator2 went haywire on Croatian/Danish.
10366
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
     1
/* $Id$ */
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
     2
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
     3
/** @file strgen.h Language pack header for strgen (needs to match). */
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
     4
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
     5
#ifndef STRGEN_H
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
     6
#define STRGEN_H
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
     7
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
     8
struct LanguagePackHeader {
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
     9
	uint32 ident;       // 32-bits identifier
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
    10
	uint32 version;     // 32-bits of auto generated version info which is basically a hash of strings.h
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
    11
	char name[32];      // the international name of this language
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
    12
	char own_name[32];  // the localized name of this language
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
    13
	char isocode[16];   // the ISO code for the language (not country code)
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
    14
	uint16 offsets[32]; // the offsets
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
    15
	byte plural_form;   // plural form index
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
    16
	byte text_dir;      // default direction of the text
10367
0098392a5560 (svn r14618) -Feature: when the chosen language isn't supported by the current font, try to find a font that does and use that instead. Thanks to glx/michi_cc for the Windows implementation.
rubidium
parents: 10366
diff changeset
    17
	/**
0098392a5560 (svn r14618) -Feature: when the chosen language isn't supported by the current font, try to find a font that does and use that instead. Thanks to glx/michi_cc for the Windows implementation.
rubidium
parents: 10366
diff changeset
    18
	 * Windows language ID:
0098392a5560 (svn r14618) -Feature: when the chosen language isn't supported by the current font, try to find a font that does and use that instead. Thanks to glx/michi_cc for the Windows implementation.
rubidium
parents: 10366
diff changeset
    19
	 * Windows cannot and will not convert isocodes to something it can use to
0098392a5560 (svn r14618) -Feature: when the chosen language isn't supported by the current font, try to find a font that does and use that instead. Thanks to glx/michi_cc for the Windows implementation.
rubidium
parents: 10366
diff changeset
    20
	 * determine whether a font can be used for the language or not. As a result
0098392a5560 (svn r14618) -Feature: when the chosen language isn't supported by the current font, try to find a font that does and use that instead. Thanks to glx/michi_cc for the Windows implementation.
rubidium
parents: 10366
diff changeset
    21
	 * of that we need to pass the language id via strgen to OpenTTD to tell
0098392a5560 (svn r14618) -Feature: when the chosen language isn't supported by the current font, try to find a font that does and use that instead. Thanks to glx/michi_cc for the Windows implementation.
rubidium
parents: 10366
diff changeset
    22
	 * what language it is in "Windows". The ID is the 'locale identifier' on:
0098392a5560 (svn r14618) -Feature: when the chosen language isn't supported by the current font, try to find a font that does and use that instead. Thanks to glx/michi_cc for the Windows implementation.
rubidium
parents: 10366
diff changeset
    23
	 *   http://msdn.microsoft.com/en-us/library/ms776294.aspx
0098392a5560 (svn r14618) -Feature: when the chosen language isn't supported by the current font, try to find a font that does and use that instead. Thanks to glx/michi_cc for the Windows implementation.
rubidium
parents: 10366
diff changeset
    24
	 */
0098392a5560 (svn r14618) -Feature: when the chosen language isn't supported by the current font, try to find a font that does and use that instead. Thanks to glx/michi_cc for the Windows implementation.
rubidium
parents: 10366
diff changeset
    25
	uint16 winlangid;   // windows language id
0098392a5560 (svn r14618) -Feature: when the chosen language isn't supported by the current font, try to find a font that does and use that instead. Thanks to glx/michi_cc for the Windows implementation.
rubidium
parents: 10366
diff changeset
    26
	/* byte pad[0];        // pad header to be a multiple of 4 */
10366
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
    27
};
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
    28
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
    29
assert_compile(sizeof(LanguagePackHeader) % 4 == 0);
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
    30
74b3472edfa4 (svn r14617) -Change: unduplicate the languagepack(header).
rubidium
parents:
diff changeset
    31
#endif /* STRGEN_H */