An open-ended means of classifying characters. : Wide Character Functions « Wide Character String « C Tutorial






Header filewctype.h
Declarationwctype_t wctype(const char *attr);
int iswctype(wint_t ch, wctype_t attr_ob);


  1. alnum
  2. digit
  3. print
  4. upper
  5. alpha
  6. graph
  7. punct
  8. xdigit
  9. cntrl
  10. lower
  11. space

The following fragment demonstrates the wctype() and iswctype() functions:

#include <wctype.h>
#include <stdio.h>

int main(void){

  wctype_t x;

  x = wctype("space");

  if(iswctype(L' ', x)){
    printf("Is a space.\n");
  }

}

(C: The Complete Reference, Fourth Edition by Herbert Schildt McGraw-Hill/Osborne 2000 ISBN-10: 0072121246, ISBN-13: 978-0072121247)









16.1.Wide Character Functions
16.1.1.Wide-Character Functions
16.1.2.Wide-Character I/O Functions
16.1.3.Wide-Character String Functions
16.1.4.Wide-Character String Conversion Functions
16.1.5.Wide-Character Array Functions
16.1.6.Multibyte/Wide-Character Conversion Functions
16.1.7.An open-ended means of classifying characters.