Fixed Extend scroll keys

* The XF86ScrollRight/Left (button 6/7) in my Extend mappings caused crashes in some cases, presumably due to poor implementation.
This commit is contained in:
DreymaR 2020-04-27 17:30:56 +02:00
parent 9b1e7ab771
commit 1535dbeeb5
3 changed files with 95 additions and 58 deletions

View File

@ -1,7 +1,7 @@
DreymaR's Big Bag of Keyboard Tricks DreymaR's Big Bag of Keyboard Tricks
==================================== ====================================
### For Linux (updated to XKB-data v2.23.1-1ubuntu1, 2018-08) ### For Linux (updated to [XKB-data v2.23.1-1ubuntu1][XKBdat], 2018-08)
* New "Colemak[eD]" AltGr mappings (lv3-4) putting dead keys on AltGr+symbol keys and reworking most other mappings * New "Colemak[eD]" AltGr mappings (lv3-4) putting dead keys on AltGr+symbol keys and reworking most other mappings
* Angle/Wide ergo modifications to improve wrist angles, hand spacing and right pinky stretch/load effort * Angle/Wide ergo modifications to improve wrist angles, hand spacing and right pinky stretch/load effort
@ -22,8 +22,10 @@ Run the install and setxkb scripts with -h (or look inside them) for more help a
Links Links
----- -----
See the [DREYMAR'S (XKB) topic on the Colemak Forums](http://forum.colemak.com/viewtopic.php?id=1438) (http://forum.colemak.com). See [DREYMAR'S XKB topic on the Colemak Forums](http://forum.colemak.com/viewtopic.php?id=1438) (http://forum.colemak.com).
There are plenty of explanations and further links in there, as well as links to files. There are plenty of explanations and further links in there, as well as links to files.
Happy XKB hacking! Happy XKB hacking!
DreymaR, 2017-06 DreymaR, 2018-08
[XKBdat]: https://ubuntu.pkgs.org/18.04/ubuntu-main-amd64/xkb-data_2.23.1-1ubuntu1_all.deb.html (xkb-data download page)

View File

@ -6,39 +6,39 @@
// - <FK##> mapped as XF86 Multimedia keys; shifted versions were not implemented in WinPKL // - <FK##> mapped as XF86 Multimedia keys; shifted versions were not implemented in WinPKL
// //
// These keys are modified/transposed by holding down the 'extend key' (CapsLock by default): // These keys are modified/transposed by holding down the 'extend key' (CapsLock by default):
// +------+------+------+------+------+------+------+------+------+------+------+------+------+ // +-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
// |Esc + |F1 <> |F2 << |F3 >> |F4 <> |F5 <> |F6 << |F7 >> |F8 <> |F9 <> |F10<> |F11<> |F12<> | // |Esc + |F1 <> |F2 << |F3 >> |F4 <> |F5 <> |F6 << |F7 >> |F8 <> |F9 <> |F10<> |F11<> |F12<> |
// | | Pause| Rew | Fwd | Eject| Refr | Bri- | Bri+ | Sleep| WWW | Mail | App1 | App2 | // | | Pause | Rew | Fwd | Eject | Refr | Bri- | Bri+ | Sleep | WWW | Mail | App1 | App2 |
// | Caps | Play | Prev | Next | Stop | Mute | Vol- | Vol+ | Media| Home | Srch | File | Calc | // | Caps | Play | Prev | Next | Stop | Mute | Vol- | Vol+ | Media | Home | Srch | File | Calc |
// +======+======+======+======+======+======+======+======+======+======+======+======+======+ // +=======+=======+=======+=======+=======+=======+=======+=======+=======+=======+=======+=======+=======+
// |` €€€ |1 |2 |3 |4 |5 |6 |7 |8 |9 |0 |- |= | // |` €€€ |1 |2 |3 |4 |5 |6 |7 |8 |9 |0 |- |= |
// | Cust | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 | // | Cust | F1 | F2 | F3 | F4 | F5 | F6 | F7 | F8 | F9 | F10 | F11 | F12 |
// +------+------+------+------+------+------+------+------+------+------+------+------+------+ // +-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
// |Tab |Q €€€ |W *** |F <<> |P <>> |G *** |J ### |L ### |U ### |Y ### |; €€€ |[ €€€ |] €€€ | // |Tab |Q €€€ |W *** |F <<> |P <>> |G *** |J ### |L ### |U ### |Y ### |; €€€ |[ €€€ |] €€€ |
// | | Esc | *WhUp| BrBck| BrFwd| *MUp | PgUp | Home | Up | End | Del | Esc | Ins | // | | Esc | *WhUp | BrBck | BrFwd | *MUp | PgUp | Home | Up | End | Del | Esc | Ins |
// +------+------+------+------+------+------+------+------+------+------+------+------+------+ // +-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
// |Caps+ |A +++ |R *** |S +++ |T +++ |D *** |H ### |N ### |E ### |I ### |O €€€ |' €€€ |\ ><> | // |Caps+ |A +++ |R *** |S +++ |T +++ |D *** |H ### |N ### |E ### |I ### |O €€€ |' €€€ |\ ><> |
// | ++++ | Alt | *WhDn| Shift| Ctrl | *MDn | PgDn | Left | Down | Right| Back | Menu | BrFav| // | ++++ | Alt | *WhDn | Shift | Ctrl | *MDn | PgDn | Left | Down | Right | Back | Menu | BrFav |
// +------+------+------+------+------+------+------+------+------+------+------+------+------+ // +-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
// |_ *** |Z €€€ |X === |C === |V === |B *** |K *** |M *** |, *** |. *** |/ €€€ |Spc € |Entr€ | // |_ *** |Z €€€ |X === |C === |V === |B *** |K *** |M *** |, *** |. *** |/ €€€ |Spc € |Entr€ |
// | *MOn | Undo | Cut | Copy | Paste| *Bt1 | *Bt2 | *Bt3 | *MLe | *MRi | Multi| Enter| PrtSc| // | *MOn | Undo | Cut | Copy | Paste | *Bt1 | *Bt2 | *Bt3 | *MLe | *MRi | Multi | Enter | PrtSc |
// +------+------+------+------+------+------+------+------+------+------+------+-------------+ // +-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
// Legend: # Movement; + Modifiers; = GUI edit; * Mouse; <> MultiMedia; € Various commands. // Legend: # Movement; + Modifiers; = GUI edit; * Mouse; <> MultiMedia; € Various commands.
// //
// KeyPad overlay with nav block to the left (lv7-8): // KeyPad overlay with nav block to the left (lv7-8):
// +------+------+------+------+------+------+------+------+------+------+------+------+------+ // +-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
// |` €€€ |1 |2 |3 |4 £ |5 € |6 |7 ⇖ |8 ⇑ |9 ⇗ |0 |- |= | // |` €€€ |1 |2 |3 |4 £ |5 € |6 |7 ⇖ |8 ⇑ |9 ⇗ |0 |- |= |
// | Cust | ! | @ | # | $ | % | ^ | KP_7 | KP_8 | KP_9 | KP_* | KP_- | KP_= | // | Cust | ! | @ | # | $ | % | ^ | KP_7 | KP_8 | KP_9 | KP_* | KP_- | KP_= |
// +------+------+------+------+------+------+------+------+------+------+------+------+------+ // +-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
// |Tab |Q ### |W ### |F ### |P €€€ |G €€€ |J ### |L ⇐ |U ⇔ |Y ⇒ |; |[ { |] } | // |Tab |Q ### |W ### |F ### |P €€€ |G €€€ |J ### |L ⇐ |U ⇔ |Y ⇒ |; |[ { |] } |
// | | Home | Up | End | Del | Esc | PgUp | KP_4 | KP_5 | KP_6 | KP_+ | ( | ) | // | | Home | Up | End | Del | Esc | PgUp | KP_4 | KP_5 | KP_6 | KP_+ | ( | ) |
// +------+------+------+------+------+------+------+------+------+------+------+------+------+ // +-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
// |Caps+ |A ### |R ### |S ### |T €€€ |D |H ### |N ⇙ |E ⇓ |I ⇘ |O |' " |\ | | // |Caps+ |A ### |R ### |S ### |T €€€ |D |H ### |N ⇙ |E ⇓ |I ⇘ |O |' " |\ | |
// | ++++ | Left | Down | Right| Back | K_Lck| PgDn | KP_1 | KP_2 | KP_3 | K_Ent| ' | : | // | ++++ | Left | Down | Right | Back | K_Lck | PgDn | KP_1 | KP_2 | KP_3 | K_Ent | ' | : |
// +------+------+------+------+------+------+------+------+------+------+------+------+------+ // +-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
// |_ *** |Z €€€ |X === |C === |V === |B *** |K |M |, ⇕ |. |/ |Spc |Entr | // |_ *** |Z €€€ |X === |C === |V === |B *** |K |M |, ⇕ |. |/ |Spc |Entr |
// | *MOn | Undo | Cut | Copy | Paste| *Bt1 | , | KP_0 | KP_0 | KP_. | KP_/ | Spc | K_Ent| // | *MOn | Undo | Cut | Copy | Paste | *Bt1 | , | KP_0 | KP_0 | KP_. | KP_/ | Spc | K_Ent |
// +------+------+------+------+------+------+------+------+------+------+------+------+------+ // +-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+-------+
// //
// NOTE: A lv7 (Level5+Level3) modifier might be necessary to use the KeyPad level sensibly // NOTE: A lv7 (Level5+Level3) modifier might be necessary to use the KeyPad level sensibly
// One idea is to use AltGr+Caps as a lv7_lock (Caps+AltGr is already lv7_switch) // One idea is to use AltGr+Caps as a lv7_lock (Caps+AltGr is already lv7_switch)
@ -49,6 +49,9 @@
// One fix is to run xset afterwards: 'seq -s " r " 8 255 | xargs xset r' supposedly does the trick. // One fix is to run xset afterwards: 'seq -s " r " 8 255 | xargs xset r' supposedly does the trick.
// Add the following to key <> {} defs (before symbols[Group1]=)? // Add the following to key <> {} defs (before symbols[Group1]=)?
// repeat=true, // repeat=true,
// TODO: A lv7 modifier to reach the second Extend layer directly.
// Test out this:
// key <RCTL> { [ ISO_Level5_Shift ], actions[Group1] = [ SetMods(mods=LevelThree+LevelFive) ] };
default partial default partial
xkb_symbols "basic" { xkb_symbols "basic" {
@ -226,11 +229,11 @@ xkb_symbols "lv5" {
Redirect(key=<HOME>) , Redirect(key=<HOME>) ] // <HOME> Redirect(key=<HOME>) , Redirect(key=<HOME>) ] // <HOME>
}; // Cmk Q }; // Cmk Q
key <AD02> { symbols[Group1]=[ NoSymbol , NoSymbol , NoSymbol , NoSymbol , key <AD02> { symbols[Group1]=[ NoSymbol , NoSymbol , NoSymbol , NoSymbol ,
XF86ScrollUp , XF86ScrollRight , // ScrollUp(††) XF86ScrollUp , XF86ScrollUp , // ScrollUp(††)
Up , KP_Up ], // ↑ Up , KP_Up ], // ↑
actions[Group1]=[NoAction(),NoAction(),NoAction(),NoAction(), actions[Group1]=[NoAction(),NoAction(),NoAction(),NoAction(),
PtrBtn(button=4) , PtrBtn(button=6) , // PtrWhBtUp/Ri PtrBtn(button=4) , PtrBtn(button=4) , // PtrWhBtUp/Ri
NoAction() , NoAction() ] NoAction() , NoAction() ] // (ScrollRight/Left & button 6/7 may cause crashes now?!)
}; // Cmk W }; // Cmk W
key <AD03> { symbols[Group1]=[ NoSymbol , NoSymbol , NoSymbol , NoSymbol , key <AD03> { symbols[Group1]=[ NoSymbol , NoSymbol , NoSymbol , NoSymbol ,
XF86Back , XF86Back , // BrBck XF86Back , XF86Back , // BrBck
@ -318,11 +321,11 @@ xkb_symbols "lv5" {
NoAction() , NoAction() ] NoAction() , NoAction() ]
}; // Cmk A }; // Cmk A
key <AC02> { symbols[Group1]=[ NoSymbol , NoSymbol , NoSymbol , NoSymbol , key <AC02> { symbols[Group1]=[ NoSymbol , NoSymbol , NoSymbol , NoSymbol ,
Down , XF86ScrollDown , // ScrollDown(††) XF86ScrollDown , XF86ScrollDown , // ScrollDown(††)
Down , KP_Down ], // ↓ Down , KP_Down ], // ↓
actions[Group1]=[NoAction(),NoAction(),NoAction(),NoAction(), actions[Group1]=[NoAction(),NoAction(),NoAction(),NoAction(),
PtrBtn(button=5) , PtrBtn(button=7) , // PtrWhBtDn/Le PtrBtn(button=5) , PtrBtn(button=5) , // PtrWhBtDn/Le
NoAction() , NoAction() ] NoAction() , NoAction() ] // (ScrollRight/Left & button 6/7 may cause crashes now?!)
}; // Cmk R }; // Cmk R
key <AC03> { symbols[Group1]=[ NoSymbol , NoSymbol , NoSymbol , NoSymbol , key <AC03> { symbols[Group1]=[ NoSymbol , NoSymbol , NoSymbol , NoSymbol ,
Shift_L , Shift_L , // Shift Shift_L , Shift_L , // Shift

View File

@ -604,23 +604,55 @@ key.type[Group1]="FOUR_LEVEL_SEMIALPHABETIC";
}; };
// --> OEystein Bech "DreymaR" Gadmar, 2013: Additions to xkb/symbols/group // --> OEystein Bech "DreymaR" Gadmar, 2012-01: Additions to xkb/symbols/hu
// The Left Ctrl key (while pressed) chooses the second group. // Colemak[eD]: National/locale Colemak "edition DreymaR" variants for Hungarian.
// (Needed mainly for mirrored layouts.) // 2006-01-01 Shai Coleman, http://colemak.com/
partial modifier_keys // See the Colemak forum topic on Cmk[eD] locales: http://forum.colemak.com/viewtopic.php?id=1458
xkb_symbols "lctrl_switch" {
key <LCTL> {
symbols[Group1]= [ Mode_switch ]
};
}; // lctrl_switch
// The Right Control key (while pressed) chooses the next group. // The 'keep local symbols' variant keeps the national symbol and special letter setup.
// Control_L+Control_R toggles groups. partial alphanumeric_keys
partial modifier_keys xkb_symbols "cmk_ed_ks" {
xkb_symbols "rctrl_switch_ctrls_toggle" { include "hu(basic)"
key <RCTL> { include "colemak(cmk_ed_letters)"
type[ Group1 ] = "PC_CONTROL_LEVEL2", name[Group1]= "Hungarian (Colemak[eD], keep local symbols)";
symbols[ Group1 ] = [ Mode_switch, ISO_Next_Group ]
}; // NOTE: Symbols on letter keys may be lost in cmk_ed_ks if they are not on Colemak[eD] letter keys.
}; // rctrl_switch_ctrls_toggle // EuroSign is often on 'E'. The latin(intl) and locale(winkeys) layout variants use '5'.
// <-- DreymaR: Additions to xkb/symbols/group // Colemak[eD] has EuroSign on 'E' and mu on '5'.
// key <AE05> { [ NoSymbol, NoSymbol, mu, degree ] };
// key <AE05> { [ NoSymbol, NoSymbol, EuroSign, degree ] }; // dead_abovering is lost
key <AD10> { [ eacute, Eacute, dollar, cent ] }; // from <AC10>
};
// The 'us' variant uses the US-type symbol key setup (recommended!) as it is nearly an intl. standard.
// For Hungarian, necessary local letters are added to designated flexible spots in the layout.
// For "writing" and "coding" subvariants, move the brackets between lv1-2 and lv3-4 as shown.
partial alphanumeric_keys
xkb_symbols "cmk_ed_us" {
include "colemak(cmk_ed_letters)"
include "colemak(cmk_ed_symbols)"
include "level3(ralt_switch)"
name[Group1]= "Hungarian (Colemak[eD], unified symbols)";
// In Hungarian, á/é/ö are common (Furedi/Kelemen(1989) frequencies: eatlnskomzrigáéydbvhjöfupőócüíúűxw)
// Acute accent is used a lot (áéóíú); umlaut (öü) and doubleacute (őű) some; accessible dead keys would be nice
// From frequencies alone it seems x and w should go instead but that's unwise in an international world!
// key <AD11> { [ bracketleft, braceleft, dead_acute, dead_doubleacute ] };
// key <AD12> { [ bracketright, braceright, dead_doubleacute, dead_diaeresis ] };
key <AD11> { [ dead_acute, dead_doubleacute, bracketleft, braceleft ] }; // easier accents
key <AD12> { [ dead_doubleacute, dead_diaeresis, bracketright, braceright ] }; // easier accents
key <LSGT> { [ odiaeresis, Odiaeresis, udiaeresis, Udiaeresis ] }; // from <AE10>/<AE11>
//// One alternative is to provide áéó, öü and őű on AltGr mappings:
// key <AD11> { [ eacute, Eacute, bracketleft, braceleft ] }; // from <AC10>
// key <AD12> { [ odiaeresis, Odiaeresis, bracketright, braceright ] }; // from <AE10>
// key <LSGT> { [ aacute, Aacute, oe, OE ] }; // from <AC11>
// NOTE: The Curl(DH) ergo mod moves H and K, which may interfere with these mappings.
// key <AB06> { [ k, K, odoubleacute, Odoubleacute ] }; // from <AD11>
// key <AC06> { [ h, H, oacute, Oacute ] }; // from <AE12>
// key <AD06> { [ j, J, udiaeresis, Udiaeresis ] }; // from <AE11>
// key <AD07> { [ l, L, udoubleacute, Udoubleacute ] }; // from <BKSL>
};
// <-- DreymaR: Additions to xkb/symbols/hu