4 * Copyright 1995 Martin von Loewis
7 /* At the moment, these are only empty stubs.
17 /***********************************************************************
18 * GetUserDefaultLCID (OLE2NLS.1)
20 DWORD WINAPI GetUserDefaultLCID()
22 /* Default sorting, neutral sublanguage */
30 /* Neutral language */
35 /***********************************************************************
36 * GetSystemDefaultLCID (OLE2NLS.2)
38 DWORD WINAPI GetSystemDefaultLCID()
40 return GetUserDefaultLCID();
43 /***********************************************************************
44 * GetUserDefaultLangID (OLE2NLS.3)
46 WORD WINAPI GetUserDefaultLangID()
48 return (WORD)GetUserDefaultLCID();
51 /***********************************************************************
52 * GetSystemDefaultLangID (OLE2NLS.4)
54 WORD WINAPI GetSystemDefaultLangID()
56 return GetUserDefaultLangID();
59 /***********************************************************************
60 * GetLocaleInfoA (OLE2NLS.5)
61 * Is the last parameter really WORD for Win16?
63 int WINAPI GetLocaleInfoA(DWORD lcid,DWORD LCType,LPSTR buf,WORD len)
67 dprintf_ole(stddeb,"GetLocaleInfoA(%8lX,%8lX,%p,%4X)\n",
69 /* Wine is supporting only the default locale */
70 if(lcid!=GetUserDefaultLCID())
72 dprintf_ole(stdnimp,"GetLocaleInfoA: Unknown locale\n");
75 /* As an option, we could obtain the value from win.ini.
76 This would not match the Wine compile-time option.
77 Also, not all identifiers are available from win.ini */
80 /* If we are through all of this, retLen should not be zero anymore.
81 If it is, the value is not supported */
82 #define LOCVAL(type,value) if(type==LCType) \
83 {retLen=strlen(value)+1;\
86 #define UNSUPPORTED(type) if(type==lcid)retString=#type;
88 /* I really wish I would know a better way to do this */
89 UNSUPPORTED(LOCALE_ILANGUAGE)
90 UNSUPPORTED(LOCALE_SLANGUAGE)
91 UNSUPPORTED(LOCALE_SENGLANGUAGE)
92 UNSUPPORTED(LOCALE_SABBREVLANGNAME)
93 UNSUPPORTED(LOCALE_SNATIVELANGNAME)
94 UNSUPPORTED(LOCALE_ICOUNTRY)
95 UNSUPPORTED(LOCALE_SCOUNTRY)
96 UNSUPPORTED(LOCALE_SENGCOUNTRY)
97 UNSUPPORTED(LOCALE_SABBREVCTRYNAME)
98 UNSUPPORTED(LOCALE_SNATIVECTRYNAME)
99 UNSUPPORTED(LOCALE_IDEFAULTLANGUAGE)
100 UNSUPPORTED(LOCALE_IDEFAULTCOUNTRY)
101 UNSUPPORTED(LOCALE_IDEFAULTCODEPAGE)
102 UNSUPPORTED(LOCALE_IDEFAULTANSICODEPAGE)
103 UNSUPPORTED(LOCALE_SLIST)
104 UNSUPPORTED(LOCALE_IMEASURE)
105 UNSUPPORTED(LOCALE_SDECIMAL)
106 UNSUPPORTED(LOCALE_STHOUSAND)
107 UNSUPPORTED(LOCALE_SGROUPING)
108 UNSUPPORTED(LOCALE_IDIGITS)
109 UNSUPPORTED(LOCALE_ILZERO)
110 UNSUPPORTED(LOCALE_INEGNUMBER)
111 UNSUPPORTED(LOCALE_SNATIVEDIGITS)
112 UNSUPPORTED(LOCALE_SCURRENCY)
113 UNSUPPORTED(LOCALE_SINTLSYMBOL)
114 UNSUPPORTED(LOCALE_SMONDECIMALSEP)
115 UNSUPPORTED(LOCALE_SMONTHOUSANDSEP)
116 UNSUPPORTED(LOCALE_SMONGROUPING)
117 UNSUPPORTED(LOCALE_ICURRDIGITS)
118 UNSUPPORTED(LOCALE_IINTLCURRDIGITS)
119 UNSUPPORTED(LOCALE_ICURRENCY)
120 UNSUPPORTED(LOCALE_INEGCURR)
121 UNSUPPORTED(LOCALE_SDATE)
122 UNSUPPORTED(LOCALE_STIME)
123 UNSUPPORTED(LOCALE_SSHORTDATE)
124 UNSUPPORTED(LOCALE_SLONGDATE)
125 UNSUPPORTED(LOCALE_STIMEFORMAT)
126 UNSUPPORTED(LOCALE_IDATE)
127 UNSUPPORTED(LOCALE_ILDATE)
128 UNSUPPORTED(LOCALE_ITIME)
129 UNSUPPORTED(LOCALE_ITIMEMARKPOSN)
130 UNSUPPORTED(LOCALE_ICENTURY)
131 UNSUPPORTED(LOCALE_ITLZERO)
132 UNSUPPORTED(LOCALE_IDAYLZERO)
133 UNSUPPORTED(LOCALE_IMONLZERO)
134 UNSUPPORTED(LOCALE_S1159)
135 UNSUPPORTED(LOCALE_S2359)
136 UNSUPPORTED(LOCALE_ICALENDARTYPE)
137 UNSUPPORTED(LOCALE_IOPTIONALCALENDAR)
138 UNSUPPORTED(LOCALE_IFIRSTDAYOFWEEK)
139 UNSUPPORTED(LOCALE_IFIRSTWEEKOFYEAR)
140 UNSUPPORTED(LOCALE_SDAYNAME1)
141 UNSUPPORTED(LOCALE_SDAYNAME2)
142 UNSUPPORTED(LOCALE_SDAYNAME3)
143 UNSUPPORTED(LOCALE_SDAYNAME4)
144 UNSUPPORTED(LOCALE_SDAYNAME5)
145 UNSUPPORTED(LOCALE_SDAYNAME6)
146 UNSUPPORTED(LOCALE_SDAYNAME7)
147 UNSUPPORTED(LOCALE_SABBREVDAYNAME1)
148 UNSUPPORTED(LOCALE_SABBREVDAYNAME2)
149 UNSUPPORTED(LOCALE_SABBREVDAYNAME3)
150 UNSUPPORTED(LOCALE_SABBREVDAYNAME4)
151 UNSUPPORTED(LOCALE_SABBREVDAYNAME5)
152 UNSUPPORTED(LOCALE_SABBREVDAYNAME6)
153 UNSUPPORTED(LOCALE_SABBREVDAYNAME7)
154 UNSUPPORTED(LOCALE_SMONTHNAME1)
155 UNSUPPORTED(LOCALE_SMONTHNAME2)
156 UNSUPPORTED(LOCALE_SMONTHNAME3)
157 UNSUPPORTED(LOCALE_SMONTHNAME4)
158 UNSUPPORTED(LOCALE_SMONTHNAME5)
159 UNSUPPORTED(LOCALE_SMONTHNAME6)
160 UNSUPPORTED(LOCALE_SMONTHNAME7)
161 UNSUPPORTED(LOCALE_SMONTHNAME8)
162 UNSUPPORTED(LOCALE_SMONTHNAME9)
163 UNSUPPORTED(LOCALE_SMONTHNAME10)
164 UNSUPPORTED(LOCALE_SMONTHNAME11)
165 UNSUPPORTED(LOCALE_SMONTHNAME12)
166 UNSUPPORTED(LOCALE_SMONTHNAME13)
167 UNSUPPORTED(LOCALE_SABBREVMONTHNAME1)
168 UNSUPPORTED(LOCALE_SABBREVMONTHNAME2)
169 UNSUPPORTED(LOCALE_SABBREVMONTHNAME3)
170 UNSUPPORTED(LOCALE_SABBREVMONTHNAME4)
171 UNSUPPORTED(LOCALE_SABBREVMONTHNAME5)
172 UNSUPPORTED(LOCALE_SABBREVMONTHNAME6)
173 UNSUPPORTED(LOCALE_SABBREVMONTHNAME7)
174 UNSUPPORTED(LOCALE_SABBREVMONTHNAME8)
175 UNSUPPORTED(LOCALE_SABBREVMONTHNAME9)
176 UNSUPPORTED(LOCALE_SABBREVMONTHNAME10)
177 UNSUPPORTED(LOCALE_SABBREVMONTHNAME11)
178 UNSUPPORTED(LOCALE_SABBREVMONTHNAME12)
179 UNSUPPORTED(LOCALE_SABBREVMONTHNAME13)
180 UNSUPPORTED(LOCALE_SPOSITIVESIGN)
181 UNSUPPORTED(LOCALE_SNEGATIVESIGN)
182 UNSUPPORTED(LOCALE_IPOSSIGNPOSN)
183 UNSUPPORTED(LOCALE_INEGSIGNPOSN)
184 UNSUPPORTED(LOCALE_IPOSSYMPRECEDES)
185 UNSUPPORTED(LOCALE_IPOSSEPBYSPACE)
186 UNSUPPORTED(LOCALE_INEGSYMPRECEDES)
187 UNSUPPORTED(LOCALE_INEGSEPBYSPACE)
189 /* Now, the language specific definitions. They don't have to be
192 /* This definitions apply to Germany only. Users in Austria
193 or Switzerland might want to modify them */
194 LOCVAL(LOCALE_ILANGUAGE,"9")
195 LOCVAL(LOCALE_SLANGUAGE,"Deutsch")
196 LOCVAL(LOCALE_SENGLANGUAGE,"German")
197 LOCVAL(LOCALE_SABBREVLANGNAME,"deu")
198 LOCVAL(LOCALE_SNATIVELANGNAME,"Deutsch")
199 LOCVAL(LOCALE_ICOUNTRY,"49")
200 LOCVAL(LOCALE_SCOUNTRY,"Deutschland")
201 LOCVAL(LOCALE_SENGCOUNTRY,"Deutschland")
202 LOCVAL(LOCALE_SABBREVCTRYNAME,"De")
203 LOCVAL(LOCALE_SNATIVECTRYNAME,"Deutschland")
204 LOCVAL(LOCALE_IDEFAULTLANGUAGE,"9")
205 LOCVAL(LOCALE_IDEFAULTCOUNTRY,"49")
207 LOCVAL(LOCALE_IDEFAULTCODEPAGE)
208 LOCVAL(LOCALE_IDEFAULTANSICODEPAGE)
210 LOCVAL(LOCALE_SLIST,";")
211 LOCVAL(LOCALE_IMEASURE,"0")
212 LOCVAL(LOCALE_SDECIMAL,",")
213 LOCVAL(LOCALE_STHOUSAND,".")
215 LOCVAL(LOCALE_SGROUPING)
217 LOCVAL(LOCALE_IDIGITS,"2")
218 LOCVAL(LOCALE_ILZERO,"1")
220 LOCVAL(LOCALE_INEGNUMBER)
221 Is this "0123456789" ??
222 LOCVAL(LOCALE_SNATIVEDIGITS)
224 LOCVAL(LOCALE_SCURRENCY,"DM")
226 LOCVAL(LOCALE_SINTLSYMBOL)
227 LOCVAL(LOCALE_SMONDECIMALSEP)
228 LOCVAL(LOCALE_SMONTHOUSANDSEP)
229 LOCVAL(LOCALE_SMONGROUPING)
231 LOCVAL(LOCALE_ICURRDIGITS,"2")
233 LOCVAL(LOCALE_IINTLCURRDIGITS)
235 LOCVAL(LOCALE_ICURRENCY,"3")
236 LOCVAL(LOCALE_INEGCURR,"8")
237 LOCVAL(LOCALE_SDATE,".")
238 LOCVAL(LOCALE_STIME,":")
239 LOCVAL(LOCALE_SSHORTDATE,"dd.MM.yyyy")
240 LOCVAL(LOCALE_SLONGDATEi,"ddd, d. MMMM yyyy")
242 LOCVAL(LOCALE_STIMEFORMAT)
244 LOCVAL(LOCALE_IDATE,"1")
246 LOCVAL(LOCALE_ILDATE)
248 LOCVAL(LOCALE_ITIME,"1")
250 LOCVAL(LOCALE_ITIMEMARKPOSN)
251 LOCVAL(LOCALE_ICENTURY)
253 LOCVAL(LOCALE_ITLZERO,"1")
255 LOCVAL(LOCALE_IDAYLZERO)
256 LOCVAL(LOCALE_IMONLZERO)
259 LOCVAL(LOCALE_ICALENDARTYPE)
260 LOCVAL(LOCALE_IOPTIONALCALENDAR)
261 LOCVAL(LOCALE_IFIRSTDAYOFWEEK)
262 LOCVAL(LOCALE_IFIRSTWEEKOFYEAR)
264 LOCVAL(LOCALE_SDAYNAME1,"Montag")
265 LOCVAL(LOCALE_SDAYNAME2,"Dienstag")
266 LOCVAL(LOCALE_SDAYNAME3,"Mittwoch")
267 LOCVAL(LOCALE_SDAYNAME4,"Donnerstag")
268 LOCVAL(LOCALE_SDAYNAME5,"Freitag")
269 LOCVAL(LOCALE_SDAYNAME6,"Sonnabend")
270 LOCVAL(LOCALE_SDAYNAME7,"Sonntag")
271 LOCVAL(LOCALE_SABBREVDAYNAME1,"Mo")
272 LOCVAL(LOCALE_SABBREVDAYNAME2,"Di")
273 LOCVAL(LOCALE_SABBREVDAYNAME3,"Mi")
274 LOCVAL(LOCALE_SABBREVDAYNAME4,"Do")
275 LOCVAL(LOCALE_SABBREVDAYNAME5,"Fr")
276 LOCVAL(LOCALE_SABBREVDAYNAME6,"Sa")
277 LOCVAL(LOCALE_SABBREVDAYNAME7,"So")
278 LOCVAL(LOCALE_SMONTHNAME1,"Januar")
279 LOCVAL(LOCALE_SMONTHNAME2,"Februar")
280 LOCVAL(LOCALE_SMONTHNAME3,"März")
281 LOCVAL(LOCALE_SMONTHNAME4,"April")
282 LOCVAL(LOCALE_SMONTHNAME5,"Mai")
283 LOCVAL(LOCALE_SMONTHNAME6,"Juni")
284 LOCVAL(LOCALE_SMONTHNAME7,"Juli")
285 LOCVAL(LOCALE_SMONTHNAME8,"August")
286 LOCVAL(LOCALE_SMONTHNAME9,"September")
287 LOCVAL(LOCALE_SMONTHNAME10,"Oktober")
288 LOCVAL(LOCALE_SMONTHNAME11,"November")
289 LOCVAL(LOCALE_SMONTHNAME12,"Dezember")
290 LOCVAL(LOCALE_SMONTHNAME13,"")
291 LOCVAL(LOCALE_SABBREVMONTHNAME1,"Jan")
292 LOCVAL(LOCALE_SABBREVMONTHNAME2,"Feb")
293 LOCVAL(LOCALE_SABBREVMONTHNAME3,"Mär")
294 LOCVAL(LOCALE_SABBREVMONTHNAME4,"Apr")
295 LOCVAL(LOCALE_SABBREVMONTHNAME5,"Mai")
296 LOCVAL(LOCALE_SABBREVMONTHNAME6,"Jun")
297 LOCVAL(LOCALE_SABBREVMONTHNAME7,"Jul")
298 LOCVAL(LOCALE_SABBREVMONTHNAME8,"Aug")
299 LOCVAL(LOCALE_SABBREVMONTHNAME9,"Sep")
300 LOCVAL(LOCALE_SABBREVMONTHNAME10,"Okt")
301 LOCVAL(LOCALE_SABBREVMONTHNAME11,"Nov")
302 LOCVAL(LOCALE_SABBREVMONTHNAME12,"Dez")
303 LOCVAL(LOCALE_SABBREVMONTHNAME13,"")
305 LOCVAL(LOCALE_SPOSITIVESIGN)
306 LOCVAL(LOCALE_SNEGATIVESIGN)
307 LOCVAL(LOCALE_IPOSSIGNPOSN)
308 LOCVAL(LOCALE_INEGSIGNPOSN)
309 LOCVAL(LOCALE_IPOSSYMPRECEDES)
310 LOCVAL(LOCALE_IPOSSEPBYSPACE)
311 LOCVAL(LOCALE_INEGSYMPRECEDES)
312 LOCVAL(LOCALE_INEGSEPBYSPACE)
314 #endif /* LANG(De) */
316 /*Insert other languages here*/
322 if(!retString)fprintf(stderr,"Unkown LC type %lX\n",LCType);
323 else fprintf(stderr,"'%s' not supported for your language.\n",
328 if(retLen>len)retLen=len;
329 strncpy(buf,retString,len);