blob: 0b28809ca6bf5c15c622c49d8f613703005a4d39 [file] [log] [blame]
diff --git a/symbols/pc b/symbols/pc
index 9f3da66..bccf56b 100644
--- a/symbols/pc
+++ b/symbols/pc
@@ -19,7 +19,16 @@ xkb_symbols "pc105" {
include "pc(editing)"
include "keypad(x11)"
- key <BKSP> { [ BackSpace ] };
+ key <BKSP> {
+ type="CONTROL_ALT",
+ repeat=yes,
+ symbols[Group1] = [ BackSpace, Delete, Delete ],
+ actions[Group1] = [
+ NoAction(),
+ RedirectKey(key=<DELE>, clearmods=Alt),
+ RedirectKey(key=<DELE>, clearmods=Alt)
+ ]
+ };
key <TAB> { [ Tab, ISO_Left_Tab ] };
key <RTRN> { [ Return ] };
@@ -141,9 +150,27 @@ xkb_symbols "editing" {
key <END> { [ End ] };
key <PGDN> { [ Next ] };
- key <UP> { [ Up ] };
+ key <UP> {
+ type="CONTROL_ALT",
+ repeat=yes,
+ symbols[Group1] = [ Up, Prior, Home ],
+ actions[Group1] = [
+ NoAction(),
+ RedirectKey(key=<PGUP>, clearmods=Alt),
+ RedirectKey(key=<HOME>, clearmods=Control+Alt)
+ ]
+ };
+ key <DOWN> {
+ type="CONTROL_ALT",
+ repeat=yes,
+ symbols[Group1] = [ Down, Next, End ],
+ actions[Group1] = [
+ NoAction(),
+ RedirectKey(key=<PGDN>, clearmods=Alt),
+ RedirectKey(key=<END>, clearmods=Control+Alt)
+ ]
+ };
+
key <LEFT> { [ Left ] };
- key <DOWN> { [ Down ] };
key <RGHT> { [ Right ] };
};
-
diff --git a/types/basic b/types/basic
index cf1ee64..bcb122c 100644
--- a/types/basic
+++ b/types/basic
@@ -5,6 +5,7 @@ default xkb_types "basic" {
// Fairly standard definitions for
// the four required key types
+ virtual_modifiers Alt;
virtual_modifiers NumLock;
type "ONE_LEVEL" {
@@ -28,4 +29,16 @@ default xkb_types "basic" {
level_name[Level2] = "Caps";
};
+ // Extra type for keys that we want to simulate other keys when Alt or
+ // Control+Alt are down. Level 1 is the key by itself, 2 is Alt, and 3
+ // is Ctrl+Alt.
+ type "CONTROL_ALT" {
+ modifiers = Alt+Control;
+ map[None] = Level1;
+ map[Alt] = Level2;
+ map[Control+Alt] = Level3;
+ level_name[Level1] = "Base";
+ level_name[Level2] = "Alt";
+ level_name[Level3] = "ControlAlt";
+ };
};