Hi all, I need advice. Now I must to use combination Shift+Space to change language with hardware keyboard on my Desire Z, how can I use hardware button "Language"?
HTC Desire Z hardware keyboard
You cannot use this button at the moment, as it's specific to this phone.
Sent from my Nexus One using Tapatalk
Sent from my Nexus One using Tapatalk
This feature can be implemented in future releases?
+1
I would second this request to add language switch feature to hardware keyboards.
This should be a common request - there're lots of people with rooted phones and custom ROMs that still require dual language support on their Milestones, G1 and G2 \ Desire Z phones with hard keyboard.
Yet there's only one app on the market to suite the Russian-only community - http://www.appbrain.com/app/russian-key ... rukeyboard, but it has terrible portrait keyboard design.
So I'll by Smart KB as soon as you'll get this feature.
I would second this request to add language switch feature to hardware keyboards.
This should be a common request - there're lots of people with rooted phones and custom ROMs that still require dual language support on their Milestones, G1 and G2 \ Desire Z phones with hard keyboard.
Yet there's only one app on the market to suite the Russian-only community - http://www.appbrain.com/app/russian-key ... rukeyboard, but it has terrible portrait keyboard design.
So I'll by Smart KB as soon as you'll get this feature.
lexunus wrote:This should be a common request - there're lots of people with rooted phones and custom ROMs that still require dual language support on their Milestones, G1 and G2 \ Desire Z phones with hard keyboard.You are talking about something else: it's already possible to change the language on every phone using the shift + space combination. What this topic is about is to support the special "language" key which is present on the Desire Z.
Cyril, what about my question of future releases?
There are 2 requirements to implement this feature:
- The keyboard must receive an event when this key is pressed (knowing HTC, it's not sure they made this available outside of their own keyboard app)
- I need to known the key code of this language key. If you want to help, you can enable the debug logs in advanced options, and look for lines beginning with "keyCode: " in your phone logs (which you can get with "Log Collector" app or "adb logcat" command). If the event is received by the keyboard, you should be able to identify which code corresponds to this key, otherwise the feature will be more difficult to implement (though not impossible)
- The keyboard must receive an event when this key is pressed (knowing HTC, it's not sure they made this available outside of their own keyboard app)
- I need to known the key code of this language key. If you want to help, you can enable the debug logs in advanced options, and look for lines beginning with "keyCode: " in your phone logs (which you can get with "Log Collector" app or "adb logcat" command). If the event is received by the keyboard, you should be able to identify which code corresponds to this key, otherwise the feature will be more difficult to implement (though not impossible)
cyril wrote:it's already possible to change the language on every phone using the shift + space combination. What this topic is about is to support the special "language" key which is present on the Desire Z.OMG, yes, it really works for me, thanks! I was in search for that kind of keyboard for a week already. Just bought the Smart Keyboard, it's really amazing.
Having a special "language" key mapping would be a pleasant supplement, but I can perfectly live with Shift+Space combo.
BTW, key remapping would be really cool if you manage to build it, we have some useless hardware buttons that could be mapped to dots, periods, lang switches, etc.
Thanks
cyril wrote:I need to known the key code of this language key. If you want to help, you can enable the debug logs in advanced options, and look for lines beginning with "keyCode: " in your phone logs (which you can get with "Log Collector" app or "adb logcat" command). If the event is received by the keyboard, you should be able to identify which code corresponds to this key, otherwise the feature will be more difficult to implement (though not impossible)Done. It's keyCode 99. It's not button "X", which returns code 52.
Here's an extract from dev docs. What really shocks me is that this damn button is only since API Level !! 9 !!:
Public static final int KEYCODE_BUTTON_X
Since: API Level 9
Key code constant: X Button key. On a game controller, the X button should be either the button labeled X or the first button on the lower row of controller buttons.
Constant Value: 99 (0x00000063)
lexunus wrote:BTW, key remapping would be really cool if you manage to build it, we have some useless hardware buttons that could be mapped to dots, periods, lang switches, etc.+1
For example map user button for "?/!" really need at russian layout.
SimWhite wrote:Sorry mate, it seems that two user buttons left to space do not fire any "keyCode" events, I've just tested it. Only "Lang" button, having keyCode 99, but by some weird reason it might only be available since Gingerbread.lexunus wrote:BTW, key remapping would be really cool if you manage to build it, we have some useless hardware buttons that could be mapped to dots, periods, lang switches, etc.+1
For example map user button for "?/!" really need at russian layout.
As I now Desire Z and G2 has different key layouts. Are you tried at G2?
In any case, I'm try to see codes some later, unfortunately now there is no cable.
In any case, I'm try to see codes some later, unfortunately now there is no cable.
SimWhite wrote:As I now Desire Z and G2 has different key layouts. Are you tried at G2?I'm on Desire Z, just like you.
OK thanks for the key code. Can you tell me if it works in the latest beta?
cyril wrote:OK thanks for the key code. Can you tell me if it works in the latest beta?Confirmed, it do work with this beta.
Also, when investigating the keyCode for this Lang button with Log Collector (it was your production version from Market), I've noticed SmartKB exceptions when closing the hard keyboard:
02-04 13:11:35.260 D/SmartKeyboard( 5002): hideWindow java.lang.Exception
02-04 13:11:35.260 D/SmartKeyboard( 5002): at net.cdeguet.smartkeyboardpro.SmartKeyboard.hideWindow(Unknown Source)
02-04 13:11:35.260 D/SmartKeyboard( 5002): at android.inputmethodservice.InputMethodService.setCandidatesViewShown(InputMethodService.java:1008)
02-04 13:11:35.260 D/SmartKeyboard( 5002): at net.cdeguet.smartkeyboardpro.SmartKeyboard.setCandidatesViewShown(Unknown Source)
02-04 13:11:35.260 D/SmartKeyboard( 5002): at net.cdeguet.smartkeyboardpro.SmartKeyboard.onStartInput(Unknown Source)
02-04 13:11:35.260 D/SmartKeyboard( 5002): at android.inputmethodservice.InputMethodService.doStartInput(InputMethodService.java:1441)
02-04 13:11:35.260 D/SmartKeyboard( 5002): at android.inputmethodservice.InputMethodService$InputMethodImpl.startInput(InputMethodService.java:354)
02-04 13:11:35.260 D/SmartKeyboard( 5002): at android.inputmethodservice.IInputMethodWrapper.executeMessage(IInputMethodWrapper.java:152)
02-04 13:11:35.260 D/SmartKeyboard( 5002): at com.android.internal.os.HandlerCaller$MyHandler.handleMessage(HandlerCaller.java:61)
02-04 13:11:35.260 D/SmartKeyboard( 5002): at android.os.Handler.dispatchMessage(Handler.java:99)
02-04 13:11:35.260 D/SmartKeyboard( 5002): at android.os.Looper.loop(Looper.java:123)
02-04 13:11:35.260 D/SmartKeyboard( 5002): at android.app.ActivityThread.main(ActivityThread.java:3812)
02-04 13:11:35.260 D/SmartKeyboard( 5002): at java.lang.reflect.Method.invokeNative(Native Method)
02-04 13:11:35.260 D/SmartKeyboard( 5002): at java.lang.reflect.Method.invoke(Method.java:507)
02-04 13:11:35.260 D/SmartKeyboard( 5002): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:841)
02-04 13:11:35.260 D/SmartKeyboard( 5002): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:599)
02-04 13:11:35.260 D/SmartKeyboard( 5002): at dalvik.system.NativeStart.main(Native Method)
02-04 13:11:35.290 D/SmartKeyboard( 5002): hideWindow java.lang.Exception
02-04 13:11:35.290 D/SmartKeyboard( 5002): at net.cdeguet.smartkeyboardpro.SmartKeyboard.hideWindow(Unknown Source)
02-04 13:11:35.290 D/SmartKeyboard( 5002): at android.inputmethodservice.InputMethodService$InputMethodImpl.hideSoftInput(InputMethodService.java:371)
02-04 13:11:35.290 D/SmartKeyboard( 5002): at android.inputmethodservice.IInputMethodWrapper.executeMessage(IInputMethodWrapper.java:179)
02-04 13:11:35.290 D/SmartKeyboard( 5002): at com.android.internal.os.HandlerCaller$MyHandler.handleMessage(HandlerCaller.java:61)
02-04 13:11:35.290 D/SmartKeyboard( 5002): at android.os.Handler.dispatchMessage(Handler.java:99)
02-04 13:11:35.290 D/SmartKeyboard( 5002): at android.os.Looper.loop(Looper.java:123)
02-04 13:11:35.290 D/SmartKeyboard( 5002): at android.app.ActivityThread.main(ActivityThread.java:3812)
02-04 13:11:35.290 D/SmartKeyboard( 5002): at java.lang.reflect.Method.invokeNative(Native Method)
02-04 13:11:35.290 D/SmartKeyboard( 5002): at java.lang.reflect.Method.invoke(Method.java:507)
02-04 13:11:35.290 D/SmartKeyboard( 5002): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:841)
02-04 13:11:35.290 D/SmartKeyboard( 5002): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:599)
02-04 13:11:35.290 D/SmartKeyboard( 5002): at dalvik.system.NativeStart.main(Native Method)
Nope. It doesn't work for me.
SimWhite wrote:Nope. It doesn't work for me.I'm on Android 2.3.2 Gingerbread, with latest CyanogenMod CM7 nightly.
"Lang" button language switch works perfectly for me.
OK so I will release 3.13 as is, and we will need to understand why it doesn't work on Android 2.2.
By the way the "exceptions" are just a trick to display the stack in debug mode, nothing to worry about
By the way the "exceptions" are just a trick to display the stack in debug mode, nothing to worry about
I'm on stock firmware 2.2 (1.34). I'm tried to install Log Collector. There is no keycode event for this button ;( I can upload logs.
cyril wrote:OK so I will release 3.13 as is, and we will need to understand why it doesn't work on Android 2.2.I guess it is clear - this keyCode is supported from API Level 9 which precisely is 2.3 Gingerbread. That's why it will have no effect on Froyo, unfortunately.
By the way the "exceptions" are just a trick to display the stack in debug mode, nothing to worry about
But I'm glad you could manage to add this feature anyway, it works for me. Thanks a lot, happy I bought this keyboard.
If you require any more testing on Desire Z, ping me on twitter @lx6g
On weekends I'm try to install 2.2.1 firmware, then try to find keycode again.
hi guys.
It was not that perfect as I have expected. We managed to implement the Lang button, but the languages themselves are not mapped correctly for Desire Z hard kb layout. I have Eng/Russian kb and buttons are mapped incorrectly in Russian layout. Take a look for Russian Keyboard app on Market. It offers to choose from nearly six hard keyboard layouts.
It was not that perfect as I have expected. We managed to implement the Lang button, but the languages themselves are not mapped correctly for Desire Z hard kb layout. I have Eng/Russian kb and buttons are mapped incorrectly in Russian layout. Take a look for Russian Keyboard app on Market. It offers to choose from nearly six hard keyboard layouts.
The mapping is phonetic layout, as it's the only one which can work on every phone without any problem.
It would just take a little time to implement other layouts, but that would be quite easy.
It would just take a little time to implement other layouts, but that would be quite easy.
cyril wrote:The mapping is phonetic layout, as it's the only one which can work on every phone without any problem.I'm not sure I get the point about "phonetic" layouts..
It would just take a little time to implement other layouts, but that would be quite easy.
We have hard keyboards with various combinations of local language letters written along with standard English QWERTY buttons. Problem is that different keyboards vendors like Motorola and HTC make there own regional layouts.
In regards to Smart KB, would be great to have a separate screen in settings to select from hard keyboard layouts.
Some photos:
Desire Z, English\Russian KB: http://www.youhtc.ru/wp-content/uploads ... an-KBD.jpg
Motorola Milestone English\Russian KB: http://www.unwiredview.com/wp-content/u ... oblem1.jpg
I mean the current implementation is a phonetic mapping: S will give you a С, D will give you a Д, etc. as it's the only mapping which will work on all QWERTY hard keyboards.
But yes I understood you wish to have the same mapping as the native one of your phone, I will work on it.
But yes I understood you wish to have the same mapping as the native one of your phone, I will work on it.
I'm tried to find keycode language button at stock 2.2.1 firmware. Nothing. Will be waiting for 2.3.
Hi there!
Any luck with this feature (mapping to some most popular hardware keyboards) in upcoming releases?
Thanks
Any luck with this feature (mapping to some most popular hardware keyboards) in upcoming releases?
Thanks
Not yet, but it will come soon
I'm sorry for upping an old thread, but will it be implemented, and if yes then when?
Thanks in advance
Thanks in advance