How can I refresh keycode to keysym mapping?
marslee_suc at 163.com
Wed Apr 8 06:35:25 PDT 2009
Thank you very much. That must be the solution,but I am developing a QT application how can I listen MappingNotify ? I think all events will be sent to QT I don't know how to catch it
2009-04-08，"Julien Cristau" <jcristau at debian.org> ：
>On Wed, 2009-04-08 at 13:30 +0800, Edward wrote:
>> Hi all,
>> I want to get keysym with XKeycodeToKeysym method, but I found when I change keyboard layout using setxkbmap –layout
>> in another process, The XKeycodeToKeysym return the old layout keysym.
>> For example:
>> Firstly, I run “setxkbmap –
>> layout us”. I get “z” for XKeycodeToKeysym(disply, 52,0), then I run “setxkbmap –layout de” in
>> another process I also get “z” for XKeycodeToKeysum(display, 52,0). I think it should return “y”. It seems that I omit to update
>> key mapping, but I don’t know how to update it immediately in my code.
>As a first guess, make sure the app listens for MappingNotify, and calls
>XRefreshKeyboardMapping() when it gets that.
>xorg mailing list
>xorg at lists.freedesktop.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the xorg