how can I catch a keypress of all characters that are on sw keyboards? Overriding onKeyDown() in the activity works only for standard ASCII characters like a-z0-9-!/... but doesn't work with all the UTF8 chars like ščřž (in that case this method is not called at all) I know the KeyEvent has a method getUnicodeChar(), which returns the unicode character that the key would produce. But I dont know how to get that KeyEvent when onKeyDown() is not called.
Asked
Active
Viewed 1,790 times
1 Answers
2
I have not tried it but there is a method called dispatchKeyEvent(KeyEvent event). I hope it will surely meet ur needs.

Vineet Shukla
- 23,865
- 10
- 55
- 63
-
THX it works, now I need to figure out, how to get UTF8 code of that special characters, because keyEvent.getUnicodeChar() returns 0 for them – martinpelant Jun 18 '11 at 09:23
-
u can use event.getKeycode() to get the keycode and use it as you want............. – Vineet Shukla Jun 19 '11 at 08:54