In the android keyboard API, we find the following for keyboard XML files: android:codes The unicode value or comma-separated values that this key outputs.
Trying to put multiple comma-separated codes onto a key in the XML file like so: android:codes="0x0051,0x0057" Seems to break everything. In particular, onKey in the onKeyboardActionListener interface has two parameters, primaryCode and keyCodes. keyCodes is supposed to contain an array of all the keyCodes from the key pressed. When the XML file has only one code in android:codes, this works: primaryCode is the code in question, and keyCodes contains this primary code and is empty elsewhere. But when you try to put mutliple codes as above, both of these parameters are empty (0 for primaryCode, and an array of -1's for keyCodes). The documentation for onKey has this to say: "The codes for all the possible alternative keys with the primary code being the first. If the primary key code is a single character such as an alphabet or number or symbol, the alternatives will include other characters that may be on the same key or adjacent keys. These codes are useful to correct for accidental presses of a key adjacent to the intended key." so keyCodes seems to be designed to receive multiple keycodes. Any idea of what's not working? Thanks, Nick. -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en