ReactOS  0.4.14-dev-342-gdc047f9
country.h
Go to the documentation of this file.
1 /*
2  * COPYRIGHT: GPL - See COPYING in the top level directory
3  * PROJECT: ReactOS Virtual DOS Machine
4  * FILE: subsystems/mvdm/ntvdm/dos/dos32krnl/country.h
5  * PURPOSE: DOS32 Country support
6  * PROGRAMMERS: Hermes Belusca-Maito (hermes.belusca@sfr.fr)
7  *
8  * NOTE: Support for default (english) language only.
9  * For other languages, please use COUNTRY.SYS
10  */
11 
12 #ifndef _COUNTRY_H_
13 #define _COUNTRY_H_
14 
15 /* DEFINITIONS ****************************************************************/
16 
17 #pragma pack(push, 1)
18 
19 #if 0 // Keep here for information purposes only
20 // DOS 2.00-2.10 country info structure
21 typedef struct _DOS_COUNTRY_INFO_OLD
22 {
23  WORD DateTimeFormat;
24  CHAR CurrencySymbol[2];
25  CHAR ThousandSep[2];
26  CHAR DecimalSep[2];
27  BYTE Reserved[24];
28 } DOS_COUNTRY_INFO_OLD, *PDOS_COUNTRY_INFO_OLD;
29 C_ASSERT(sizeof(DOS_COUNTRY_INFO_OLD) == 0x20);
30 #endif
31 
32 // DOS 2.11+ compatible country info structure
33 typedef struct _DOS_COUNTRY_INFO
34 {
48 C_ASSERT(sizeof(DOS_COUNTRY_INFO) == 0x22);
49 
50 typedef struct _DOS_COUNTRY_INFO_EX
51 {
57 C_ASSERT(sizeof(DOS_COUNTRY_INFO_EX) == 0x28);
58 
59 typedef struct _DOS_COUNTRY_INFO_2
60 {
62  union
63  {
65 
68 
71 
74  };
76 
77 #pragma pack(pop)
78 
79 /* FUNCTIONS ******************************************************************/
80 
81 WORD
82 DosGetCountryInfo(IN OUT PWORD CountryId,
83  OUT PDOS_COUNTRY_INFO CountryInfo);
84 
85 WORD
87  IN WORD CodePage,
88  IN WORD CountryId,
89  OUT PDOS_COUNTRY_INFO_2 CountryInfo,
91 
93 CHAR DosToUpper(CHAR Char);
94 VOID DosToUpperStrN(PCHAR DestStr, PCHAR SrcStr, WORD Length);
95 VOID DosToUpperStrZ(PSTR DestStr, PSTR SrcStr);
96 
98 
99 #endif /* _COUNTRY_H_ */
struct _DOS_COUNTRY_INFO * PDOS_COUNTRY_INFO
signed char * PCHAR
Definition: retypes.h:7
WORD DosGetCountryInfo(IN OUT PWORD CountryId, OUT PDOS_COUNTRY_INFO CountryInfo)
Definition: country.c:77
#define IN
Definition: typedefs.h:38
char CHAR
Definition: xmlstorage.h:175
struct _DOS_COUNTRY_INFO_2 * PDOS_COUNTRY_INFO_2
C_ASSERT(sizeof(DOS_COUNTRY_INFO)==0x22)
struct _DOS_COUNTRY_INFO DOS_COUNTRY_INFO
CHAR DosToUpper(CHAR Char)
Definition: country.c:218
DOS_COUNTRY_INFO_EX CountryInfoEx
Definition: country.h:64
DWORD FNameTermTblPtr
Definition: country.h:70
WORD DateTimeFormat
Definition: country.h:35
BYTE CurrencyFormat
Definition: country.h:41
BOOLEAN DosCountryInitialize(VOID)
Definition: country.c:236
BYTE CurrencyDigitsNum
Definition: country.h:42
unsigned char BOOLEAN
CHAR DecimalSep[2]
Definition: country.h:38
_Reserved_ PVOID Reserved
Definition: winddi.h:3974
struct _DOS_COUNTRY_INFO_EX * PDOS_COUNTRY_INFO_EX
CHAR DataListSep[2]
Definition: country.h:45
WORD * PWORD
Definition: pedump.c:67
WORD DosGetCountryInfoEx(IN BYTE InfoId, IN WORD CodePage, IN WORD CountryId, OUT PDOS_COUNTRY_INFO_2 CountryInfo, IN OUT PWORD BufferSize)
Definition: country.c:141
DWORD DBCSLeadTblPtr
Definition: country.h:73
#define BufferSize
Definition: classpnp.h:419
unsigned short WORD
Definition: ntddk_ex.h:93
unsigned long DWORD
Definition: ntddk_ex.h:95
_In_ ULONG _In_ ULONG _In_ ULONG Length
Definition: ntddpcm.h:101
CHAR DateSep[2]
Definition: country.h:39
unsigned char BYTE
Definition: mem.h:68
DOS_COUNTRY_INFO CountryInfo
Definition: country.h:55
DWORD LoCaseTblPtr
Definition: country.h:67
CHAR TimeSep[2]
Definition: country.h:40
DWORD CaseMapPtr
Definition: country.h:44
signed char * PSTR
Definition: retypes.h:7
#define OUT
Definition: typedefs.h:39
VOID DosToUpperStrN(PCHAR DestStr, PCHAR SrcStr, WORD Length)
Definition: country.c:224
CHAR CurrencySymbol[5]
Definition: country.h:36
WORD DosIfCharYesNo(WORD Char)
Definition: country.c:204
VOID DosToUpperStrZ(PSTR DestStr, PSTR SrcStr)
Definition: country.c:230
DWORD UpCaseTblPtr
Definition: country.h:66
struct _DOS_COUNTRY_INFO_2 DOS_COUNTRY_INFO_2
DWORD FNameUpCaseTblPtr
Definition: country.h:69
DWORD CollateTblPtr
Definition: country.h:72
CHAR ThousandSep[2]
Definition: country.h:37
struct _DOS_COUNTRY_INFO_EX DOS_COUNTRY_INFO_EX