question

jc-0592 avatar image
0 Votes"
jc-0592 asked saldana-msft edited

japanese IME is breaking my python script keybinds

I wrote a program for a customer service agent who uses windows 10. A hotkey is bound using the keyboard module, and it works like a charm, UNTIL the user presses CapsLock to swap to Microsoft IME Japanese.

Once that swap is made, the hotkey that my program has bound does not function anymore, and the program must be restarted.

I checked the key output in each keyboard mode, and they both output the same char, ' \ '.

Could someone speculate as to what the problem could be, and perhaps even a potential resolution?



 `import keyboard  keyboard.add_hotkey('\', callFunction)`



not-supported
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

0 Answers