Re: Windows IME support mysteries


Subject: Re: Windows IME support mysteries
From: Andrew Dunbar (hippietrail@yahoo.com)
Date: Sun Apr 15 2001 - 09:40:12 CDT


Mike Nordell wrote:
>
> Andrew Dunbar wrote:
> > If you try to enter Hiragana, Katakana, or Korean Hangul, you'll
> > just get "?" characters since these are language specific.
> >
> > I'm pretty sure the exact "implicit conversion" is happening with
> > WM_IME_CHAR.
> >
> > Okay so that's the treatise on the problem - does anybody know
> > what special trickery is required on Windows 2000?
>
> No, but perhaps some ideas can be found at
> http://mspress.microsoft.com/prod/books/sampchap/2323.htm
>
> Also, if you're using MSVC you could try spying on the keyboard events using
> Spy++ and see what differs between AW and sny other application.

Thanks for the URL. Spy++ didn't help. It looks like a slightly
undocumented solution is to call ImmGetCompositionStringW instead
of ImmGetCompositionString if I know I'm on a Unicode-enabled system.
My theory is that non Unicode-enabled systems will only support
a single IME so this may not be the final answer.

Two questions: What's the most correct way to test for Unicode-
enabled Windows? GetSystemMetrics doesn't have a test. I can think
of several hacky ways but there ought to be a standard way.

Is it safe for me to use emitChar / EventMapper::keystroke
since an IME can actually return an arbitrarily long string
instead of a single character? I'm not sure what assumptions
these functions really make.

Thanks for any enlightenment (:

Andrew.

-- 
http://linguaphile.sourceforge.net

_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com




This archive was generated by hypermail 2b25 : Sun Apr 15 2001 - 09:38:37 CDT