summaryrefslogtreecommitdiff
path: root/symbols/level5
blob: 330fbc4c5d975b339e49c5c4e16346ccd7fa8c73 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
// These variants assign ISO_Level5_Shift to various keys
// so that levels 5 to 8 can be reached.

// The right Ctrl key (while pressed) chooses the fifth shift level.
partial modifier_keys
xkb_symbols "rctrl_switch" {
  key <RCTL> {[  ISO_Level5_Shift  ], type[group1]="ONE_LEVEL" };
};

// The Less/Greater key (while pressed) chooses the fifth shift level.
partial modifier_keys
xkb_symbols "lsgt_switch" {
  key <LSGT> {[  ISO_Level5_Shift  ], type[group1]="ONE_LEVEL" };
};

// The right Alt key (while pressed) chooses the fifth shift level.
partial modifier_keys
xkb_symbols "ralt_switch" {
  key <RALT> {[  ISO_Level5_Shift  ], type[group1]="ONE_LEVEL" };
};

// The CapsLock key (while pressed) chooses the fifth shift level.
partial modifier_keys
xkb_symbols "caps_switch" {
  key <CAPS> {[  ISO_Level5_Shift  ], type[group1]="ONE_LEVEL" };
};

// The Menu key (while pressed) chooses the fifth shift level.
partial modifier_keys
xkb_symbols "menu_switch" {
  key <MENU> {[  ISO_Level5_Shift  ], type[group1]="ONE_LEVEL" };
};


// This adds the definitions needed to create a level5-locking behaviour,
// using the virtual modifier NumLock (mapped to Mod2) as lock indicator.
// See also types/level5 (EIGHT_LEVEL_WITH_LEVEL5_LOCK) and compat/level5 (level5_lock).
partial modifier_keys
xkb_symbols "lock" {
  replace key <HYPR> {[  NoSymbol  ], type[group1] = "ONE_LEVEL", vmods = NumLock,
                                      actions[group1] = [ SetMods(modifiers=NumLock) ]};
  modifier_map Mod2 { <HYPR> };
};

// Below are eight variants for assigning extra keys for choosing/locking the fifth level.

partial modifier_keys
xkb_symbols "lsgt_switch_lock" {
  include "level5(lock)"
  key <LSGT> {[  ISO_Level5_Shift, ISO_Level5_Shift, ISO_Level5_Shift, ISO_Level5_Shift,
                 ISO_Level5_Lock, ISO_Level5_Lock, ISO_Level5_Lock, ISO_Level5_Lock  ],
                 type[group1] = "EIGHT_LEVEL" };
};

partial modifier_keys
xkb_symbols "lwin_switch_lock" {
  include "level5(lock)"
  key <LWIN> {[  ISO_Level5_Shift, ISO_Level5_Shift, ISO_Level5_Shift, ISO_Level5_Shift,
                 ISO_Level5_Lock, ISO_Level5_Lock, ISO_Level5_Lock, ISO_Level5_Lock  ],
                 type[group1] = "EIGHT_LEVEL" };
};

partial modifier_keys
xkb_symbols "ralt_switch_lock" {
  include "level5(lock)"
  key <RALT> {[  ISO_Level5_Shift, ISO_Level5_Shift, ISO_Level5_Shift, ISO_Level5_Shift,
                 ISO_Level5_Lock, ISO_Level5_Lock, ISO_Level5_Lock, ISO_Level5_Lock  ],
                 type[group1] = "EIGHT_LEVEL" };
};

partial modifier_keys
xkb_symbols "rwin_switch_lock" {
  include "level5(lock)"
  key <RWIN> {[  ISO_Level5_Shift, ISO_Level5_Shift, ISO_Level5_Shift, ISO_Level5_Shift,
                 ISO_Level5_Lock, ISO_Level5_Lock, ISO_Level5_Lock, ISO_Level5_Lock  ],
                 type[group1] = "EIGHT_LEVEL" };
};

partial modifier_keys
xkb_symbols "lsgt_switch_lock_cancel" {
  include "level5(lock)"
  key <LSGT> {[  ISO_Level5_Shift, ISO_Level5_Shift, ISO_Level5_Shift, ISO_Level5_Shift,
                 ISO_Level5_Lock, ISO_Level5_Lock, ISO_Level5_Lock, ISO_Level5_Lock  ],
                 type[group1] = "EIGHT_LEVEL_WITH_LEVEL5_LOCK" };
};

partial modifier_keys
xkb_symbols "lwin_switch_lock_cancel" {
  include "level5(lock)"
  key <LWIN> {[  ISO_Level5_Shift, ISO_Level5_Shift, ISO_Level5_Shift, ISO_Level5_Shift,
                 ISO_Level5_Lock, ISO_Level5_Lock, ISO_Level5_Lock, ISO_Level5_Lock  ],
                 type[group1] = "EIGHT_LEVEL_WITH_LEVEL5_LOCK" };
};

partial modifier_keys
xkb_symbols "ralt_switch_lock_cancel" {
  include "level5(lock)"
  key <RALT> {[  ISO_Level5_Shift, ISO_Level5_Shift, ISO_Level5_Shift, ISO_Level5_Shift,
                 ISO_Level5_Lock, ISO_Level5_Lock, ISO_Level5_Lock, ISO_Level5_Lock  ],
                 type[group1] = "EIGHT_LEVEL_WITH_LEVEL5_LOCK" };
};

partial modifier_keys
xkb_symbols "rwin_switch_lock_cancel" {
  include "level5(lock)"
  key <RWIN> {[  ISO_Level5_Shift, ISO_Level5_Shift, ISO_Level5_Shift, ISO_Level5_Shift,
                 ISO_Level5_Lock, ISO_Level5_Lock, ISO_Level5_Lock, ISO_Level5_Lock  ],
                 type[group1] = "EIGHT_LEVEL_WITH_LEVEL5_LOCK" };
};