"Dmitry Timoshkov" dmitry@baikal.ru wrote:
IMHO RtlUpperChar has nothing to do for unicode chars. Is there a way to use Wine internal code page to do the conversion
without
converting to unicode and back?
Wine has only unicode case conversion tables and currently there is no
way
to avoid forth and back conversions.
My solution for this is:
/************************************************************************** * RtlUpperChar (NTDLL.@) */ CHAR WINAPI RtlUpperChar( CHAR ch ) { WCHAR wch;
wch = toupperW(((WCHAR) ch) & 0xff); if (wch >> 8) { return ch; } else { return (CHAR) wch; } }
This would mean: Some ISO Latin 1 characters would be converted additionally to 'a' .. 'z'.
I did a test on w2k trying to convert all chars between 0 and 255. The result was:
Just 'a' .. 'z' are converted to 'A' .. 'Z', all other characters remain unchanged.
I switched the machine between 'EN' (English) and 'DE' (German) and no difference. May be this was the wrong place to switch the locale / code pages ... My guess is:
RtlUpperChar does not take the locale into account. It always convertes just 'a' .. 'z' and nothing else.
Is this the right direction or did I miss something?
Greetings Thomas