xref: /haiku/headers/posix/locale.h (revision 0fae873352b02792db93f721c1a2ff6b240c8ecc)
1*0fae8733SScott McCreary /*
2*0fae8733SScott McCreary  * Copyright 2002-2010 Haiku Inc. All Rights Reserved.
3*0fae8733SScott McCreary  * Distributed under the terms of the MIT License.
4*0fae8733SScott McCreary  */
5a3b20c0fSAxel Dörfler #ifndef _LOCALE_H_
6a3b20c0fSAxel Dörfler #define _LOCALE_H_
7*0fae8733SScott McCreary 
8a3b20c0fSAxel Dörfler 
9a3b20c0fSAxel Dörfler #include <null.h>
10a3b20c0fSAxel Dörfler 
11a3b20c0fSAxel Dörfler struct lconv {
12a3b20c0fSAxel Dörfler 	char *decimal_point;
13a3b20c0fSAxel Dörfler 	char *thousands_sep;
14a3b20c0fSAxel Dörfler 	char *grouping;
15a3b20c0fSAxel Dörfler 	char *int_curr_symbol;
16a3b20c0fSAxel Dörfler 	char *currency_symbol;
17a3b20c0fSAxel Dörfler 	char *mon_decimal_point;
18a3b20c0fSAxel Dörfler 	char *mon_thousands_sep;
19a3b20c0fSAxel Dörfler 	char *mon_grouping;
20a3b20c0fSAxel Dörfler 	char *positive_sign;
21a3b20c0fSAxel Dörfler 	char *negative_sign;
22a3b20c0fSAxel Dörfler 	char int_frac_digits;
23a3b20c0fSAxel Dörfler 	char frac_digits;
24a3b20c0fSAxel Dörfler 	char p_cs_precedes;
25a3b20c0fSAxel Dörfler 	char p_sep_by_space;
26a3b20c0fSAxel Dörfler 	char n_cs_precedes;
27a3b20c0fSAxel Dörfler 	char n_sep_by_space;
28a3b20c0fSAxel Dörfler 	char p_sign_posn;
29a3b20c0fSAxel Dörfler 	char n_sign_posn;
30a3f66598SOliver Tappe 	char int_p_cs_precedes;
31a3f66598SOliver Tappe 	char int_p_sep_by_space;
32a3f66598SOliver Tappe 	char int_n_cs_precedes;
33a3f66598SOliver Tappe 	char int_n_sep_by_space;
34a3f66598SOliver Tappe 	char int_p_sign_posn;
35a3f66598SOliver Tappe 	char int_n_sign_posn;
36a3b20c0fSAxel Dörfler };
37a3b20c0fSAxel Dörfler 
38a3b20c0fSAxel Dörfler #define	LC_ALL		0
39a3b20c0fSAxel Dörfler #define	LC_COLLATE	1
40a3b20c0fSAxel Dörfler #define	LC_CTYPE	2
41a3b20c0fSAxel Dörfler #define	LC_MONETARY	3
42a3b20c0fSAxel Dörfler #define	LC_NUMERIC	4
43a3b20c0fSAxel Dörfler #define	LC_TIME		5
44a3b20c0fSAxel Dörfler #define	LC_MESSAGES	6
45a3f66598SOliver Tappe /*
46a3f66598SOliver Tappe  * the values above must be kept in loopable order (i.e. strictly increasing
47a3f66598SOliver Tappe  * with no holes) and in sync with the value below
48a3f66598SOliver Tappe  */
49a3f66598SOliver Tappe #define	LC_LAST		LC_MESSAGES
50a3b20c0fSAxel Dörfler 
51a3b20c0fSAxel Dörfler #ifdef __cplusplus
52a3b20c0fSAxel Dörfler extern "C" {
53a3b20c0fSAxel Dörfler #endif
54a3b20c0fSAxel Dörfler 
55a3b20c0fSAxel Dörfler extern struct lconv *localeconv(void);
56a3b20c0fSAxel Dörfler extern char *setlocale(int category, const char *locale);
57a3b20c0fSAxel Dörfler 
58a3b20c0fSAxel Dörfler #ifdef __cplusplus
59a3b20c0fSAxel Dörfler }
60a3b20c0fSAxel Dörfler #endif
61a3b20c0fSAxel Dörfler 
62a3b20c0fSAxel Dörfler #endif /* _LOCALE_H_ */
63