Hi, I'm writing a Greek IME, which also needs to translate hardware keypresses. I'm doing this by intercepting onKeyDown() in InputMethodService.
Is there some way to find out what the caps state is (as indicated by the plain/triangle/caret cursor in the UI for lowercase/single-caps/ all-caps, respectively), so I can accordingly output upper or lower case characters? I checked the PinyinIME code in GIT and it tries to track the hardware keyboard shift state by monitoring KEYCODE_SHIFT_LEFT and KEYCODE_SHIFT_RIGHT keypresses -- and it can get out of sync with the true state indicated by the cursor, which can be confusing. So, the question is: 1. Do I also have to track hardware shift key-down events and duplicate the caps state logic, or is there a way to query the input connection what that state is? 2. If there is no way to query the caps state, then is there a way to reset it to lowercase (since I need to know what the initial caps state is when the IME starts). Thanks! Spiros --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---

