#include <wctype.h>
|
|
int
iswgraph (wint_t wch); |
The iswgraph() function tests whether ’wch’ is a visible wide-character i.e it belongs to class graph(see defns for definition).
The result of this function is undefined unless the argument is WEOF or a valid wchar_t value.
The functionality of this API is independent of the program’s 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<wctype.h>
#include<stdio.h>
int test_iswgraph()
{
int arr[]={’n’,’\f’, 0xe1, ’6’, ’ ’};
int i = 0;
int size = 5;
for( i=0; i<size; i++)
{
int ret = iswgraph(arr[i]);
if( (!ret) != 0 )
{
printf("\n%lc is not wide visible char ", arr[i]);
}
else
{
printf("\n%lc is wide visible char", arr[i]);
}
}
printf("\n");
}
Output
n is wide visible char
is not wide visible char
«¡ is wide visible char
6 is wide visible char
is not wide visible char
|
© 2008-2009 Nokia Corporation. All rights reserved. This documentation can be used in the connection with this Product to help and support the user. |