keymap and Xsync
Dirk Wallenstein
halsmit at t-online.de
Mon Jul 19 00:10:39 PDT 2010
On Sat, Jul 17, 2010 at 10:31:47PM +0200, viollet.benoit at free.fr wrote:
> The following code:
>
> locale(LC_ALL,"");
> ...
> keysym = XKeycodeToKeysym (dpy, keycode,0);
> std::cout << (int) keycode << " " << (int) keysym << std::endl;
> XSync (dpy, False);
> keysym = XKeycodeToKeysym (dpy, keycode,0);
> std::cout << (int) keycode << " " << (int) keysym << std::endl;
>
> gives
> 24 97
> 24 113
>
> So, Xsync changes the keymap from "fr" to "us". But when I add at the beginning: system("setxkbmap fr"), it works.
> 24 97
> 24 97
>
> What can I do ?
Does it work with the XKB version of the call:
keysym = XkbKeycodeToKeysym (dpy, keycode,0, 0);
--
Greetings,
Dirk
More information about the xorg-devel
mailing list