| 1 |
default partial xkb_compatibility "misc" { |
| 2 |
|
| 3 |
virtual_modifiers Alt,Meta,Super,Hyper,ScrollLock; |
| 4 |
|
| 5 |
// Interpretations for some other useful keys. |
| 6 |
|
| 7 |
interpret Terminate_Server { |
| 8 |
action = Terminate(); |
| 9 |
}; |
| 10 |
|
| 11 |
setMods.clearLocks= True; |
| 12 |
|
| 13 |
// Set the "Alt" virtual modifier. |
| 14 |
|
| 15 |
interpret Alt_L+Any { |
| 16 |
virtualModifier= Alt; |
| 17 |
action = SetMods(modifiers=modMapMods); |
| 18 |
}; |
| 19 |
|
| 20 |
interpret Alt_L { |
| 21 |
action = SetMods(modifiers=Alt); |
| 22 |
}; |
| 23 |
|
| 24 |
interpret Alt_R+Any { |
| 25 |
virtualModifier= Alt; |
| 26 |
action = SetMods(modifiers=modMapMods); |
| 27 |
}; |
| 28 |
|
| 29 |
interpret Alt_R { |
| 30 |
action = SetMods(modifiers=Alt); |
| 31 |
}; |
| 32 |
|
| 33 |
// Set the "Meta" virtual modifier. |
| 34 |
|
| 35 |
interpret Meta_L+Any { |
| 36 |
virtualModifier= Meta; |
| 37 |
action = SetMods(modifiers=modMapMods); |
| 38 |
}; |
| 39 |
|
| 40 |
interpret Meta_L { |
| 41 |
action = SetMods(modifiers=Meta); |
| 42 |
}; |
| 43 |
|
| 44 |
interpret Meta_R+Any { |
| 45 |
virtualModifier= Meta; |
| 46 |
action = SetMods(modifiers=modMapMods); |
| 47 |
}; |
| 48 |
|
| 49 |
interpret Meta_R { |
| 50 |
action = SetMods(modifiers=Meta); |
| 51 |
}; |
| 52 |
|
| 53 |
// Set the "Super" virtual modifier. |
| 54 |
|
| 55 |
interpret Super_L+Any { |
| 56 |
virtualModifier= Super; |
| 57 |
action = SetMods(modifiers=modMapMods); |
| 58 |
}; |
| 59 |
|
| 60 |
interpret Super_L { |
| 61 |
action = SetMods(modifiers=Super); |
| 62 |
}; |
| 63 |
|
| 64 |
interpret Super_R+Any { |
| 65 |
virtualModifier= Super; |
| 66 |
action = SetMods(modifiers=modMapMods); |
| 67 |
}; |
| 68 |
|
| 69 |
interpret Super_R { |
| 70 |
action = SetMods(modifiers=Super); |
| 71 |
}; |
| 72 |
|
| 73 |
// Set the "Hyper" virtual modifier. |
| 74 |
|
| 75 |
interpret Hyper_L+Any { |
| 76 |
virtualModifier= Hyper; |
| 77 |
action = SetMods(modifiers=modMapMods); |
| 78 |
}; |
| 79 |
|
| 80 |
interpret Hyper_L { |
| 81 |
action = SetMods(modifiers=Hyper); |
| 82 |
}; |
| 83 |
|
| 84 |
interpret Hyper_R+Any { |
| 85 |
virtualModifier= Hyper; |
| 86 |
action = SetMods(modifiers=modMapMods); |
| 87 |
}; |
| 88 |
|
| 89 |
interpret Hyper_R { |
| 90 |
action = SetMods(modifiers=Hyper); |
| 91 |
}; |
| 92 |
|
| 93 |
// Sets the "ScrollLock" virtual modifier and |
| 94 |
// makes it actually lock when pressed. Sets |
| 95 |
// up a map for the scroll lock indicator. |
| 96 |
interpret Scroll_Lock+Any { |
| 97 |
virtualModifier= ScrollLock; |
| 98 |
action = LockMods(modifiers=modMapMods); |
| 99 |
}; |
| 100 |
|
| 101 |
include "ledscroll" |
| 102 |
|
| 103 |
include "misc(assign_shift_left_action)" |
| 104 |
include "misc(assign_shift_right_action)" |
| 105 |
}; |
| 106 |
|
| 107 |
partial xkb_compatibility "assign_shift_left_action" { |
| 108 |
// Because of the irreversible mapping of the Lock modifier to the |
| 109 |
// keysym Caps_Lock in symbols/pc, some combinations of options |
| 110 |
// involving e.g symbols/shift(lshift_both_capslock) may make |
| 111 |
// <LFSH> bound to the Lock modifier, creating unwanted behaviour. |
| 112 |
// The following statement ensures Shift_L always sets the Shift |
| 113 |
// modifier. |
| 114 |
setMods.clearLocks= True; |
| 115 |
interpret Shift_L { |
| 116 |
action = SetMods(modifiers = Shift); |
| 117 |
}; |
| 118 |
}; |
| 119 |
|
| 120 |
partial xkb_compatibility "assign_shift_right_action" { |
| 121 |
// A similar issue as assign_shift_left_action hereinabove may |
| 122 |
// happen to <RTSH> with some combinations of options, |
| 123 |
// involving e.g symbols/shift(shift_both_capslock) and |
| 124 |
// symbols/group(lalt_lshift_toggle). The following statement |
| 125 |
// ensures Shift_R always sets the Shift modifier. |
| 126 |
setMods.clearLocks= True; |
| 127 |
interpret Shift_R { |
| 128 |
action = SetMods(modifiers = Shift); |
| 129 |
}; |
| 130 |
}; |