Difference between virtualKey and keyCode?



  • I'm working on a program which needs to support both English and Japanese keyboard.

    but no matter which keyboard I'm using, the program functions as if it is always the english keyboard.

    I debugged the code and noticed that in the keypress event, we use nativeVirtualKey() instead of key(). while the key() reflects the keyboard type, the nativeVirtualKey() seems to return the same code for both keyboards.

    I can't tell the difference between nativeVirtualKey and key? I don't know when to use which one? And what is worse, there is a scan code also.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.