]> git.ipfire.org Git - thirdparty/glibc.git/blob - locale/langinfo.h
Implement alternative month names (bug 10871).
[thirdparty/glibc.git] / locale / langinfo.h
1 /* Access to locale-dependent parameters.
2 Copyright (C) 1995-2018 Free Software Foundation, Inc.
3 This file is part of the GNU C Library.
4
5 The GNU C Library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Lesser General Public
7 License as published by the Free Software Foundation; either
8 version 2.1 of the License, or (at your option) any later version.
9
10 The GNU C Library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Lesser General Public License for more details.
14
15 You should have received a copy of the GNU Lesser General Public
16 License along with the GNU C Library; if not, see
17 <http://www.gnu.org/licenses/>. */
18
19 #ifndef _LANGINFO_H
20 #define _LANGINFO_H 1
21
22 /* Get the type definition. */
23 #include <nl_types.h>
24
25 #include <bits/locale.h> /* Define the __LC_* category names. */
26
27
28 __BEGIN_DECLS
29
30 /* Construct an `nl_item' value for `nl_langinfo' from a locale category
31 (LC_*) and an item index within the category. Some code may depend on
32 the item values within a category increasing monotonically with the
33 indices. */
34 #define _NL_ITEM(category, index) (((category) << 16) | (index))
35
36 /* Extract the category and item index from a constructed `nl_item' value. */
37 #define _NL_ITEM_CATEGORY(item) ((int) (item) >> 16)
38 #define _NL_ITEM_INDEX(item) ((int) (item) & 0xffff)
39
40 /* Enumeration of locale items that can be queried with `nl_langinfo'. */
41 enum
42 {
43 /* LC_TIME category: date and time formatting. */
44
45 /* Abbreviated days of the week. */
46 ABDAY_1 = _NL_ITEM (__LC_TIME, 0), /* Sun */
47 #define ABDAY_1 ABDAY_1
48 ABDAY_2,
49 #define ABDAY_2 ABDAY_2
50 ABDAY_3,
51 #define ABDAY_3 ABDAY_3
52 ABDAY_4,
53 #define ABDAY_4 ABDAY_4
54 ABDAY_5,
55 #define ABDAY_5 ABDAY_5
56 ABDAY_6,
57 #define ABDAY_6 ABDAY_6
58 ABDAY_7,
59 #define ABDAY_7 ABDAY_7
60
61 /* Long-named days of the week. */
62 DAY_1, /* Sunday */
63 #define DAY_1 DAY_1
64 DAY_2, /* Monday */
65 #define DAY_2 DAY_2
66 DAY_3, /* Tuesday */
67 #define DAY_3 DAY_3
68 DAY_4, /* Wednesday */
69 #define DAY_4 DAY_4
70 DAY_5, /* Thursday */
71 #define DAY_5 DAY_5
72 DAY_6, /* Friday */
73 #define DAY_6 DAY_6
74 DAY_7, /* Saturday */
75 #define DAY_7 DAY_7
76
77 /* Abbreviated month names. */
78 ABMON_1, /* Jan */
79 #define ABMON_1 ABMON_1
80 ABMON_2,
81 #define ABMON_2 ABMON_2
82 ABMON_3,
83 #define ABMON_3 ABMON_3
84 ABMON_4,
85 #define ABMON_4 ABMON_4
86 ABMON_5,
87 #define ABMON_5 ABMON_5
88 ABMON_6,
89 #define ABMON_6 ABMON_6
90 ABMON_7,
91 #define ABMON_7 ABMON_7
92 ABMON_8,
93 #define ABMON_8 ABMON_8
94 ABMON_9,
95 #define ABMON_9 ABMON_9
96 ABMON_10,
97 #define ABMON_10 ABMON_10
98 ABMON_11,
99 #define ABMON_11 ABMON_11
100 ABMON_12,
101 #define ABMON_12 ABMON_12
102
103 /* Long month names, in the grammatical form used when the month
104 is a part of a complete date. */
105 MON_1, /* January */
106 #define MON_1 MON_1
107 MON_2,
108 #define MON_2 MON_2
109 MON_3,
110 #define MON_3 MON_3
111 MON_4,
112 #define MON_4 MON_4
113 MON_5,
114 #define MON_5 MON_5
115 MON_6,
116 #define MON_6 MON_6
117 MON_7,
118 #define MON_7 MON_7
119 MON_8,
120 #define MON_8 MON_8
121 MON_9,
122 #define MON_9 MON_9
123 MON_10,
124 #define MON_10 MON_10
125 MON_11,
126 #define MON_11 MON_11
127 MON_12,
128 #define MON_12 MON_12
129
130 AM_STR, /* Ante meridiem string. */
131 #define AM_STR AM_STR
132 PM_STR, /* Post meridiem string. */
133 #define PM_STR PM_STR
134
135 D_T_FMT, /* Date and time format for strftime. */
136 #define D_T_FMT D_T_FMT
137 D_FMT, /* Date format for strftime. */
138 #define D_FMT D_FMT
139 T_FMT, /* Time format for strftime. */
140 #define T_FMT T_FMT
141 T_FMT_AMPM, /* 12-hour time format for strftime. */
142 #define T_FMT_AMPM T_FMT_AMPM
143
144 ERA, /* Alternate era. */
145 #define ERA ERA
146 __ERA_YEAR, /* Year in alternate era format. */
147 #ifdef __USE_GNU
148 # define ERA_YEAR __ERA_YEAR
149 #endif
150 ERA_D_FMT, /* Date in alternate era format. */
151 #define ERA_D_FMT ERA_D_FMT
152 ALT_DIGITS, /* Alternate symbols for digits. */
153 #define ALT_DIGITS ALT_DIGITS
154 ERA_D_T_FMT, /* Date and time in alternate era format. */
155 #define ERA_D_T_FMT ERA_D_T_FMT
156 ERA_T_FMT, /* Time in alternate era format. */
157 #define ERA_T_FMT ERA_T_FMT
158
159 _NL_TIME_ERA_NUM_ENTRIES, /* Number entries in the era arrays. */
160 _NL_TIME_ERA_ENTRIES, /* Structure with era entries in usable form.*/
161
162 _NL_WABDAY_1, /* Sun */
163 _NL_WABDAY_2,
164 _NL_WABDAY_3,
165 _NL_WABDAY_4,
166 _NL_WABDAY_5,
167 _NL_WABDAY_6,
168 _NL_WABDAY_7,
169
170 /* Long-named days of the week. */
171 _NL_WDAY_1, /* Sunday */
172 _NL_WDAY_2, /* Monday */
173 _NL_WDAY_3, /* Tuesday */
174 _NL_WDAY_4, /* Wednesday */
175 _NL_WDAY_5, /* Thursday */
176 _NL_WDAY_6, /* Friday */
177 _NL_WDAY_7, /* Saturday */
178
179 /* Abbreviated month names. */
180 _NL_WABMON_1, /* Jan */
181 _NL_WABMON_2,
182 _NL_WABMON_3,
183 _NL_WABMON_4,
184 _NL_WABMON_5,
185 _NL_WABMON_6,
186 _NL_WABMON_7,
187 _NL_WABMON_8,
188 _NL_WABMON_9,
189 _NL_WABMON_10,
190 _NL_WABMON_11,
191 _NL_WABMON_12,
192
193 /* Long month names, in the grammatical form used when the month
194 is a part of a complete date. */
195 _NL_WMON_1, /* January */
196 _NL_WMON_2,
197 _NL_WMON_3,
198 _NL_WMON_4,
199 _NL_WMON_5,
200 _NL_WMON_6,
201 _NL_WMON_7,
202 _NL_WMON_8,
203 _NL_WMON_9,
204 _NL_WMON_10,
205 _NL_WMON_11,
206 _NL_WMON_12,
207
208 _NL_WAM_STR, /* Ante meridiem string. */
209 _NL_WPM_STR, /* Post meridiem string. */
210
211 _NL_WD_T_FMT, /* Date and time format for strftime. */
212 _NL_WD_FMT, /* Date format for strftime. */
213 _NL_WT_FMT, /* Time format for strftime. */
214 _NL_WT_FMT_AMPM, /* 12-hour time format for strftime. */
215
216 _NL_WERA_YEAR, /* Year in alternate era format. */
217 _NL_WERA_D_FMT, /* Date in alternate era format. */
218 _NL_WALT_DIGITS, /* Alternate symbols for digits. */
219 _NL_WERA_D_T_FMT, /* Date and time in alternate era format. */
220 _NL_WERA_T_FMT, /* Time in alternate era format. */
221
222 _NL_TIME_WEEK_NDAYS,
223 _NL_TIME_WEEK_1STDAY,
224 _NL_TIME_WEEK_1STWEEK,
225 _NL_TIME_FIRST_WEEKDAY,
226 _NL_TIME_FIRST_WORKDAY,
227 _NL_TIME_CAL_DIRECTION,
228 _NL_TIME_TIMEZONE,
229
230 _DATE_FMT, /* strftime format for date. */
231 #define _DATE_FMT _DATE_FMT
232 _NL_W_DATE_FMT,
233
234 _NL_TIME_CODESET,
235
236 /* Long month names, in the grammatical form used when the month
237 is named by itself. */
238 __ALTMON_1, /* January */
239 __ALTMON_2,
240 __ALTMON_3,
241 __ALTMON_4,
242 __ALTMON_5,
243 __ALTMON_6,
244 __ALTMON_7,
245 __ALTMON_8,
246 __ALTMON_9,
247 __ALTMON_10,
248 __ALTMON_11,
249 __ALTMON_12,
250 #ifdef __USE_GNU
251 # define ALTMON_1 __ALTMON_1
252 # define ALTMON_2 __ALTMON_2
253 # define ALTMON_3 __ALTMON_3
254 # define ALTMON_4 __ALTMON_4
255 # define ALTMON_5 __ALTMON_5
256 # define ALTMON_6 __ALTMON_6
257 # define ALTMON_7 __ALTMON_7
258 # define ALTMON_8 __ALTMON_8
259 # define ALTMON_9 __ALTMON_9
260 # define ALTMON_10 __ALTMON_10
261 # define ALTMON_11 __ALTMON_11
262 # define ALTMON_12 __ALTMON_12
263 #endif
264
265 /* Long month names, in the grammatical form used when the month
266 is named by itself. */
267 _NL_WALTMON_1, /* January */
268 _NL_WALTMON_2,
269 _NL_WALTMON_3,
270 _NL_WALTMON_4,
271 _NL_WALTMON_5,
272 _NL_WALTMON_6,
273 _NL_WALTMON_7,
274 _NL_WALTMON_8,
275 _NL_WALTMON_9,
276 _NL_WALTMON_10,
277 _NL_WALTMON_11,
278 _NL_WALTMON_12,
279
280 _NL_NUM_LC_TIME, /* Number of indices in LC_TIME category. */
281
282 /* LC_COLLATE category: text sorting.
283 This information is accessed by the strcoll and strxfrm functions.
284 These `nl_langinfo' names are used only internally. */
285 _NL_COLLATE_NRULES = _NL_ITEM (__LC_COLLATE, 0),
286 _NL_COLLATE_RULESETS,
287 _NL_COLLATE_TABLEMB,
288 _NL_COLLATE_WEIGHTMB,
289 _NL_COLLATE_EXTRAMB,
290 _NL_COLLATE_INDIRECTMB,
291 _NL_COLLATE_GAP1,
292 _NL_COLLATE_GAP2,
293 _NL_COLLATE_GAP3,
294 _NL_COLLATE_TABLEWC,
295 _NL_COLLATE_WEIGHTWC,
296 _NL_COLLATE_EXTRAWC,
297 _NL_COLLATE_INDIRECTWC,
298 _NL_COLLATE_SYMB_HASH_SIZEMB,
299 _NL_COLLATE_SYMB_TABLEMB,
300 _NL_COLLATE_SYMB_EXTRAMB,
301 _NL_COLLATE_COLLSEQMB,
302 _NL_COLLATE_COLLSEQWC,
303 _NL_COLLATE_CODESET,
304 _NL_NUM_LC_COLLATE,
305
306 /* LC_CTYPE category: character classification.
307 This information is accessed by the functions in <ctype.h>.
308 These `nl_langinfo' names are used only internally. */
309 _NL_CTYPE_CLASS = _NL_ITEM (__LC_CTYPE, 0),
310 _NL_CTYPE_TOUPPER,
311 _NL_CTYPE_GAP1,
312 _NL_CTYPE_TOLOWER,
313 _NL_CTYPE_GAP2,
314 _NL_CTYPE_CLASS32,
315 _NL_CTYPE_GAP3,
316 _NL_CTYPE_GAP4,
317 _NL_CTYPE_GAP5,
318 _NL_CTYPE_GAP6,
319 _NL_CTYPE_CLASS_NAMES,
320 _NL_CTYPE_MAP_NAMES,
321 _NL_CTYPE_WIDTH,
322 _NL_CTYPE_MB_CUR_MAX,
323 _NL_CTYPE_CODESET_NAME,
324 CODESET = _NL_CTYPE_CODESET_NAME,
325 #define CODESET CODESET
326 _NL_CTYPE_TOUPPER32,
327 _NL_CTYPE_TOLOWER32,
328 _NL_CTYPE_CLASS_OFFSET,
329 _NL_CTYPE_MAP_OFFSET,
330 _NL_CTYPE_INDIGITS_MB_LEN,
331 _NL_CTYPE_INDIGITS0_MB,
332 _NL_CTYPE_INDIGITS1_MB,
333 _NL_CTYPE_INDIGITS2_MB,
334 _NL_CTYPE_INDIGITS3_MB,
335 _NL_CTYPE_INDIGITS4_MB,
336 _NL_CTYPE_INDIGITS5_MB,
337 _NL_CTYPE_INDIGITS6_MB,
338 _NL_CTYPE_INDIGITS7_MB,
339 _NL_CTYPE_INDIGITS8_MB,
340 _NL_CTYPE_INDIGITS9_MB,
341 _NL_CTYPE_INDIGITS_WC_LEN,
342 _NL_CTYPE_INDIGITS0_WC,
343 _NL_CTYPE_INDIGITS1_WC,
344 _NL_CTYPE_INDIGITS2_WC,
345 _NL_CTYPE_INDIGITS3_WC,
346 _NL_CTYPE_INDIGITS4_WC,
347 _NL_CTYPE_INDIGITS5_WC,
348 _NL_CTYPE_INDIGITS6_WC,
349 _NL_CTYPE_INDIGITS7_WC,
350 _NL_CTYPE_INDIGITS8_WC,
351 _NL_CTYPE_INDIGITS9_WC,
352 _NL_CTYPE_OUTDIGIT0_MB,
353 _NL_CTYPE_OUTDIGIT1_MB,
354 _NL_CTYPE_OUTDIGIT2_MB,
355 _NL_CTYPE_OUTDIGIT3_MB,
356 _NL_CTYPE_OUTDIGIT4_MB,
357 _NL_CTYPE_OUTDIGIT5_MB,
358 _NL_CTYPE_OUTDIGIT6_MB,
359 _NL_CTYPE_OUTDIGIT7_MB,
360 _NL_CTYPE_OUTDIGIT8_MB,
361 _NL_CTYPE_OUTDIGIT9_MB,
362 _NL_CTYPE_OUTDIGIT0_WC,
363 _NL_CTYPE_OUTDIGIT1_WC,
364 _NL_CTYPE_OUTDIGIT2_WC,
365 _NL_CTYPE_OUTDIGIT3_WC,
366 _NL_CTYPE_OUTDIGIT4_WC,
367 _NL_CTYPE_OUTDIGIT5_WC,
368 _NL_CTYPE_OUTDIGIT6_WC,
369 _NL_CTYPE_OUTDIGIT7_WC,
370 _NL_CTYPE_OUTDIGIT8_WC,
371 _NL_CTYPE_OUTDIGIT9_WC,
372 _NL_CTYPE_TRANSLIT_TAB_SIZE,
373 _NL_CTYPE_TRANSLIT_FROM_IDX,
374 _NL_CTYPE_TRANSLIT_FROM_TBL,
375 _NL_CTYPE_TRANSLIT_TO_IDX,
376 _NL_CTYPE_TRANSLIT_TO_TBL,
377 _NL_CTYPE_TRANSLIT_DEFAULT_MISSING_LEN,
378 _NL_CTYPE_TRANSLIT_DEFAULT_MISSING,
379 _NL_CTYPE_TRANSLIT_IGNORE_LEN,
380 _NL_CTYPE_TRANSLIT_IGNORE,
381 _NL_CTYPE_MAP_TO_NONASCII,
382 _NL_CTYPE_NONASCII_CASE,
383 _NL_CTYPE_EXTRA_MAP_1,
384 _NL_CTYPE_EXTRA_MAP_2,
385 _NL_CTYPE_EXTRA_MAP_3,
386 _NL_CTYPE_EXTRA_MAP_4,
387 _NL_CTYPE_EXTRA_MAP_5,
388 _NL_CTYPE_EXTRA_MAP_6,
389 _NL_CTYPE_EXTRA_MAP_7,
390 _NL_CTYPE_EXTRA_MAP_8,
391 _NL_CTYPE_EXTRA_MAP_9,
392 _NL_CTYPE_EXTRA_MAP_10,
393 _NL_CTYPE_EXTRA_MAP_11,
394 _NL_CTYPE_EXTRA_MAP_12,
395 _NL_CTYPE_EXTRA_MAP_13,
396 _NL_CTYPE_EXTRA_MAP_14,
397 _NL_NUM_LC_CTYPE,
398
399 /* LC_MONETARY category: formatting of monetary quantities.
400 These items each correspond to a member of `struct lconv',
401 defined in <locale.h>. */
402 __INT_CURR_SYMBOL = _NL_ITEM (__LC_MONETARY, 0),
403 #ifdef __USE_GNU
404 # define INT_CURR_SYMBOL __INT_CURR_SYMBOL
405 #endif
406 __CURRENCY_SYMBOL,
407 #ifdef __USE_GNU
408 # define CURRENCY_SYMBOL __CURRENCY_SYMBOL
409 #endif
410 __MON_DECIMAL_POINT,
411 #ifdef __USE_GNU
412 # define MON_DECIMAL_POINT __MON_DECIMAL_POINT
413 #endif
414 __MON_THOUSANDS_SEP,
415 #ifdef __USE_GNU
416 # define MON_THOUSANDS_SEP __MON_THOUSANDS_SEP
417 #endif
418 __MON_GROUPING,
419 #ifdef __USE_GNU
420 # define MON_GROUPING __MON_GROUPING
421 #endif
422 __POSITIVE_SIGN,
423 #ifdef __USE_GNU
424 # define POSITIVE_SIGN __POSITIVE_SIGN
425 #endif
426 __NEGATIVE_SIGN,
427 #ifdef __USE_GNU
428 # define NEGATIVE_SIGN __NEGATIVE_SIGN
429 #endif
430 __INT_FRAC_DIGITS,
431 #ifdef __USE_GNU
432 # define INT_FRAC_DIGITS __INT_FRAC_DIGITS
433 #endif
434 __FRAC_DIGITS,
435 #ifdef __USE_GNU
436 # define FRAC_DIGITS __FRAC_DIGITS
437 #endif
438 __P_CS_PRECEDES,
439 #ifdef __USE_GNU
440 # define P_CS_PRECEDES __P_CS_PRECEDES
441 #endif
442 __P_SEP_BY_SPACE,
443 #ifdef __USE_GNU
444 # define P_SEP_BY_SPACE __P_SEP_BY_SPACE
445 #endif
446 __N_CS_PRECEDES,
447 #ifdef __USE_GNU
448 # define N_CS_PRECEDES __N_CS_PRECEDES
449 #endif
450 __N_SEP_BY_SPACE,
451 #ifdef __USE_GNU
452 # define N_SEP_BY_SPACE __N_SEP_BY_SPACE
453 #endif
454 __P_SIGN_POSN,
455 #ifdef __USE_GNU
456 # define P_SIGN_POSN __P_SIGN_POSN
457 #endif
458 __N_SIGN_POSN,
459 #ifdef __USE_GNU
460 # define N_SIGN_POSN __N_SIGN_POSN
461 #endif
462 _NL_MONETARY_CRNCYSTR,
463 #define CRNCYSTR _NL_MONETARY_CRNCYSTR
464 __INT_P_CS_PRECEDES,
465 #ifdef __USE_GNU
466 # define INT_P_CS_PRECEDES __INT_P_CS_PRECEDES
467 #endif
468 __INT_P_SEP_BY_SPACE,
469 #ifdef __USE_GNU
470 # define INT_P_SEP_BY_SPACE __INT_P_SEP_BY_SPACE
471 #endif
472 __INT_N_CS_PRECEDES,
473 #ifdef __USE_GNU
474 # define INT_N_CS_PRECEDES __INT_N_CS_PRECEDES
475 #endif
476 __INT_N_SEP_BY_SPACE,
477 #ifdef __USE_GNU
478 # define INT_N_SEP_BY_SPACE __INT_N_SEP_BY_SPACE
479 #endif
480 __INT_P_SIGN_POSN,
481 #ifdef __USE_GNU
482 # define INT_P_SIGN_POSN __INT_P_SIGN_POSN
483 #endif
484 __INT_N_SIGN_POSN,
485 #ifdef __USE_GNU
486 # define INT_N_SIGN_POSN __INT_N_SIGN_POSN
487 #endif
488 _NL_MONETARY_DUO_INT_CURR_SYMBOL,
489 _NL_MONETARY_DUO_CURRENCY_SYMBOL,
490 _NL_MONETARY_DUO_INT_FRAC_DIGITS,
491 _NL_MONETARY_DUO_FRAC_DIGITS,
492 _NL_MONETARY_DUO_P_CS_PRECEDES,
493 _NL_MONETARY_DUO_P_SEP_BY_SPACE,
494 _NL_MONETARY_DUO_N_CS_PRECEDES,
495 _NL_MONETARY_DUO_N_SEP_BY_SPACE,
496 _NL_MONETARY_DUO_INT_P_CS_PRECEDES,
497 _NL_MONETARY_DUO_INT_P_SEP_BY_SPACE,
498 _NL_MONETARY_DUO_INT_N_CS_PRECEDES,
499 _NL_MONETARY_DUO_INT_N_SEP_BY_SPACE,
500 _NL_MONETARY_DUO_P_SIGN_POSN,
501 _NL_MONETARY_DUO_N_SIGN_POSN,
502 _NL_MONETARY_DUO_INT_P_SIGN_POSN,
503 _NL_MONETARY_DUO_INT_N_SIGN_POSN,
504 _NL_MONETARY_UNO_VALID_FROM,
505 _NL_MONETARY_UNO_VALID_TO,
506 _NL_MONETARY_DUO_VALID_FROM,
507 _NL_MONETARY_DUO_VALID_TO,
508 _NL_MONETARY_CONVERSION_RATE,
509 _NL_MONETARY_DECIMAL_POINT_WC,
510 _NL_MONETARY_THOUSANDS_SEP_WC,
511 _NL_MONETARY_CODESET,
512 _NL_NUM_LC_MONETARY,
513
514 /* LC_NUMERIC category: formatting of numbers.
515 These also correspond to members of `struct lconv'; see <locale.h>. */
516 __DECIMAL_POINT = _NL_ITEM (__LC_NUMERIC, 0),
517 #ifdef __USE_GNU
518 # define DECIMAL_POINT __DECIMAL_POINT
519 #endif
520 RADIXCHAR = __DECIMAL_POINT,
521 #define RADIXCHAR RADIXCHAR
522 __THOUSANDS_SEP,
523 #ifdef __USE_GNU
524 # define THOUSANDS_SEP __THOUSANDS_SEP
525 #endif
526 THOUSEP = __THOUSANDS_SEP,
527 #define THOUSEP THOUSEP
528 __GROUPING,
529 #ifdef __USE_GNU
530 # define GROUPING __GROUPING
531 #endif
532 _NL_NUMERIC_DECIMAL_POINT_WC,
533 _NL_NUMERIC_THOUSANDS_SEP_WC,
534 _NL_NUMERIC_CODESET,
535 _NL_NUM_LC_NUMERIC,
536
537 __YESEXPR = _NL_ITEM (__LC_MESSAGES, 0), /* Regex matching ``yes'' input. */
538 #define YESEXPR __YESEXPR
539 __NOEXPR, /* Regex matching ``no'' input. */
540 #define NOEXPR __NOEXPR
541 __YESSTR, /* Output string for ``yes''. */
542 #if defined __USE_GNU || (defined __USE_XOPEN && !defined __USE_XOPEN2K)
543 # define YESSTR __YESSTR
544 #endif
545 __NOSTR, /* Output string for ``no''. */
546 #if defined __USE_GNU || (defined __USE_XOPEN && !defined __USE_XOPEN2K)
547 # define NOSTR __NOSTR
548 #endif
549 _NL_MESSAGES_CODESET,
550 _NL_NUM_LC_MESSAGES,
551
552 _NL_PAPER_HEIGHT = _NL_ITEM (__LC_PAPER, 0),
553 _NL_PAPER_WIDTH,
554 _NL_PAPER_CODESET,
555 _NL_NUM_LC_PAPER,
556
557 _NL_NAME_NAME_FMT = _NL_ITEM (__LC_NAME, 0),
558 _NL_NAME_NAME_GEN,
559 _NL_NAME_NAME_MR,
560 _NL_NAME_NAME_MRS,
561 _NL_NAME_NAME_MISS,
562 _NL_NAME_NAME_MS,
563 _NL_NAME_CODESET,
564 _NL_NUM_LC_NAME,
565
566 _NL_ADDRESS_POSTAL_FMT = _NL_ITEM (__LC_ADDRESS, 0),
567 _NL_ADDRESS_COUNTRY_NAME,
568 _NL_ADDRESS_COUNTRY_POST,
569 _NL_ADDRESS_COUNTRY_AB2,
570 _NL_ADDRESS_COUNTRY_AB3,
571 _NL_ADDRESS_COUNTRY_CAR,
572 _NL_ADDRESS_COUNTRY_NUM,
573 _NL_ADDRESS_COUNTRY_ISBN,
574 _NL_ADDRESS_LANG_NAME,
575 _NL_ADDRESS_LANG_AB,
576 _NL_ADDRESS_LANG_TERM,
577 _NL_ADDRESS_LANG_LIB,
578 _NL_ADDRESS_CODESET,
579 _NL_NUM_LC_ADDRESS,
580
581 _NL_TELEPHONE_TEL_INT_FMT = _NL_ITEM (__LC_TELEPHONE, 0),
582 _NL_TELEPHONE_TEL_DOM_FMT,
583 _NL_TELEPHONE_INT_SELECT,
584 _NL_TELEPHONE_INT_PREFIX,
585 _NL_TELEPHONE_CODESET,
586 _NL_NUM_LC_TELEPHONE,
587
588 _NL_MEASUREMENT_MEASUREMENT = _NL_ITEM (__LC_MEASUREMENT, 0),
589 _NL_MEASUREMENT_CODESET,
590 _NL_NUM_LC_MEASUREMENT,
591
592 _NL_IDENTIFICATION_TITLE = _NL_ITEM (__LC_IDENTIFICATION, 0),
593 _NL_IDENTIFICATION_SOURCE,
594 _NL_IDENTIFICATION_ADDRESS,
595 _NL_IDENTIFICATION_CONTACT,
596 _NL_IDENTIFICATION_EMAIL,
597 _NL_IDENTIFICATION_TEL,
598 _NL_IDENTIFICATION_FAX,
599 _NL_IDENTIFICATION_LANGUAGE,
600 _NL_IDENTIFICATION_TERRITORY,
601 _NL_IDENTIFICATION_AUDIENCE,
602 _NL_IDENTIFICATION_APPLICATION,
603 _NL_IDENTIFICATION_ABBREVIATION,
604 _NL_IDENTIFICATION_REVISION,
605 _NL_IDENTIFICATION_DATE,
606 _NL_IDENTIFICATION_CATEGORY,
607 _NL_IDENTIFICATION_CODESET,
608 _NL_NUM_LC_IDENTIFICATION,
609
610 /* This marks the highest value used. */
611 _NL_NUM
612 };
613
614 /* This macro produces an item you can pass to `nl_langinfo' or
615 `nl_langinfo_l' to get the name of the locale in use for CATEGORY. */
616 #define _NL_LOCALE_NAME(category) _NL_ITEM ((category), \
617 _NL_ITEM_INDEX (-1))
618 #ifdef __USE_GNU
619 # define NL_LOCALE_NAME(category) _NL_LOCALE_NAME (category)
620 #endif
621
622
623 /* Return the current locale's value for ITEM.
624 If ITEM is invalid, an empty string is returned.
625
626 The string returned will not change until `setlocale' is called;
627 it is usually in read-only memory and cannot be modified. */
628
629 extern char *nl_langinfo (nl_item __item) __THROW;
630
631
632 #ifdef __USE_XOPEN2K8
633 /* POSIX.1-2008 extended locale interface (see locale.h). */
634 # include <bits/types/locale_t.h>
635
636 /* Just like nl_langinfo but get the information from the locale object L. */
637 extern char *nl_langinfo_l (nl_item __item, locale_t __l);
638 #endif
639
640 __END_DECLS
641
642 #endif /* langinfo.h */