]> pd.if.org Git - pdclib/blob - man3/wchar.h.3
dos2unix
[pdclib] / man3 / wchar.h.3
1 .\" This file is part of the Public Domain C Library " "PDCLib).
2 .\" Permission is granted to use" "modify" "and / or redistribute at will.
3 .\"
4 .Dd
5 .Dt WCHAR.H 3
6 .Os
7 .\"
8 .Sh NAME
9 .Nm wchar.h
10 .Nd wide character & wide character string manipulation
11 .\"
12 .Sh SYNOPSIS
13 .In wchar.h
14 .\"
15 .Sh DESCRIPTION
16 The
17 .In wchar.h
18 header provides functions for manipulating wide character strings" "for
19 converting between wide characters and multibyte character sets" "for 
20 manipulating wide character strings" "and for wide character oriented input and 
21 output.
22 .\"
23 .Ss Types & Definitions
24 The type
25 .Vt size_t
26 and macro
27 .Dv NULL
28 shall be defined as in
29 .In stddef.h .
30 .Pp
31 The type
32 .Vt wchar_t
33 shall be defined as an integral type capable of representing any wide character
34 in the implementation defined encoding. The type
35 .Vt wint_t
36 shall be defined as an integral type capable of representing any wide character
37 in the implementation defined encoding" "plus the distinct value given by
38 .Dv WEOF ,
39 which evaluates to a constant expression of type
40 .Vt wint_t
41 which does not correspond to any character in the implementation defined 
42 character set. The macros 
43 .Dv WCHAR_MIN
44 and
45 .Dv WCHAR_MAX
46 shall be defined as in
47 .In stdint.h .
48 .Pp
49 The type
50 .Vt mbstate_t
51 shall be a complete non-array object type used for the storage of the state of
52 a multibyte to wide character conversion.
53 .Pp
54 The type
55 .Vt struct tm
56 shall be defined as an incomplete type" "a full definition of wich can be found 
57 in
58 .In time.h .
59 .\"
60 .Ss Wide Character String Handling Functions
61 .Fn "wchar_t *wcscpy" "wchar_t *restrict s1" "const wchar_t *restrict s2"
62 .br
63 .Fn "wchar_t *wcsncpy" "wchar_t *restrict s1" "const wchar_t *restrict s2" "size_t n"
64 .br
65 .Fn "wchar_t *wmemcpy" "wchar_t *restrict s1" "const wchar_t *restrict s2" "size_t n"
66 .br
67 .Fn "wchar_t *wmemmove" "wchar_t *s1" "const wchar_t *s2" "size_t n"
68 .br
69 .Fn "wchar_t *wcscat" "wchar_t *restrict s1" "const wchar_t *restrict s2"
70 .br
71 .Fn "wchar_t *wcsncat" "wchar_t *restrict s1" "const wchar_t *restrict s2" "size_t n"
72 .br
73 .Fn "int wcscmp" "const wchar_t *s1" "const wchar_t *s2"
74 .br
75 .Fn "int wcscoll" "const wchar_t *s1" "const wchar_t *s2"
76 .br
77 .Fn "int wcsncmp" "const wchar_t *s1" "const wchar_t *s2" "size_t n"
78 .br
79 .Fn "size_t wcsxfrm" "wchar_t *restrict s1" "const wchar_t *restrict s2" "size_t n"
80 .br
81 .Fn "int wmemcmp" "const wchar_t *s1" "const wchar_t *s2" "size_t n"
82 .br
83 .Fn "wchar_t *wcschr" "const wchar_t *s" "wchar_t c"
84 .br
85 .Fn "size_t wcscspn" "const wchar_t *s1" "const wchar_t *s2"
86 .br
87 .Fn "wchar_t *wcspbrk" "const wchar_t *s1" "const wchar_t *s2"
88 .br
89 .Fn "wchar_t *wcsrchr" "const wchar_t *s" "wchar_t c"
90 .br
91 .Fn "size_t wcsspn" "const wchar_t *s1" "const wchar_t *s2"
92 .br
93 .Fn "wchar_t *wcsstr" "const wchar_t *s1" "const wchar_t *s2"
94 .br
95 .Fn "wchar_t *wcstok" "wchar_t *restrict s1" "const wchar_t *restrict s2" "wchar_t **restrict ptr"
96 .br
97 .Fn "wchar_t *wmemchr" "const wchar_t *s" "wchar_t c" "size_t n" 
98 .br
99 .Fn "size_t wcslen" "const wchar_t *s"
100 .br
101 .Fn "wchar_t *wmemset" "wchar_t *s" "wchar_t c" "size_t n"
102 .\"
103 .Ss Wide Character String Formatting
104 .Fn "int swprintf" "wchar_t *restrict s" "size_t n" "const wchar_t *restrict format" "..."
105 .br
106 .Fn "int swscanf" "const wchar_t *restrict s" "const wchar_t *restrict format" "..."
107 .br
108 .Fn "int vswprintf" "wchar_t *restrict s" "size_t n" "const wchar_t *restrict format" "va_list arg"
109 .br
110 .Fn "int vswscanf" "const wchar_t *restrict s" "const wchar_t *restrict format" "va_list arg"
111 .br
112 .Fn "size_t wcsftime" "wchar_t *restrict s" "size_t maxsize" "const wchar_t *restrict format" "const struct tm *restrict timeptr"
113 .\"
114 .Ss Wide Character Input and Output
115 .Fn "int fwprintf" "FILE *restrict stream" "const wchar_t *restrict format" "..."
116 .br
117 .Fn "int fwscanf" "FILE *restrict stream" "const wchar_t *restrict format" "..."
118 .br
119 .Fn "int vfwprintf" "FILE *restrict stream" "const wchar_t *restrict format" "va_list arg"
120 .br
121 .Fn "int vfwscanf" "FILE *restrict stream" "const wchar_t *restrict format" "va_list arg"
122 .br
123 .Fn "int vwprintf" "const wchar_t *restrict format" "va_list arg"
124 .br
125 .Fn "int vwscanf" "const wchar_t *restrict format" "va_list arg"
126 .br
127 .Fn "int wprintf" "const wchar_t *restrict format" "..."
128 .br
129 .Fn "int wscanf" "const wchar_t *restrict format" "..."
130 .br
131 .Fn "wint_t fgetwc" "FILE *stream"
132 .br
133 .Fn "wchar_t *fgetws" "wchar_t *restrict s" "int n" "FILE *restrict stream"
134 .br
135 .Fn "wint_t fputwc" "wchar_t c" "FILE *stream"
136 .br
137 .Fn "int fputws" "const wchar_t *restrict s" "FILE *restrict stream"
138 .br
139 .Fn "int fwide" "FILE *stream" "int mode"
140 .br
141 .Fn "wint_t getwc" "FILE *stream"
142 .br
143 .Fn "wint_t getwchar" "void"
144 .br
145 .Fn "wint_t putwc" "wchar_t c" "FILE *stream"
146 .br
147 .Fn "wint_t putwchar" "wchar_t c"
148 .br
149 .Fn "wint_t ungetwc" "wint_t c" "FILE *stream"
150 .\"
151 .Ss Wide Character String Parsing
152 .Fn "double wcstod" "const wchar_t *restrict nptr" "wchar_t **restrict endptr"
153 .br
154 .Fn "float wcstof" "const wchar_t *restrict nptr" "wchar_t **restrict endptr"
155 .br
156 .Fn "long double wcstold" "const wchar_t *restrict nptr" "wchar_t **restrict endptr"
157 .br
158 .Fn "long int wcstol" "const wchar_t *restrict nptr" "wchar_t **restrict endptr" "int base"
159 .br
160 .Fn "long long int wcstoll" "const wchar_t *restrict nptr" "wchar_t **restrict endptr" "int base"
161 .br
162 .Fn "unsigned long int wcstoul" "const wchar_t *restrict nptr" "wchar_t **restrict endptr" "int base"
163 .br
164 .Fn "unsigned long long int wcstoull" "const wchar_t *restrict nptr" "wchar_t **restrict endptr" "int base"
165 .\"
166 .Ss Character Set Conversion
167 .Fn "wint_t btowc" "int c"
168 .br
169 .Fn "int wctob" "wint_t c"
170 .br
171 .Fn "int mbsinit" "const mbstate_t *ps"
172 .br
173 .Fn "size_t mbrlen" "const char *restrict s" "size_t n" "mbstate_t *restrict ps"
174 .br
175 .Fn "size_t mbrtowc" "wchar_t *restrict pwc" "const char *restrict s" "size_t n" "mbstate_t *restrict ps"
176 .br
177 .Fn "size_t wcrtomb" "char *restrict s" "wchar_t wc" "mbstate_t *restrict ps"
178 .br
179 .Fn "size_t mbsrtowcs" "wchar_t *restrict dst" "const char **restrict src" "size_t len" "mbstate_t *restrict ps"
180 .br
181 .Fn "size_t wcsrtombs" "char *restrict dst" "const wchar_t **restrict src" "size_t len" "mbstate_t *restrict ps"
182 .\"
183 .Sh SEE ALSO
184 .Xr string.h 3
185 .Xr uchar.h 3
186 .Xr wcscpy 3
187 .Xr wcsncpy 3
188 .Xr wmemcpy 3
189 .Xr wmemmove 3
190 .Xr wcscat 3
191 .Xr wcsncat 3
192 .Xr wcscmp 3
193 .Xr wcscoll 3
194 .Xr wcsncmp 3
195 .Xr wcsxfrm 3
196 .Xr wmemcmp 3
197 .Xr wcschr 3
198 .Xr wcscspn 3
199 .Xr wcspbrk 3
200 .Xr wcsrchr 3
201 .Xr wcsspn 3
202 .Xr wcsstr 3
203 .Xr wcstok 3
204 .Xr wmemchr 3
205 .Xr wcslen 3
206 .Xr wmemset 3
207 .\"
208 .Xr swprintf 3
209 .Xr swscanf 3
210 .Xr vswprintf 3
211 .Xr vswscanf 3
212 .Xr wcsftime 3
213 .\"
214 .Xr fwprintf 3
215 .Xr fwscanf 3
216 .Xr vfwprintf 3
217 .Xr vfwscanf 3
218 .Xr vwprintf 3
219 .Xr vwscanf 3
220 .Xr wprintf 3
221 .Xr wscanf 3
222 .Xr fgetwc 3
223 .Xr fgetws 3
224 .Xr fputwc 3
225 .Xr fputws 3
226 .Xr fwide 3
227 .Xr getwc 3
228 .Xr getwchar 3
229 .Xr putwc 3
230 .Xr putwchar 3
231 .Xr ungetwc 3
232 .\"
233 .Xr wcstod 3
234 .Xr wcstof 3
235 .Xr wcstold 3
236 .Xr wcstol 3
237 .Xr wcstoll 3
238 .Xr wcstoul 3
239 .Xr wcstoull 3
240 .\"
241 .Xr btowc 3
242 .Xr wctomb 3
243 .Xr mbsinit 3
244 .Xr mbrlen 3
245 .Xr mbrtowc 3
246 .Xr wcrtomb 3
247 .Xr mbsrtowcs 3
248 .Xr wcsrtombs 3
249 .\"
250 .Sh STANDARDS
251 Conforming to
252 .St -isoC-amd1 ,
253 .St -isoC-99 and
254 .St -isoC-2011 .