aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/xkeyboard-config
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2011-10-19 10:44:43 +0200
committermarha <marha@users.sourceforge.net>2011-10-19 10:44:43 +0200
commit9f986778bd4393c5a9108426969d45aa7f10f334 (patch)
tree27d7bd08dac54a54a923e76dccf2b8e388be2a03 /xorg-server/xkeyboard-config
parentafbd3947071a33f59dda122f1ac396442a02c128 (diff)
downloadvcxsrv-9f986778bd4393c5a9108426969d45aa7f10f334.tar.gz
vcxsrv-9f986778bd4393c5a9108426969d45aa7f10f334.tar.bz2
vcxsrv-9f986778bd4393c5a9108426969d45aa7f10f334.zip
libX11 libXext libXft mesa libxcb mkfontscale pixman xserver
xkeyboard-config git update 19 oct 2011
Diffstat (limited to 'xorg-server/xkeyboard-config')
-rw-r--r--xorg-server/xkeyboard-config/rules/base.xml.in4
-rw-r--r--xorg-server/xkeyboard-config/symbols/gb2
-rw-r--r--xorg-server/xkeyboard-config/symbols/macintosh_vndr/apple282
-rw-r--r--xorg-server/xkeyboard-config/types/extra344
-rw-r--r--xorg-server/xkeyboard-config/types/numpad138
5 files changed, 374 insertions, 396 deletions
diff --git a/xorg-server/xkeyboard-config/rules/base.xml.in b/xorg-server/xkeyboard-config/rules/base.xml.in
index 6814a6b72..5279521a6 100644
--- a/xorg-server/xkeyboard-config/rules/base.xml.in
+++ b/xorg-server/xkeyboard-config/rules/base.xml.in
@@ -6209,7 +6209,7 @@
<option>
<configItem>
<name>numpad:mac</name>
- <_description>Numeric keypad keys work as with Macintosh</_description>
+ <_description>Numeric keypad keys always enter digits (as in Mac OS)</_description>
</configItem>
</option>
<option>
@@ -6339,6 +6339,7 @@
<_description>Right Win chooses 5th level, locks when pressed together with another 5th-level-chooser</_description>
</configItem>
</option>
+<!--
<option>
<configItem>
<name>lv5:lsgt_switch_lock_cancel</name>
@@ -6375,6 +6376,7 @@
<_description>Right Alt chooses 5th level, acts as onetime lock when pressed together with another 5th-level-chooser</_description>
</configItem>
</option>
+-->
</group>
<group allowMultipleSelection="false">
<!-- Let space output NBSP, NNBSP, ZWNJ, and ZWJ for the desired level -->
diff --git a/xorg-server/xkeyboard-config/symbols/gb b/xorg-server/xkeyboard-config/symbols/gb
index d460d3d61..58e966fc7 100644
--- a/xorg-server/xkeyboard-config/symbols/gb
+++ b/xorg-server/xkeyboard-config/symbols/gb
@@ -169,10 +169,12 @@ xkb_symbols "mac" {
key <AE02> { [ 2, at, EuroSign ] };
key <AE03> { [ 3, sterling, numbersign ] };
+ key <LSGT> { [ grave, asciitilde ] };
// End alphanumeric section
include "level3(ralt_switch)"
+ include "level3(enter_switch)"
};
diff --git a/xorg-server/xkeyboard-config/symbols/macintosh_vndr/apple b/xorg-server/xkeyboard-config/symbols/macintosh_vndr/apple
index cbbf110d3..551eabc33 100644
--- a/xorg-server/xkeyboard-config/symbols/macintosh_vndr/apple
+++ b/xorg-server/xkeyboard-config/symbols/macintosh_vndr/apple
@@ -1,141 +1,141 @@
-//
-// Keyboard modification for Apple keyboards
-//
-
-partial default modifier_keys
-xkb_symbols "extended" {
-
- key <KPEQ> { [ KP_Equal ] };
-
-// The key in the PC's Insert position is sometimes engraved Help (at least
-// in Switzerland and Great Britain), with Insert sometimes above. But in the
-// US and Canada, it remains Insert. So this should probably be an XkbOption,
-// but I have to do more research.
-// Perhaps Help should be the primary symbol with Insert in the 1st shift-level
-// key <INS> { [ Help, Insert ] };
-// The keys next to F12, labeled F13, F14, & F15 generate codes that XFree86
-// claims not to generate. I think they should be equivalent to the PC keys
-// Print Screen / SysRq, Scroll Lock, and Pause. Linux kernel bug?
-// key <PRSC> { [ F13 ] }; // should be keycode 93 or
-// key <FK13> { [ F13 ] }; // should be keycode 118
-// key <SCLK> { [ F14 ] }; // should be keycode 123 or
-// key <FK14> { [ F14 ] }; // should be keycode 119
-// key <PAUS> { [ F15 ] }; // should be keycode 127 or
-// key <FK15> { [ F15 ] }; // should be keycode 120
-};
-
-partial modifier_keys
-xkb_symbols "laptop" {
-
- include "macintosh_vndr/apple(extended)"
-
- // The real numlock key on the iBook (shared with F5) works internally to
- // the keyboard. It illuminates the Num_Lock led and locks the fn-key to
- // type only the keypad keys on the letter keys (U=4, I=5, O=6, P=*, etc.).
- // The key in the Num_lock position is engraved with Clear.
- override key <NMLK> { [ Clear ] };
- // The key engraved Delete sends BKSP. To get Delete, use Shift-Delete
- override key <BKSP> { [ BackSpace, Delete ] };
- // These keyboards only generate a <RALT> when pressing fn+Alt. This makes
- // it impossible to get to the third shift level on keys that are on
- // the fn-keypad, so use the Enter key (right of <SPC>) for Mode_switch,
- // and use fn+Enter (Apple's code for Menu) for KP_Enter.
- replace key <KPEN> { [ ISO_Level3_Shift ] };
- modifier_map Mod5 { ISO_Level3_Shift };
- // Linux kernel bug with Menu on macs means this doesn't work yet
-// replace key <MENU> { [ KP_Enter ] }; // should be keycode 117
-};
-
-partial modifier_keys
-xkb_symbols "laptop_bad_switch" {
- // Kept for backward compatibility
- include "macintosh_vndr/apple(laptop)"
-};
-
-// Long Aluminium Keyboards
-partial function_keys
-xkb_symbols "alukbd" {
- // The base is a inet PC keyboard
- include "pc"
-
- // Additional Fxx keys
- key <FK13> { [ F13 ] };
- key <FK14> { [ F14 ] };
- key <FK15> { [ F15 ] };
- key <FK16> { [ F16 ] };
- key <FK17> { [ F17 ] };
- key <FK18> { [ F18 ] };
- key <FK19> { [ F19 ] };
-
- // On aluminium keyboards, Num_Lock is replace by Clear
- replace key <NMLK> { [ XF86Clear ] };
- // CAPS key is always Caps_Lock, even for JIS keyboards
- replace key <CAPS> { [ Caps_Lock ] };
-
- // F1..F12 are multimedia keys when used with the 'Fn' key
- // Make those multimedia actions available via ISO_Level3_Shift too,
- // it is useful when the Fn key is remapped to something else (e.g. Insert)
- key <FK01> {
- type= "FOUR_LEVEL_X",
- symbols[Group1]= [ NoSymbol, XF86KbdBrightnessDown, NoSymbol, XF86_Switch_VT_1 ]
- };
- key <FK02> {
- type= "FOUR_LEVEL_X",
- symbols[Group1]= [ NoSymbol, XF86KbdBrightnessUp, NoSymbol, XF86_Switch_VT_2 ]
- };
- key <FK03> {
- type= "FOUR_LEVEL_X",
- symbols[Group1]= [ NoSymbol, NoSymbol, NoSymbol, XF86_Switch_VT_3 ]
- };
- key <FK04> {
- type= "FOUR_LEVEL_X",
- symbols[Group1]= [ NoSymbol, NoSymbol, NoSymbol, XF86_Switch_VT_4 ]
- };
- key <FK05> {
- type= "FOUR_LEVEL_X",
- symbols[Group1]= [ NoSymbol, NoSymbol, NoSymbol, XF86_Switch_VT_5 ]
- };
- key <FK06> {
- type= "FOUR_LEVEL_X",
- symbols[Group1]= [ NoSymbol, NoSymbol, NoSymbol, XF86_Switch_VT_6 ]
- };
- key <FK07> {
- type= "FOUR_LEVEL_X",
- symbols[Group1]= [ NoSymbol, XF86AudioPrev, NoSymbol, XF86_Switch_VT_7 ]
- };
- key <FK08> {
- type= "FOUR_LEVEL_X",
- symbols[Group1]= [ NoSymbol, XF86AudioPlay, NoSymbol, XF86_Switch_VT_8 ]
- };
- key <FK09> {
- type= "FOUR_LEVEL_X",
- symbols[Group1]= [ NoSymbol, XF86AudioNext, NoSymbol, XF86_Switch_VT_9 ]
- };
- key <FK10> {
- type= "FOUR_LEVEL_X",
- symbols[Group1]= [ NoSymbol, XF86AudioMute, NoSymbol, XF86_Switch_VT_10 ]
- };
- key <FK11> {
- type= "FOUR_LEVEL_X",
- symbols[Group1]= [ NoSymbol, XF86AudioLowerVolume, NoSymbol, XF86_Switch_VT_11 ]
- };
- key <FK12> {
- type= "FOUR_LEVEL_X",
- symbols[Group1]= [ NoSymbol, XF86AudioRaiseVolume, NoSymbol, XF86_Switch_VT_12 ]
- };
-};
-
-// Aluminium Keyboard: make F13, F14, F15 PC-ish (Print, Scroll_Lock, Pause)
-partial function_keys keypad_keys
-xkb_symbols "alupckeys" {
- key <FK13> {
- type= "PC_ALT_LEVEL2",
- symbols[Group1]= [ Print, Sys_Req ]
- };
- key <FK14> { [ Scroll_Lock ] };
- key <FK15> {
- type= "PC_CONTROL_LEVEL2",
- symbols[Group1]= [ Pause, Break ]
- };
- override key <NMLK> { [ Num_Lock, Pointer_EnableKeys ] };
-};
+//
+// Keyboard modification for Apple keyboards
+//
+
+partial default modifier_keys
+xkb_symbols "extended" {
+
+ key <KPEQ> { [ KP_Equal ] };
+
+// The key in the PC's Insert position is sometimes engraved Help (at least
+// in Switzerland and Great Britain), with Insert sometimes above. But in the
+// US and Canada, it remains Insert. So this should probably be an XkbOption,
+// but I have to do more research.
+// Perhaps Help should be the primary symbol with Insert in the 1st shift-level
+// key <INS> { [ Help, Insert ] };
+// The keys next to F12, labeled F13, F14, & F15 generate codes that XFree86
+// claims not to generate. I think they should be equivalent to the PC keys
+// Print Screen / SysRq, Scroll Lock, and Pause. Linux kernel bug?
+// key <PRSC> { [ F13 ] }; // should be keycode 93 or
+// key <FK13> { [ F13 ] }; // should be keycode 118
+// key <SCLK> { [ F14 ] }; // should be keycode 123 or
+// key <FK14> { [ F14 ] }; // should be keycode 119
+// key <PAUS> { [ F15 ] }; // should be keycode 127 or
+// key <FK15> { [ F15 ] }; // should be keycode 120
+};
+
+partial modifier_keys
+xkb_symbols "laptop" {
+
+ include "macintosh_vndr/apple(extended)"
+
+ // The real numlock key on the iBook (shared with F5) works internally to
+ // the keyboard. It illuminates the Num_Lock led and locks the fn-key to
+ // type only the keypad keys on the letter keys (U=4, I=5, O=6, P=*, etc.).
+ // The key in the Num_lock position is engraved with Clear.
+ override key <NMLK> { [ Clear ] };
+ // The key engraved Delete sends BKSP. To get Delete, use Shift-Delete
+ override key <BKSP> { [ BackSpace, Delete ] };
+ // These keyboards only generate a <RALT> when pressing fn+Alt. This makes
+ // it impossible to get to the third shift level on keys that are on
+ // the fn-keypad, so use the Enter key (right of <SPC>) for Mode_switch,
+ // and use fn+Enter (Apple's code for Menu) for KP_Enter.
+ replace key <KPEN> { [ ISO_Level3_Shift ] };
+ modifier_map Mod5 { ISO_Level3_Shift };
+ // Linux kernel bug with Menu on macs means this doesn't work yet
+// replace key <MENU> { [ KP_Enter ] }; // should be keycode 117
+};
+
+partial modifier_keys
+xkb_symbols "laptop_bad_switch" {
+ // Kept for backward compatibility
+ include "macintosh_vndr/apple(laptop)"
+};
+
+// Long Aluminium Keyboards
+partial function_keys
+xkb_symbols "alukbd" {
+ // The base is a inet PC keyboard
+ include "pc"
+
+ // Additional Fxx keys
+ key <FK13> { [ F13 ] };
+ key <FK14> { [ F14 ] };
+ key <FK15> { [ F15 ] };
+ key <FK16> { [ F16 ] };
+ key <FK17> { [ F17 ] };
+ key <FK18> { [ F18 ] };
+ key <FK19> { [ F19 ] };
+
+ // On aluminium keyboards, Num_Lock is replace by Clear
+ replace key <NMLK> { [ Clear ] };
+ // CAPS key is always Caps_Lock, even for JIS keyboards
+ replace key <CAPS> { [ Caps_Lock ] };
+
+ // F1..F12 are multimedia keys when used with the 'Fn' key
+ // Make those multimedia actions available via ISO_Level3_Shift too,
+ // it is useful when the Fn key is remapped to something else (e.g. Insert)
+ key <FK01> {
+ type= "FOUR_LEVEL_X",
+ symbols[Group1]= [ NoSymbol, XF86KbdBrightnessDown, NoSymbol, XF86_Switch_VT_1 ]
+ };
+ key <FK02> {
+ type= "FOUR_LEVEL_X",
+ symbols[Group1]= [ NoSymbol, XF86KbdBrightnessUp, NoSymbol, XF86_Switch_VT_2 ]
+ };
+ key <FK03> {
+ type= "FOUR_LEVEL_X",
+ symbols[Group1]= [ NoSymbol, NoSymbol, NoSymbol, XF86_Switch_VT_3 ]
+ };
+ key <FK04> {
+ type= "FOUR_LEVEL_X",
+ symbols[Group1]= [ NoSymbol, NoSymbol, NoSymbol, XF86_Switch_VT_4 ]
+ };
+ key <FK05> {
+ type= "FOUR_LEVEL_X",
+ symbols[Group1]= [ NoSymbol, NoSymbol, NoSymbol, XF86_Switch_VT_5 ]
+ };
+ key <FK06> {
+ type= "FOUR_LEVEL_X",
+ symbols[Group1]= [ NoSymbol, NoSymbol, NoSymbol, XF86_Switch_VT_6 ]
+ };
+ key <FK07> {
+ type= "FOUR_LEVEL_X",
+ symbols[Group1]= [ NoSymbol, XF86AudioPrev, NoSymbol, XF86_Switch_VT_7 ]
+ };
+ key <FK08> {
+ type= "FOUR_LEVEL_X",
+ symbols[Group1]= [ NoSymbol, XF86AudioPlay, NoSymbol, XF86_Switch_VT_8 ]
+ };
+ key <FK09> {
+ type= "FOUR_LEVEL_X",
+ symbols[Group1]= [ NoSymbol, XF86AudioNext, NoSymbol, XF86_Switch_VT_9 ]
+ };
+ key <FK10> {
+ type= "FOUR_LEVEL_X",
+ symbols[Group1]= [ NoSymbol, XF86AudioMute, NoSymbol, XF86_Switch_VT_10 ]
+ };
+ key <FK11> {
+ type= "FOUR_LEVEL_X",
+ symbols[Group1]= [ NoSymbol, XF86AudioLowerVolume, NoSymbol, XF86_Switch_VT_11 ]
+ };
+ key <FK12> {
+ type= "FOUR_LEVEL_X",
+ symbols[Group1]= [ NoSymbol, XF86AudioRaiseVolume, NoSymbol, XF86_Switch_VT_12 ]
+ };
+};
+
+// Aluminium Keyboard: make F13, F14, F15 PC-ish (Print, Scroll_Lock, Pause)
+partial function_keys keypad_keys
+xkb_symbols "alupckeys" {
+ key <FK13> {
+ type= "PC_ALT_LEVEL2",
+ symbols[Group1]= [ Print, Sys_Req ]
+ };
+ key <FK14> { [ Scroll_Lock ] };
+ key <FK15> {
+ type= "PC_CONTROL_LEVEL2",
+ symbols[Group1]= [ Pause, Break ]
+ };
+ override key <NMLK> { [ Num_Lock, Pointer_EnableKeys ] };
+};
diff --git a/xorg-server/xkeyboard-config/types/extra b/xorg-server/xkeyboard-config/types/extra
index 06b1fec78..465796b53 100644
--- a/xorg-server/xkeyboard-config/types/extra
+++ b/xorg-server/xkeyboard-config/types/extra
@@ -1,183 +1,161 @@
-partial default xkb_types "default" {
- // Definition for a key type used for the czech keymap, for instance.
- // Defines style a with four level shift. It is similar to three_level
- // type used for iso9995 but it lets the shift key behave "normally".
-
- virtual_modifiers LevelThree;
-
- type "FOUR_LEVEL" {
- modifiers = Shift+LevelThree;
- map[None] = Level1;
- map[Shift] = Level2;
- map[LevelThree] = Level3;
- map[Shift+LevelThree] = Level4;
- level_name[Level1] = "Base";
- level_name[Level2] = "Shift";
- level_name[Level3] = "Alt Base";
- level_name[Level4] = "Shift Alt";
- };
-
- type "FOUR_LEVEL_ALPHABETIC" {
- modifiers = Shift+Lock+LevelThree;
- map[None] = Level1;
- map[Shift] = Level2;
- map[Lock] = Level2;
- map[LevelThree] = Level3;
- map[Shift+LevelThree] = Level4;
- map[Lock+LevelThree] = Level4;
- map[Lock+Shift+LevelThree] = Level3;
- level_name[Level1] = "Base";
- level_name[Level2] = "Shift";
- level_name[Level3] = "Alt Base";
- level_name[Level4] = "Shift Alt";
- };
-
- type "FOUR_LEVEL_SEMIALPHABETIC" {
- modifiers = Shift+Lock+LevelThree;
- map[None] = Level1;
- map[Shift] = Level2;
- map[Lock] = Level2;
- map[LevelThree] = Level3;
- map[Shift+LevelThree] = Level4;
- map[Lock+LevelThree] = Level3;
- map[Lock+Shift+LevelThree] = Level4;
- preserve[Lock+LevelThree] = Lock;
- preserve[Lock+Shift+LevelThree] = Lock;
- level_name[Level1] = "Base";
- level_name[Level2] = "Shift";
- level_name[Level3] = "Alt Base";
- level_name[Level4] = "Shift Alt";
- };
-
- // Another four level keypad variant
- // First two levels are controled by NumLock (with active Shift-ing like
- // in KEYPAD). LevelThree overrides this mode, with two additional
- // Shift-ed levels
- // NumLock state is intentionnaly ignored when LevelThree is active
- type "FOUR_LEVEL_MIXED_KEYPAD" {
- modifiers = Shift+NumLock+LevelThree;
- map[None] = Level1;
- map[Shift+NumLock] = Level1;
- map[NumLock] = Level2;
- map[Shift] = Level2;
- map[LevelThree] = Level3;
- map[NumLock+LevelThree] = Level3;
- map[Shift+LevelThree] = Level4;
- map[Shift+NumLock+LevelThree] = Level4;
- level_name[Level1] = "Base";
- level_name[Level2] = "Number";
- level_name[Level3] = "Alt Base";
- level_name[Level4] = "Shift Alt";
- };
-
- // Base level, two Shift-ed LevelThree levels, one Ctrl+Alt command level
- type "FOUR_LEVEL_X" {
- modifiers = Shift+LevelThree+Control+Alt;
- map[None] = Level1;
- map[LevelThree] = Level2;
- map[Shift+LevelThree] = Level3;
- map[Control+Alt] = Level4;
- level_name[Level1] = "Base";
- level_name[Level2] = "Alt Base";
- level_name[Level3] = "Shift Alt";
- level_name[Level4] = "Ctrl+Alt";
- };
-
-// Special type for keys used in Serbian Latin Unicode map
-// It makes it possible to use all three forms of latin letters
-// present in Unicode that are made up of two separate letters
-// (forms like LJ, Lj, and lj; NJ, Nj, and nj; etc)
-
- type "SEPARATE_CAPS_AND_SHIFT_ALPHABETIC" {
- modifiers = Shift+Lock+LevelThree;
- map[None] = Level1;
- map[Shift] = Level2;
- map[Lock] = Level4;
- map[LevelThree] = Level3;
- map[Shift+LevelThree] = Level4;
- map[Lock+LevelThree] = Level3;
- map[Lock+Shift+LevelThree] = Level3;
- preserve[Lock]= Lock;
- preserve[Lock+LevelThree]= Lock;
- level_name[Level1] = "Base";
- level_name[Level2] = "Shift";
- level_name[Level3] = "AltGr Base";
- level_name[Level4] = "Shift AltGr";
- };
-
-// type for e.g. german ssharp which is capitalized SS.
-// CHARACTERISTICS:
-// It is FOUR_LEVEL with the exception that the fifth level
-// is mapped to the Lock modifier.
-// If other modifiers are used, the Lock state is ignored.
-// DETAILS ABOUT GERMAN:
-// The capital form of ssharp (called sharp s) only exists for
-// completely capitalized Text, not at the beginning of sentences
-// or nouns (nouns have a captial letter at the beginning in german).
-// The ssharp key, to the right of the zero key, takes this into
-// account and has a questionmark mapped on shift-ssharp since
-// normally no capital version is needed.
-// When typing with active capsLock, this key type is needed to
-// output two capital letters S because this is the only german key
-// whose capital letter is not the same as the one typed with shift.
-
- type "FOUR_LEVEL_PLUS_LOCK" {
- modifiers = Shift+Lock+LevelThree;
- map[None] = Level1;
- map[Shift] = Level2;
- map[LevelThree] = Level3;
- map[Shift+LevelThree] = Level4;
- map[Lock] = Level5;
- map[Lock+Shift] = Level2;
- map[Lock+LevelThree] = Level3;
- map[Lock+Shift+LevelThree] = Level4;
- level_name[Level1] = "Base";
- level_name[Level2] = "Shift";
- level_name[Level3] = "Alt Base";
- level_name[Level4] = "Shift Alt";
- level_name[Level5] = "Lock";
- };
-};
-
-// This enables the four level shifting also for the keypad.
-partial xkb_types "keypad" {
- virtual_modifiers LevelThree;
-
- type "FOUR_LEVEL_KEYPAD" {
- modifiers = Shift+NumLock+LevelThree;
- map[None] = Level1;
- map[Shift] = Level2;
- map[NumLock] = Level2;
- map[Shift+NumLock] = Level1;
- map[LevelThree] = Level3;
- map[Shift+LevelThree] = Level4;
- map[NumLock+LevelThree] = Level4;
- map[Shift+NumLock+LevelThree] = Level3;
- level_name[Level1] = "Base";
- level_name[Level2] = "Number";
- level_name[Level3] = "Alt Base";
- level_name[Level4] = "Alt Number";
- };
-};
-
-// This enables the four level shifting also for the keypad,
-// but levels 1 and 2, and 3 and 4 are swapped on Mac keypads.
-partial xkb_types "mac_keypad" {
- virtual_modifiers LevelThree;
-
- type "FOUR_LEVEL_KEYPAD" {
- modifiers = Shift+NumLock+LevelThree;
- map[None] = Level2;
- map[Shift] = Level1;
- map[NumLock] = Level1;
- map[Shift+NumLock] = Level2;
- map[LevelThree] = Level4;
- map[Shift+LevelThree] = Level3;
- map[NumLock+LevelThree] = Level3;
- map[Shift+NumLock+LevelThree] = Level4;
- level_name[Level2] = "Base";
- level_name[Level1] = "Number";
- level_name[Level4] = "Alt Base";
- level_name[Level3] = "Alt Number";
- };
-};
+partial default xkb_types "default" {
+ // Definition for a key type used for the czech keymap, for instance.
+ // Defines style a with four level shift. It is similar to three_level
+ // type used for iso9995 but it lets the shift key behave "normally".
+
+ virtual_modifiers LevelThree;
+
+ type "FOUR_LEVEL" {
+ modifiers = Shift+LevelThree;
+ map[None] = Level1;
+ map[Shift] = Level2;
+ map[LevelThree] = Level3;
+ map[Shift+LevelThree] = Level4;
+ level_name[Level1] = "Base";
+ level_name[Level2] = "Shift";
+ level_name[Level3] = "Alt Base";
+ level_name[Level4] = "Shift Alt";
+ };
+
+ type "FOUR_LEVEL_ALPHABETIC" {
+ modifiers = Shift+Lock+LevelThree;
+ map[None] = Level1;
+ map[Shift] = Level2;
+ map[Lock] = Level2;
+ map[LevelThree] = Level3;
+ map[Shift+LevelThree] = Level4;
+ map[Lock+LevelThree] = Level4;
+ map[Lock+Shift+LevelThree] = Level3;
+ level_name[Level1] = "Base";
+ level_name[Level2] = "Shift";
+ level_name[Level3] = "Alt Base";
+ level_name[Level4] = "Shift Alt";
+ };
+
+ type "FOUR_LEVEL_SEMIALPHABETIC" {
+ modifiers = Shift+Lock+LevelThree;
+ map[None] = Level1;
+ map[Shift] = Level2;
+ map[Lock] = Level2;
+ map[LevelThree] = Level3;
+ map[Shift+LevelThree] = Level4;
+ map[Lock+LevelThree] = Level3;
+ map[Lock+Shift+LevelThree] = Level4;
+ preserve[Lock+LevelThree] = Lock;
+ preserve[Lock+Shift+LevelThree] = Lock;
+ level_name[Level1] = "Base";
+ level_name[Level2] = "Shift";
+ level_name[Level3] = "Alt Base";
+ level_name[Level4] = "Shift Alt";
+ };
+
+ // Another four level keypad variant
+ // First two levels are controled by NumLock (with active Shift-ing like
+ // in KEYPAD). LevelThree overrides this mode, with two additional
+ // Shift-ed levels
+ // NumLock state is intentionnaly ignored when LevelThree is active
+ type "FOUR_LEVEL_MIXED_KEYPAD" {
+ modifiers = Shift+NumLock+LevelThree;
+ map[None] = Level1;
+ map[Shift+NumLock] = Level1;
+ map[NumLock] = Level2;
+ map[Shift] = Level2;
+ map[LevelThree] = Level3;
+ map[NumLock+LevelThree] = Level3;
+ map[Shift+LevelThree] = Level4;
+ map[Shift+NumLock+LevelThree] = Level4;
+ level_name[Level1] = "Base";
+ level_name[Level2] = "Number";
+ level_name[Level3] = "Alt Base";
+ level_name[Level4] = "Shift Alt";
+ };
+
+ // Base level, two Shift-ed LevelThree levels, one Ctrl+Alt command level
+ type "FOUR_LEVEL_X" {
+ modifiers = Shift+LevelThree+Control+Alt;
+ map[None] = Level1;
+ map[LevelThree] = Level2;
+ map[Shift+LevelThree] = Level3;
+ map[Control+Alt] = Level4;
+ level_name[Level1] = "Base";
+ level_name[Level2] = "Alt Base";
+ level_name[Level3] = "Shift Alt";
+ level_name[Level4] = "Ctrl+Alt";
+ };
+
+// Special type for keys used in Serbian Latin Unicode map
+// It makes it possible to use all three forms of latin letters
+// present in Unicode that are made up of two separate letters
+// (forms like LJ, Lj, and lj; NJ, Nj, and nj; etc)
+
+ type "SEPARATE_CAPS_AND_SHIFT_ALPHABETIC" {
+ modifiers = Shift+Lock+LevelThree;
+ map[None] = Level1;
+ map[Shift] = Level2;
+ map[Lock] = Level4;
+ map[LevelThree] = Level3;
+ map[Shift+LevelThree] = Level4;
+ map[Lock+LevelThree] = Level3;
+ map[Lock+Shift+LevelThree] = Level3;
+ preserve[Lock]= Lock;
+ preserve[Lock+LevelThree]= Lock;
+ level_name[Level1] = "Base";
+ level_name[Level2] = "Shift";
+ level_name[Level3] = "AltGr Base";
+ level_name[Level4] = "Shift AltGr";
+ };
+
+// type for e.g. german ssharp which is capitalized SS.
+// CHARACTERISTICS:
+// It is FOUR_LEVEL with the exception that the fifth level
+// is mapped to the Lock modifier.
+// If other modifiers are used, the Lock state is ignored.
+// DETAILS ABOUT GERMAN:
+// The capital form of ssharp (called sharp s) only exists for
+// completely capitalized Text, not at the beginning of sentences
+// or nouns (nouns have a captial letter at the beginning in german).
+// The ssharp key, to the right of the zero key, takes this into
+// account and has a questionmark mapped on shift-ssharp since
+// normally no capital version is needed.
+// When typing with active capsLock, this key type is needed to
+// output two capital letters S because this is the only german key
+// whose capital letter is not the same as the one typed with shift.
+
+ type "FOUR_LEVEL_PLUS_LOCK" {
+ modifiers = Shift+Lock+LevelThree;
+ map[None] = Level1;
+ map[Shift] = Level2;
+ map[LevelThree] = Level3;
+ map[Shift+LevelThree] = Level4;
+ map[Lock] = Level5;
+ map[Lock+Shift] = Level2;
+ map[Lock+LevelThree] = Level3;
+ map[Lock+Shift+LevelThree] = Level4;
+ level_name[Level1] = "Base";
+ level_name[Level2] = "Shift";
+ level_name[Level3] = "Alt Base";
+ level_name[Level4] = "Shift Alt";
+ level_name[Level5] = "Lock";
+ };
+};
+
+// This enables the four level shifting also for the keypad.
+partial xkb_types "keypad" {
+ virtual_modifiers LevelThree;
+
+ type "FOUR_LEVEL_KEYPAD" {
+ modifiers = Shift+NumLock+LevelThree;
+ map[None] = Level1;
+ map[Shift] = Level2;
+ map[NumLock] = Level2;
+ map[Shift+NumLock] = Level1;
+ map[LevelThree] = Level3;
+ map[Shift+LevelThree] = Level4;
+ map[NumLock+LevelThree] = Level4;
+ map[Shift+NumLock+LevelThree] = Level3;
+ level_name[Level1] = "Base";
+ level_name[Level2] = "Number";
+ level_name[Level3] = "Alt Base";
+ level_name[Level4] = "Alt Number";
+ };
+};
diff --git a/xorg-server/xkeyboard-config/types/numpad b/xorg-server/xkeyboard-config/types/numpad
index 82c22a917..7888d7db1 100644
--- a/xorg-server/xkeyboard-config/types/numpad
+++ b/xorg-server/xkeyboard-config/types/numpad
@@ -1,71 +1,67 @@
-partial default xkb_types "pc" {
- type "KEYPAD" {
- modifiers = Shift+NumLock;
- map[None] = Level1;
- map[Shift] = Level2;
- map[NumLock] = Level2;
- map[Shift+NumLock] = Level1;
- level_name[Level1] = "Base";
- level_name[Level2] = "Number";
- };
- include "extra(keypad)"
-};
-
-// On Mac keypads, level 1 and 2 are swapped
-partial xkb_types "mac" {
- type "KEYPAD" {
- modifiers = Shift+NumLock;
- map[None] = Level2;
- map[Shift] = Level1;
- map[NumLock] = Level1;
- map[Shift+NumLock] = Level2;
- level_name[Level2] = "Base";
- level_name[Level1] = "Number";
- };
- include "extra(mac_keypad)"
-};
-
-partial xkb_types "microsoft" {
- type "KEYPAD" {
- modifiers = Shift+NumLock;
- map[None] = Level1;
- preserve[Shift] = Shift;
- map[NumLock] = Level2;
- level_name[Level1] = "Base";
- level_name[Level2] = "Number";
- };
- include "extra(keypad)"
-};
-
-// Swiss-German style numeric keypad: Shift and NumLock operates as
-// two independent modifiers; however, since we want shift state for
-// the cursor keys, only three levels are used from the key mappings.
-// Closest type is actually FOUR_LEVEL_X, but most numpad layouts uses
-// FOUR_LEVEL_MIXED_KEYPAD so that's the one we are going to override.
-partial xkb_types "shift3" {
- type "FOUR_LEVEL_MIXED_KEYPAD" {
- modifiers = Shift+NumLock+Control+Alt;
-
- // NumLock Off => navigate using cursor keys
- map[None] = Level1;
-
- // NumLock Off + Shift pressed => select using cursor keys
- preserve[Shift] = Shift;
-
- // NumLock On => decimal digits
- map[NumLock] = Level2;
-
- // NumLock On + Shift pressed => auxiliary symbols,
- // e.g. hexadecimal digits
- map[Shift+NumLock] = Level3;
-
- // Ctrl + Alt, regardless of NumLock and Shift => command keys
- map[Control+Alt] = Level4;
-
- // reverse map from levels to modifiers
- level_name[Level1] = "Base";
- level_name[Level2] = "NumLock";
- level_name[Level3] = "Shift+NumLock";
- level_name[Level4] = "Ctrl+Alt";
- };
-};
+partial default xkb_types "pc" {
+ type "KEYPAD" {
+ modifiers = Shift+NumLock;
+ map[None] = Level1;
+ map[Shift] = Level2;
+ map[NumLock] = Level2;
+ map[Shift+NumLock] = Level1;
+ level_name[Level1] = "Base";
+ level_name[Level2] = "Number";
+ };
+ include "extra(keypad)"
+};
+
+// On Mac keypads, level 1 and 2 are swapped
+partial xkb_types "mac" {
+ type "KEYPAD" {
+ modifiers = None;
+ map[None] = Level2;
+ level_name[Level2] = "Number";
+ };
+ include "extra(keypad)"
+};
+
+partial xkb_types "microsoft" {
+ type "KEYPAD" {
+ modifiers = Shift+NumLock;
+ map[None] = Level1;
+ preserve[Shift] = Shift;
+ map[NumLock] = Level2;
+ level_name[Level1] = "Base";
+ level_name[Level2] = "Number";
+ };
+ include "extra(keypad)"
+};
+
+// Swiss-German style numeric keypad: Shift and NumLock operates as
+// two independent modifiers; however, since we want shift state for
+// the cursor keys, only three levels are used from the key mappings.
+// Closest type is actually FOUR_LEVEL_X, but most numpad layouts uses
+// FOUR_LEVEL_MIXED_KEYPAD so that's the one we are going to override.
+partial xkb_types "shift3" {
+ type "FOUR_LEVEL_MIXED_KEYPAD" {
+ modifiers = Shift+NumLock+Control+Alt;
+
+ // NumLock Off => navigate using cursor keys
+ map[None] = Level1;
+
+ // NumLock Off + Shift pressed => select using cursor keys
+ preserve[Shift] = Shift;
+
+ // NumLock On => decimal digits
+ map[NumLock] = Level2;
+
+ // NumLock On + Shift pressed => auxiliary symbols,
+ // e.g. hexadecimal digits
+ map[Shift+NumLock] = Level3;
+
+ // Ctrl + Alt, regardless of NumLock and Shift => command keys
+ map[Control+Alt] = Level4;
+
+ // reverse map from levels to modifiers
+ level_name[Level1] = "Base";
+ level_name[Level2] = "NumLock";
+ level_name[Level3] = "Shift+NumLock";
+ level_name[Level4] = "Ctrl+Alt";
+ };
+};