date and time created 91/03/06 18:09:53 by bostic
[unix-history] / usr / src / lib / libc / locale / ctype.3
index a8b648c..7185fde 100644 (file)
@@ -1,9 +1,9 @@
-.\"    @(#)ctype.3     4.1 (Berkeley) %G%
+.\"    @(#)ctype.3     6.4 (Berkeley) %G%
 .\"
 .\"
-.TH CTYPE 3 
+.TH CTYPE 3  ""
 .AT 3
 .SH NAME
 .AT 3
 .SH NAME
-isalpha, isupper, islower, isdigit, isalnum, isspace, ispunct, isprint, iscntrl, isascii \- character classification
+isalpha, isupper, islower, isdigit, isxdigit, isalnum, isspace, ispunct, isprint, isgraph, iscntrl, isascii, toupper, tolower, toascii \- character classification macros
 .SH SYNOPSIS
 .B #include <ctype.h>
 .PP
 .SH SYNOPSIS
 .B #include <ctype.h>
 .PP
@@ -16,12 +16,14 @@ by table lookup.
 Each is a predicate returning nonzero for true,
 zero for false.
 .I Isascii
 Each is a predicate returning nonzero for true,
 zero for false.
 .I Isascii
-is defined on all integer values; the rest
+and
+.I toascii
+are defined on all integer values; the rest
 are defined only where 
 .I isascii
 is true and on the single non-ASCII value
 EOF (see
 are defined only where 
 .I isascii
 is true and on the single non-ASCII value
 EOF (see
-.IR stdio (3)).
+.IR stdio (3S)).
 .TP 15n
 .I isalpha
 .I c
 .TP 15n
 .I isalpha
 .I c
@@ -39,13 +41,17 @@ is a lower case letter
 .I c
 is a digit
 .TP
 .I c
 is a digit
 .TP
+.I isxdigit
+.I c
+is a hex digit
+.TP
 .I isalnum
 .I c
 is an alphanumeric character
 .TP
 .I isspace
 .I c
 .I isalnum
 .I c
 is an alphanumeric character
 .TP
 .I isspace
 .I c
-is a space, tab, carriage return, newline, or formfeed
+is a space, tab, carriage return, newline, vertical tab, or formfeed
 .TP
 .I ispunct
 .I c
 .TP
 .I ispunct
 .I c
@@ -55,6 +61,12 @@ is a punctuation character (neither control nor alphanumeric)
 .I c
 is a printing character, code 040(8) (space) through 0176 (tilde)
 .TP
 .I c
 is a printing character, code 040(8) (space) through 0176 (tilde)
 .TP
+.I isgraph
+.I c
+is a printing character, similar to
+.I isprint
+except false for space.
+.TP
 .I iscntrl
 .I c
 is a delete character (0177) or ordinary control character
 .I iscntrl
 .I c
 is a delete character (0177) or ordinary control character
@@ -63,5 +75,19 @@ is a delete character (0177) or ordinary control character
 .I isascii
 .I c
 is an ASCII character, code less than 0200
 .I isascii
 .I c
 is an ASCII character, code less than 0200
+.TP
+.I tolower
+.I c
+is converted to lower case.  Return value is undefined if not 
+.I isupper(c).
+.TP
+.I toupper
+.I c
+is converted to upper case.  Return value is undefined if not 
+.I islower(c).
+.TP
+.I toascii
+.I c
+is converted to be a valid ascii character.
 .SH "SEE ALSO"
 ascii(7)
 .SH "SEE ALSO"
 ascii(7)