isgraph


isgraph

Ascertains whether a given character is graphic

 #include <ctype.h> int isgraph ( int c  ); 

The function isgraph( ) tests whether its character argument is a graphic character; that is, whether the value represents a printing character other than the space character. (In other words, the space character is considered printable, but not graphic.) If the character is graphic, isgraph( ) returns a nonzero value (that is, TRue); if not, the function returns 0 (false).

Whether a given character code represents a graphic character depends on the current locale setting for the category LC_CTYPE, which you can query or change using the setlocale( ) function.

Example

See the example for isprint( ) in this chapter.

See Also

The corresponding C99 function for wide characters, iswgraph( ); isalnum( ), isalpha( ), isblank( ), iscntrl( ), isdigit( ), islower( ), isprint( ), ispunct( ), isspace( ), isupper( ), isxdigit( ), setlocale( )



C(c) In a Nutshell
C in a Nutshell (In a Nutshell (OReilly))
ISBN: 0596006977
EAN: 2147483647
Year: 2006
Pages: 473

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net