Bug 15843 - -option grp:ctrls_toggle not working
Summary: -option grp:ctrls_toggle not working
Status: RESOLVED FIXED
Alias: None
Product: xkeyboard-config
Classification: Unclassified
Component: General (show other bugs)
Version: unspecified
Hardware: All All
: medium normal
Assignee: xkb
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-05-06 02:56 UTC by James Cloos
Modified: 2016-10-22 20:20 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Attachments
unpatched output of xkbmap :0 - (53.75 KB, text/plain)
2008-05-06 02:56 UTC, James Cloos
Details
0001-symbols-group-re-enable-grp-ctrls_toggle.patch (1.02 KB, patch)
2016-01-20 05:06 UTC, Peter Hutterer
Details | Splinter Review

Description James Cloos 2008-05-06 02:56:16 UTC
Created attachment 16382 [details]
unpatched output of xkbmap :0 -

It has been some time since my setxkbmap invokation in ~/.xinitrc has
worked as intended.

After taking a look at the output of « xkbmap :0 - » I tried this small
diff and piped the result to « xkbmap - :0 » and everything worked:

--- server-0.xkb        2008-05-05 17:01:56.000000000 -0400
+++ working.xkb 2008-05-05 17:05:43.891419799 -0400
@@ -1204,7 +1204,7 @@
     };
     key <RTRN> {         [          Return ] };
     key <LCTL> {
-        type= "PC_RCONTROL_LEVEL2",
+        type= "PC_CONTROL_LEVEL2",
         symbols[Group1]= [       Control_L,  ISO_Prev_Group ]
     };
     key <AC01> {
@@ -1491,7 +1491,7 @@
     key <MUHE> {         [        Muhenkan ] };
     key <KPEN> {         [        KP_Enter ] };
     key <RCTL> {
-        type= "PC_LCONTROL_LEVEL2",
+        type= "PC_CONTROL_LEVEL2",
         symbols[Group1]= [       Control_R,  ISO_Next_Group ]
     };
     key <KPDV> {

I don’t know which part of the definition in symbols/group and types/pc
breaks w/o that change.

I'm running from cvs, currently up to date as of:

/ChangeLog/1.421/Sun Apr 13 05:28:30 2008//

but the diffs don’t seem to be relevant.

That said, the comment in the LOCAL_EIGHT_LEVEL addition that RControl
seems not to be enabled by default does seem relevant, yes?
Comment 1 Peter Hutterer 2014-11-11 23:53:24 UTC
6 years later, let's assume this is working :) please re-open if that's not the case.
Comment 2 Jan Christoph Ebersbach 2016-01-15 16:29:31 UTC
The issue still exists in xorg 1.18.  The fix James suggested worked also for me.

Steps to reproduce:
0. Clear current keyboard options: setxbkmap -option
1. Set a two layouts: setxkbmap -option grp:ctrls_toggle us,de
2. Press "y" key.  It should produce a "y"
3. Switch layouts by pressing LCtrl+RCtrl
4. Press "y" key.  It should still produce a "y" instead of "z" which would be the German mapping
Comment 3 Peter Hutterer 2016-01-20 05:06:40 UTC
Created attachment 121149 [details] [review]
0001-symbols-group-re-enable-grp-ctrls_toggle.patch
Comment 4 Sergey V. Udaltsov 2016-01-24 21:33:34 UTC
Thank you Peter! Committed!
Comment 5 Ivan Zakharyaschev 2016-10-22 20:20:28 UTC
It's a bit strange that piping the output of "setxkbmap -print" to "xkbcomp - :0" is a workaround that would load ctrls_toggle successfully -- as documented there https://bugzilla.altlinux.org/show_bug.cgi?id=30618#c4 , https://bugzilla.altlinux.org/show_bug.cgi?id=32638 :

    setxkbmap -option '' `cat "$sysxkbmap"` -print | xkbcomp - "$DISPLAY"

So, it would seem that is is a bug in setxkbmap, not in the definitions, because ultimately xkbcomp was able to do the job. Strange... How? ...if it was a bug in the definitions.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.