aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Brown <mcb30@ipxe.org>2022-02-15 11:43:08 +0000
committerMichael Brown <mcb30@ipxe.org>2022-02-15 13:37:44 +0000
commit164db2cc630932a91119b1aee5fa299d17716819 (patch)
tree07ca2c7449265426f7d92ba3b8c3e9b279b20417
parentc7d78192919bfa62fde33650e1506e902816eec3 (diff)
downloadipxe-164db2cc630932a91119b1aee5fa299d17716819.zip
ipxe-164db2cc630932a91119b1aee5fa299d17716819.tar.gz
ipxe-164db2cc630932a91119b1aee5fa299d17716819.tar.bz2
[console] Fix unreachable characters in "il" keymap
Signed-off-by: Michael Brown <mcb30@ipxe.org>
-rw-r--r--src/hci/keymap/keymap_il.c1
-rwxr-xr-xsrc/util/genkeymap.py6
2 files changed, 7 insertions, 0 deletions
diff --git a/src/hci/keymap/keymap_il.c b/src/hci/keymap/keymap_il.c
index e3061fa..95e33a0 100644
--- a/src/hci/keymap/keymap_il.c
+++ b/src/hci/keymap/keymap_il.c
@@ -31,6 +31,7 @@ static struct keymap_key il_basic[] = {
/** "il" AltGr remapping */
static struct keymap_key il_altgr[] = {
+ { 0x5c, 0x60 }, /* '\\' => '`' */
{ 0, 0 }
};
diff --git a/src/util/genkeymap.py b/src/util/genkeymap.py
index 42ccee1..5f87a89 100755
--- a/src/util/genkeymap.py
+++ b/src/util/genkeymap.py
@@ -176,6 +176,12 @@ class KeyLayout(UserDict[KeyModifiers, Sequence[Key]]):
# Treat Ctrl-Backspace as producing Backspace rather than Ctrl-H
KeyModifiers.CTRL: [(KEY_BACKSPACE, 0x7f)],
},
+ 'il': {
+ # Redefine some otherwise unreachable ASCII characters
+ # using the closest available approximation
+ KeyModifiers.ALTGR: [(0x28, ord('\'')), (0x2b, ord('`')),
+ (0x35, ord('/'))],
+ },
}
"""Fixups for erroneous keymappings produced by 'loadkeys -b'"""