Hello all.
This patch fixes a couple of problems with keyboard group switching reported in the news group: 1. Group switch had never worked before, if the keyboard has been switched outside of Wine. 2. I was clearly stated that Group switch is active if event->state & 0x2000, not event->state & 0x6000.
Please test it on your local configurations and report back. If there will be no objections, I'll send it to wine-patches.
Thanks.
-- Dmitry.
I wrote:
This patch fixes a couple of problems with keyboard group switching reported in the news group:
- Group switch had never worked before, if the keyboard has been
switched outside of Wine.
Correct.
- I was clearly stated that Group switch is active if event->state & 0x2000,
not event->state & 0x6000.
Wrong.
Please replace
AltGrMask = event->state & 0x2000; to AltGrMask = event->state & 0x6000;
in the patch, all possible group indexes should be available.
Please test it on your local configurations and report back. If there will be no objections, I'll send it to wine-patches.
-- Dmitry.
On Tue, 25 Sep 2001 19:30:02 +0900 Dmitry Timoshkov dmitry@baikal.ru wrote:
DT> Hello all. DT> DT> This patch fixes a couple of problems with keyboard group switching DT> reported in the news group: DT> 1. Group switch had never worked before, if the keyboard has been DT> switched outside of Wine. DT> 2. I was clearly stated that Group switch is active if event->state & 0x2000, DT> not event->state & 0x6000. DT> DT> Please test it on your local configurations and report back.
In my XF86Config-4 I have: Option "XkbLayout" "lt" Option "XkbOptions" "grp:ctrl_shift_toggle" - it means Ctrl+Shift switches layouts.
I switched layouts 2 times in notepad. Without patch:
err:keyboard:X11DRV_ToUnicode Please report: no char for keysym FE0A (ISO_Prev_Group) : err:keyboard:X11DRV_ToUnicode (virtKey=10,scanCode=2A,keycode=32,state=5) err:keyboard:X11DRV_ToUnicode Please report: no char for keysym FE0A (ISO_Prev_Group) : err:keyboard:X11DRV_ToUnicode (virtKey=10,scanCode=2A,keycode=32,state=5)
With patch: err:keyboard:X11DRV_ToUnicode Please report: no char for keysym FE0A (ISO_Prev_Group) : err:keyboard:X11DRV_ToUnicode (virtKey=10,scanCode=2A,keycode=32,state=5) err:keyboard:X11DRV_ToUnicode Please report: no char for keysym FE0A (ISO_Prev_Group) : err:keyboard:X11DRV_ToUnicode (virtKey=10,scanCode=2A,keycode=32,state=2005)
As you see, with patch "state" is different when switching layout second time.
Regards, Nerijus
"Nerijus Baliunas" nerijus@users.sourceforge.net wrote:
In my XF86Config-4 I have: Option "XkbLayout" "lt" Option "XkbOptions" "grp:ctrl_shift_toggle" - it means Ctrl+Shift switches layouts.
I switched layouts 2 times in notepad. Without patch:
err:keyboard:X11DRV_ToUnicode Please report: no char for keysym FE0A (ISO_Prev_Group) : err:keyboard:X11DRV_ToUnicode (virtKey=10,scanCode=2A,keycode=32,state=5) err:keyboard:X11DRV_ToUnicode Please report: no char for keysym FE0A (ISO_Prev_Group) : err:keyboard:X11DRV_ToUnicode (virtKey=10,scanCode=2A,keycode=32,state=5)
With patch: err:keyboard:X11DRV_ToUnicode Please report: no char for keysym FE0A (ISO_Prev_Group) : err:keyboard:X11DRV_ToUnicode (virtKey=10,scanCode=2A,keycode=32,state=5) err:keyboard:X11DRV_ToUnicode Please report: no char for keysym FE0A (ISO_Prev_Group) : err:keyboard:X11DRV_ToUnicode (virtKey=10,scanCode=2A,keycode=32,state=2005)
As you see, with patch "state" is different when switching layout second time.
Sure. Wine corrects state according to its internal lpKeyState. Difference between internal and actual state value is due to the fact that Wine does not see (or better X does not show) some keyboard events. Since I also have "grp:ctrl_shift_toggle" I had seen the same state correction.
Perhaps Wine should ignore ISO_Prev_Group/ISO_Next_Group keyboard events to not confuse users.
-- Dmitry.