>
> Since PRUnichar*'s are just wchar_t*'s, can't you convert to multibyte
> string using libc wcstombs, walk through the char* converting each char
> using toupper and tolower libc calls then convert back using mbstowcs?
Gawd no way! bbaetz has already explained the typing issues, but I'll try to
explain the encoding issues:
"mbs" means "multi-byte" which means that each UCS2 character converts
to one OR MORE characters. This means if I have some PRUnichar* value
{ 0x4924, 0x4858, 0x4921 }
and these characters, respectively, convert to:
"A", "$j", "f9"
then when I upper case "j" or "f" and try to convert back to wchar_t, I get
"A", "$J", "F9"
which has a TOTALLY different meaning when converted back to UCS2..I
don't know if this explains it clearly enough (someone from i18n can
explain better) but it's just not that simple.
Alec