[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[MiNT] wide characters



I remember a discussion about wide chars a year or 2 ago but I wasn't
really following it.

I am looking through more of the Highwire code and in the forms textareas
they are handled as WCHAR

#ifndef WCHAR
typedef unsigned short WCHAR;  /* 16-bit character, for BICS or Unicode */
#define WCHAR WCHAR
#endif

I'd like to be able to search these arrays for non alpha-num characters,
just for the basic task of Ctrl-Left & Ctrl-Right handling.

http://www.gnu.org/software/libtool/manual/libc/String_002fArray-Comparison.html

Are the wide string comparisons available on Mint ?
eg  Function: int wcsncmp (const wchar_t *ws1, const wchar_t *ws2, size_t size)

Will they work with the above unsigned short definition or would HW have to be
changed to use wchar_t  ?

I think the two types might be equivalent but I don't know how gcc will react.

Peter