Letter Recognizer and keypress events

G

Guest

I have written a hangman game using the Compact Framework and I've
encountered a bug that I don't know how to fix.

When using the Letter Recognizer to input characters, as I'm writing the
letter i, I make an initial stroke down and the letter L appears on screen
and the stroke I just entered turns gray. If I then dot the i, the L
disappears and is replaced by an i.

In my game, I get the letter L as a keypress event, then I get an I. This
is obviously not what the user intended if they want to enter the letter I.
Does anyone know of a way to handle this correctly?

Thanks.
 
A

Alex Feinman [MVP]

Since the letter recognizer is expected to work with SIP-agnostic
applications, I expect that it sends backspace and then 'i'. I'm pretty sure
you could handle backspace. If for some reason you can't, consider refusing
to work with letter recognizer - insist on virtual keyboard. You can get the
currently selected input method by PInvoking SipGetCurrentIM

[DllImport("coredll")]
extern static bool SipGetCurrentIM(out Guid guidCurrent);
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top