Fix subclassing to support nested messages.
[wine] / include / msvcrt / ctype.h
1 /*
2  * Character type definitions
3  *
4  * Derived from the mingw header written by Colin Peters.
5  * Modified for Wine use by Jon Griffiths and Francois Gouget.
6  * This file is in the public domain.
7  */
8 #ifndef __WINE_CTYPE_H
9 #define __WINE_CTYPE_H
10 #ifndef __WINE_USE_MSVCRT
11 #define __WINE_USE_MSVCRT
12 #endif
13
14 #ifndef MSVCRT
15 # ifdef USE_MSVCRT_PREFIX
16 #  define MSVCRT(x)    MSVCRT_##x
17 # else
18 #  define MSVCRT(x)    x
19 # endif
20 #endif
21
22 #ifdef __cplusplus
23 extern "C" {
24 #endif
25
26 #ifndef MSVCRT_WCHAR_T_DEFINED
27 #define MSVCRT_WCHAR_T_DEFINED
28 #ifndef __cplusplus
29 typedef unsigned short MSVCRT(wchar_t);
30 #endif
31 #endif
32
33 #ifndef USE_MSVCRT_PREFIX
34 # ifndef WEOF
35 #  define WEOF        (wint_t)(0xFFFF)
36 # endif
37 #else
38 # ifndef MSVCRT_WEOF
39 #  define MSVCRT_WEOF (MSVCRT_wint_t)(0xFFFF)
40 # endif
41 #endif /* USE_MSVCRT_PREFIX */
42
43 #ifndef MSVCRT_WCTYPE_T_DEFINED
44 typedef MSVCRT(wchar_t) MSVCRT(wint_t);
45 typedef MSVCRT(wchar_t) MSVCRT(wctype_t);
46 #define MSVCRT_WCTYPE_T_DEFINED
47 #endif
48
49 /* ASCII char classification table - binary compatible */
50 #define _UPPER        0x0001  /* C1_UPPER */
51 #define _LOWER        0x0002  /* C1_LOWER */
52 #define _DIGIT        0x0004  /* C1_DIGIT */
53 #define _SPACE        0x0008  /* C1_SPACE */
54 #define _PUNCT        0x0010  /* C1_PUNCT */
55 #define _CONTROL      0x0020  /* C1_CNTRL */
56 #define _BLANK        0x0040  /* C1_BLANK */
57 #define _HEX          0x0080  /* C1_XDIGIT */
58 #define _LEADBYTE     0x8000
59 #define _ALPHA       (0x0100|_UPPER|_LOWER)  /* (C1_ALPHA|_UPPER|_LOWER) */
60
61 int MSVCRT(__isascii)(int);
62 int MSVCRT(__iscsym)(int);
63 int MSVCRT(__iscsymf)(int);
64 int MSVCRT(__toascii)(int);
65 int MSVCRT(_isctype)(int,int);
66 int MSVCRT(_tolower)(int);
67 int MSVCRT(_toupper)(int);
68 int MSVCRT(isalnum)(int);
69 int MSVCRT(isalpha)(int);
70 int MSVCRT(iscntrl)(int);
71 int MSVCRT(isdigit)(int);
72 int MSVCRT(isgraph)(int);
73 int MSVCRT(islower)(int);
74 int MSVCRT(isprint)(int);
75 int MSVCRT(ispunct)(int);
76 int MSVCRT(isspace)(int);
77 int MSVCRT(isupper)(int);
78 int MSVCRT(isxdigit)(int);
79 int MSVCRT(tolower)(int);
80 int MSVCRT(toupper)(int);
81
82 #ifndef MSVCRT_WCTYPE_DEFINED
83 #define MSVCRT_WCTYPE_DEFINED
84 int MSVCRT(is_wctype)(MSVCRT(wint_t),MSVCRT(wctype_t));
85 int MSVCRT(isleadbyte)(int);
86 int MSVCRT(iswalnum)(MSVCRT(wint_t));
87 int MSVCRT(iswalpha)(MSVCRT(wint_t));
88 int MSVCRT(iswascii)(MSVCRT(wint_t));
89 int MSVCRT(iswcntrl)(MSVCRT(wint_t));
90 int MSVCRT(iswctype)(MSVCRT(wint_t),MSVCRT(wctype_t));
91 int MSVCRT(iswdigit)(MSVCRT(wint_t));
92 int MSVCRT(iswgraph)(MSVCRT(wint_t));
93 int MSVCRT(iswlower)(MSVCRT(wint_t));
94 int MSVCRT(iswprint)(MSVCRT(wint_t));
95 int MSVCRT(iswpunct)(MSVCRT(wint_t));
96 int MSVCRT(iswspace)(MSVCRT(wint_t));
97 int MSVCRT(iswupper)(MSVCRT(wint_t));
98 int MSVCRT(iswxdigit)(MSVCRT(wint_t));
99 MSVCRT(wchar_t) MSVCRT(towlower)(MSVCRT(wchar_t));
100 MSVCRT(wchar_t) MSVCRT(towupper)(MSVCRT(wchar_t));
101 #endif /* MSVCRT_WCTYPE_DEFINED */
102
103 #ifdef __cplusplus
104 }
105 #endif
106
107
108 #ifndef USE_MSVCRT_PREFIX
109 static inline int isascii(int c) { return __isascii(c); }
110 static inline int iscsym(int c) { return __iscsym(c); }
111 static inline int iscsymf(int c) { return __iscsymf(c); }
112 static inline int toascii(int c) { return __toascii(c); }
113 #endif /* USE_MSVCRT_PREFIX */
114
115 #endif /* __WINE_CTYPE_H */