2 Copyright © 1995-2011, The AROS Development Team. All rights reserved.
5 Desc: IsXXXX() - Stub for Language isXXXXX() functions.
8 #include "locale_intern.h"
9 #include <aros/asmcall.h>
10 #include <proto/locale.h>
12 /*****************************************************************************
15 #include <proto/locale.h>
17 AROS_LH2(BOOL, IsXXXX,
20 AROS_LHA(const struct Locale *, locale, A0),
21 AROS_LHA(ULONG, character, D0),
24 struct LocaleBase *, LocaleBase, 0, Locale)
27 These functions allow you to find out whether a character
28 matches a certain type according to the current Locale
31 The functions available are:
33 IsAlNum() - is this an alphanumeric character
34 IsAlpha() - is this an alphabet character
35 IsCntrl() - is this a control character
36 IsDigit() - is this a decimal digit character
37 IsGraph() - is this a graphical character
38 IsLower() - is this a lowercase character
39 IsPrint() - is this a printable character
40 IsPunct() - is this a punctuation character
41 IsSpace() - is this a whitespace character
42 IsUpper() - is this an uppercase character
43 IsXDigit() - is this a hexadecimal digit
46 locale - The Locale to use for this function.
47 character - the character to test
50 ind - An indication of whether the character matches the type.
51 TRUE - if the character is of the required type,
55 The Locale MUST be supplied.
57 These functions require a 32-bit character to support future
58 multi-byte character sets.
68 *****************************************************************************/
71 AROS_LH2(ULONG
, IsAlNum
,
72 AROS_LHA(struct Locale
*, locale
, A0
),
73 AROS_LHA(ULONG
, character
, D0
),
74 struct LocaleBase
*, LocaleBase
, 14, Locale
)
79 return AROS_CALL1(BOOL
, IntL(locale
)->il_LanguageFunctions
[4],
80 AROS_LCA(ULONG
, character
, D0
),
81 struct LocaleBase
*, LocaleBase
);
83 return AROS_UFC2(ULONG
, IntL(locale
)->il_LanguageFunctions
[4],
84 AROS_UFCA(ULONG
, character
, D0
),
85 AROS_UFCA(struct LocaleBase
*, LocaleBase
, A6
));
91 AROS_LH2(ULONG
, IsAlpha
,
92 AROS_LHA(struct Locale
*, locale
, A0
),
93 AROS_LHA(ULONG
, character
, D0
),
94 struct LocaleBase
*, LocaleBase
, 15, Locale
)
99 return AROS_CALL1(BOOL
, IntL(locale
)->il_LanguageFunctions
[5],
100 AROS_LCA(ULONG
, character
, D0
),
101 struct LocaleBase
*, LocaleBase
);
103 return AROS_UFC2(ULONG
, IntL(locale
)->il_LanguageFunctions
[5],
104 AROS_UFCA(ULONG
, character
, D0
),
105 AROS_UFCA(struct LocaleBase
*, LocaleBase
, A6
));
111 AROS_LH2(ULONG
, IsCntrl
,
112 AROS_LHA(struct Locale
*, locale
, A0
),
113 AROS_LHA(ULONG
, character
, D0
),
114 struct LocaleBase
*, LocaleBase
, 16, Locale
)
119 return AROS_CALL1(BOOL
, IntL(locale
)->il_LanguageFunctions
[6],
120 AROS_LCA(ULONG
, character
, D0
),
121 struct LocaleBase
*, LocaleBase
);
123 return AROS_UFC2(ULONG
, IntL(locale
)->il_LanguageFunctions
[6],
124 AROS_UFCA(ULONG
, character
, D0
),
125 AROS_UFCA(struct LocaleBase
*, LocaleBase
, A6
));
131 AROS_LH2(ULONG
, IsDigit
,
132 AROS_LHA(struct Locale
*, locale
, A0
),
133 AROS_LHA(ULONG
, character
, D0
),
134 struct LocaleBase
*, LocaleBase
, 17, Locale
)
139 return AROS_CALL1(BOOL
, IntL(locale
)->il_LanguageFunctions
[7],
140 AROS_LCA(ULONG
, character
, D0
),
141 struct LocaleBase
*, LocaleBase
);
143 return AROS_UFC2(ULONG
, IntL(locale
)->il_LanguageFunctions
[7],
144 AROS_UFCA(ULONG
, character
, D0
),
145 AROS_UFCA(struct LocaleBase
*, LocaleBase
, A6
));
151 AROS_LH2(ULONG
, IsGraph
,
152 AROS_LHA(struct Locale
*, locale
, A0
),
153 AROS_LHA(ULONG
, character
, D0
),
154 struct LocaleBase
*, LocaleBase
, 18, Locale
)
159 return AROS_CALL1(BOOL
, IntL(locale
)->il_LanguageFunctions
[8],
160 AROS_LCA(ULONG
, character
, D0
),
161 struct LocaleBase
*, LocaleBase
);
163 return AROS_UFC2(ULONG
, IntL(locale
)->il_LanguageFunctions
[8],
164 AROS_UFCA(ULONG
, character
, D0
),
165 AROS_UFCA(struct LocaleBase
*, LocaleBase
, A6
));
171 AROS_LH2(ULONG
, IsLower
,
172 AROS_LHA(struct Locale
*, locale
, A0
),
173 AROS_LHA(ULONG
, character
, D0
),
174 struct LocaleBase
*, LocaleBase
, 19, Locale
)
179 return AROS_CALL1(BOOL
, IntL(locale
)->il_LanguageFunctions
[9],
180 AROS_LCA(ULONG
, character
, D0
),
181 struct LocaleBase
*, LocaleBase
);
183 return AROS_UFC2(ULONG
, IntL(locale
)->il_LanguageFunctions
[9],
184 AROS_UFCA(ULONG
, character
, D0
),
185 AROS_UFCA(struct LocaleBase
*, LocaleBase
, A6
));
191 AROS_LH2(ULONG
, IsPrint
,
192 AROS_LHA(struct Locale
*, locale
, A0
),
193 AROS_LHA(ULONG
, character
, D0
),
194 struct LocaleBase
*, LocaleBase
, 20, Locale
)
199 return AROS_CALL1(BOOL
, IntL(locale
)->il_LanguageFunctions
[10],
200 AROS_LCA(ULONG
, character
, D0
),
201 struct LocaleBase
*, LocaleBase
);
203 return AROS_UFC2(ULONG
, IntL(locale
)->il_LanguageFunctions
[10],
204 AROS_UFCA(ULONG
, character
, D0
),
205 AROS_UFCA(struct LocaleBase
*, LocaleBase
, A6
));
211 AROS_LH2(ULONG
, IsPunct
,
212 AROS_LHA(struct Locale
*, locale
, A0
),
213 AROS_LHA(ULONG
, character
, D0
),
214 struct LocaleBase
*, LocaleBase
, 21, Locale
)
219 return AROS_CALL1(BOOL
, IntL(locale
)->il_LanguageFunctions
[11],
220 AROS_LCA(ULONG
, character
, D0
),
221 struct LocaleBase
*, LocaleBase
);
223 return AROS_UFC2(ULONG
, IntL(locale
)->il_LanguageFunctions
[11],
224 AROS_UFCA(ULONG
, character
, D0
),
225 AROS_UFCA(struct LocaleBase
*, LocaleBase
, A6
));
231 AROS_LH2(ULONG
, IsSpace
,
232 AROS_LHA(struct Locale
*, locale
, A0
),
233 AROS_LHA(ULONG
, character
, D0
),
234 struct LocaleBase
*, LocaleBase
, 22, Locale
)
239 return AROS_CALL1(BOOL
, IntL(locale
)->il_LanguageFunctions
[12],
240 AROS_LCA(ULONG
, character
, D0
),
241 struct LocaleBase
*, LocaleBase
);
243 return AROS_UFC2(ULONG
, IntL(locale
)->il_LanguageFunctions
[12],
244 AROS_UFCA(ULONG
, character
, D0
),
245 AROS_UFCA(struct LocaleBase
*, LocaleBase
, A6
));
251 AROS_LH2(ULONG
, IsUpper
,
252 AROS_LHA(struct Locale
*, locale
, A0
),
253 AROS_LHA(ULONG
, character
, D0
),
254 struct LocaleBase
*, LocaleBase
, 23, Locale
)
259 return AROS_CALL1(BOOL
, IntL(locale
)->il_LanguageFunctions
[13],
260 AROS_LCA(ULONG
, character
, D0
),
261 struct LocaleBase
*, LocaleBase
);
263 return AROS_UFC2(ULONG
, IntL(locale
)->il_LanguageFunctions
[13],
264 AROS_UFCA(ULONG
, character
, D0
),
265 AROS_UFCA(struct LocaleBase
*, LocaleBase
, A6
));
271 AROS_LH2(ULONG
, IsXDigit
,
272 AROS_LHA(struct Locale
*, locale
, A0
),
273 AROS_LHA(ULONG
, character
, D0
),
274 struct LocaleBase
*, LocaleBase
, 24, Locale
)
279 return AROS_CALL1(BOOL
, IntL(locale
)->il_LanguageFunctions
[14],
280 AROS_LCA(ULONG
, character
, D0
),
281 struct LocaleBase
*, LocaleBase
);
283 return AROS_UFC2(ULONG
, IntL(locale
)->il_LanguageFunctions
[14],
284 AROS_UFCA(ULONG
, character
, D0
),
285 AROS_UFCA(struct LocaleBase
*, LocaleBase
, A6
));