2004-11-03 13:51:07 +00:00
|
|
|
.\" Copyright (c) Bruno Haible <haible@clisp.cons.org>
|
|
|
|
.\"
|
|
|
|
.\" This is free documentation; you can redistribute it and/or
|
|
|
|
.\" modify it under the terms of the GNU General Public License as
|
|
|
|
.\" published by the Free Software Foundation; either version 2 of
|
|
|
|
.\" the License, or (at your option) any later version.
|
|
|
|
.\"
|
|
|
|
.\" References consulted:
|
|
|
|
.\" GNU glibc-2 source code and manual
|
|
|
|
.\" Dinkumware C library reference http://www.dinkumware.com/
|
|
|
|
.\" OpenGroup's Single Unix specification http://www.UNIX-systems.org/online.html
|
|
|
|
.\" ISO/IEC 9899:1999
|
|
|
|
.\"
|
2009-02-03 03:26:43 +00:00
|
|
|
.TH WCTOB 3 2009-02-04 "GNU" "Linux Programmer's Manual"
|
2004-11-03 13:51:07 +00:00
|
|
|
.SH NAME
|
|
|
|
wctob \- try to represent a wide character as a single byte
|
|
|
|
.SH SYNOPSIS
|
|
|
|
.nf
|
|
|
|
.B #include <wchar.h>
|
|
|
|
.sp
|
|
|
|
.BI "int wctob(wint_t " c );
|
|
|
|
.fi
|
|
|
|
.SH DESCRIPTION
|
2007-05-12 09:06:04 +00:00
|
|
|
The
|
|
|
|
.BR wctob ()
|
|
|
|
function tests whether
|
getaddrinfo.3, setlocale.3, strchr.3, wctob.3, st.4, glob.7, locale.7, regex.7, standards.7, unicode.7, utf-8.7: Global fix: s/multi-/multi/
The tendency in English, as prescribed in style guides like
Chicago MoS, is towards removing hyphens after prefixes
like "multi-" etc.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2010-01-16 17:47:55 +00:00
|
|
|
the multibyte representation of the
|
2004-11-03 13:51:07 +00:00
|
|
|
wide character \fIc\fP, starting in the initial state, consists of a single
|
2007-04-12 22:42:49 +00:00
|
|
|
byte.
|
2007-12-13 20:46:52 +00:00
|
|
|
If so, it is returned as an
|
|
|
|
.IR "unsigned char" .
|
2004-11-03 13:51:07 +00:00
|
|
|
.PP
|
2007-04-12 22:42:49 +00:00
|
|
|
Never use this function.
|
|
|
|
It cannot help you in writing internationalized
|
|
|
|
programs.
|
|
|
|
Internationalized programs must never distinguish single-byte and
|
getaddrinfo.3, setlocale.3, strchr.3, wctob.3, st.4, glob.7, locale.7, regex.7, standards.7, unicode.7, utf-8.7: Global fix: s/multi-/multi/
The tendency in English, as prescribed in style guides like
Chicago MoS, is towards removing hyphens after prefixes
like "multi-" etc.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2010-01-16 17:47:55 +00:00
|
|
|
multibyte characters.
|
2004-11-03 13:51:07 +00:00
|
|
|
.SH "RETURN VALUE"
|
2007-05-12 09:06:04 +00:00
|
|
|
The
|
|
|
|
.BR wctob ()
|
|
|
|
function returns the single-byte representation of \fIc\fP,
|
2007-07-10 19:50:57 +00:00
|
|
|
if it exists, of \fBEOF\fP otherwise.
|
2004-11-03 13:51:07 +00:00
|
|
|
.SH "CONFORMING TO"
|
2006-08-03 13:57:30 +00:00
|
|
|
C99.
|
2004-11-03 13:51:07 +00:00
|
|
|
.SH NOTES
|
2007-06-08 09:56:56 +00:00
|
|
|
The behavior of
|
2007-05-12 09:06:04 +00:00
|
|
|
.BR wctob ()
|
2007-06-22 18:25:23 +00:00
|
|
|
depends on the
|
|
|
|
.B LC_CTYPE
|
|
|
|
category of the
|
2004-11-03 13:51:07 +00:00
|
|
|
current locale.
|
|
|
|
.PP
|
2007-04-12 22:42:49 +00:00
|
|
|
This function should never be used.
|
|
|
|
Internationalized programs must never
|
getaddrinfo.3, setlocale.3, strchr.3, wctob.3, st.4, glob.7, locale.7, regex.7, standards.7, unicode.7, utf-8.7: Global fix: s/multi-/multi/
The tendency in English, as prescribed in style guides like
Chicago MoS, is towards removing hyphens after prefixes
like "multi-" etc.
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
2010-01-16 17:47:55 +00:00
|
|
|
distinguish single-byte and multibyte characters.
|
2007-04-12 22:42:49 +00:00
|
|
|
Use the function
|
2007-05-12 09:06:04 +00:00
|
|
|
.BR wctomb (3)
|
|
|
|
instead.
|
2007-05-16 18:25:50 +00:00
|
|
|
.SH "SEE ALSO"
|
2009-02-03 03:27:14 +00:00
|
|
|
.BR btowc (3),
|
2007-05-16 18:25:50 +00:00
|
|
|
.BR wctomb (3)
|