Windows IME: Custom Korean Virtual Keyboard

I have a problem with Korean Windows IME. I am developing a virtual (on-screen / software) keyboard for a piece of firmware. I rely on Windows IME and it seems to work fine in Japanese and Chinese. It also works great with Korean if I use a physical keyboard.

But when I press the virtual keyboard button, mouse events seem to interfere with IME and basically just cancel the composition. The WM_IME_ENDCOMPOSITION message is triggered every time you click the mouse. As a result, I can only get individual Korean characters without the ability to combine them into words.

Does anyone know of any way to control this effect? How does a standard Windows soft keyboard bypass it? For a number of reasons, we cannot use the standard Windows soft keyboard in our product, and we need to develop our own.

Thanks.

+4
source share
1 answer

The end of the composition is caused by a VK_ProcessKey keyboard VK_ProcessKey . You can see this message after clicking the virtual key with spy ++.

Try connecting the function used to filter this message using the Windows SetWindowsHookEx API.

In my case, this method may work as we expected.

+2
source

All Articles