#include <ctype.h>
|
int
isgraph (int c); |
The functionality of this API is independent of the programs current locale and so it returns non-zero for all the characters (of various locales supported) that belong to the class graph, irrespective of the locale they belong to.
#include<ctype.h> //isgraph() #include<stdio.h> //printf() int test_isgraph() { int arr[]={n,\f, 6, }; int i = 0; int size = 4; for( i=0; i<size; i++) { int ret = isgraph(arr[i]); //call to API with chars in arr[] if( (!ret) != 0 ) { printf("\n%c is not visible char ", arr[i]); } else { printf("\n%c is visible char", arr[i]); } } printf("\n"); }
Output
n is visible char is not visible char 6 is visible char is not visible char
© 2008 Nokia Corporation. All rights reserved. This documentation can be used in the connection with this Product to help and support the user. |