feat: switch text to UTF-8; add Unicode key events, dead keys & Czech layout; fix numpad navigation; add NumLock support

This commit is contained in:
daniel committed 2026-10-03 10:11:49 +02:00
1 parent 32660ddd1a
commit 2aa6360b3d
101 files changed
+3733 -1639

No files matched your search

+44 -11
View File
@@ -15,15 +15,10 @@
# base: character produced unshifted, one per scancode
# shift: character produced with Shift held, one per scancode
# altgr: character produced with AltGr held, one per scancode
#
# Characters are Windows-1252 byte values.
#
# A value of 0x00 means "no override" - the key keeps whatever the kernel's
# US scancode table produced. This is how a layout declares only the keys it
# actually changes.
# dead_keys: (optional) characters that are dead keys in this layout
[registry]
layouts = ["en", "no", "sv", "da"]
layouts = ["en", "no", "sv", "da", "cs"]
# =============================================================================
# LAYOUTS
@@ -54,7 +49,7 @@ shift = [
]
altgr = [
0x40, 0xA3, 0x24, 0x00, 0x7B, 0x5B, 0x5D, 0x7D, # @ GBP $ . { [ ] }
0x00, 0xB4, 0x80, 0x00, 0x7E, 0x00, 0x00, 0x00, # . ' EUR . ~ . . .
0x00, 0xB4, 0x20AC, 0x00, 0x7E, 0x00, 0x00, 0x00, # . ' EUR . ~ . . .
0x00, 0x00, 0x00, 0x00, 0x5C, # . . . . backslash
]
@@ -77,8 +72,8 @@ shift = [
0xBD, 0x2A, 0x3B, 0x3A, 0x5F, 0x3E, # 1/2 * ; : _ >
]
altgr = [
0x40, 0xA3, 0x24, 0x80, 0xA5, 0x7B, 0x5B, 0x5D, # @ GBP $ EUR YEN { [ ]
0x7D, 0x5C, 0xB1, 0x80, 0x00, 0x7E, 0xF8, 0xE6, # } bslash +- EUR . ~ o/ ae
0x40, 0xA3, 0x24, 0x20AC, 0xA5, 0x7B, 0x5B, 0x5D, # @ GBP $ EUR YEN { [ ]
0x7D, 0x5C, 0xB1, 0x20AC, 0x00, 0x7E, 0xF8, 0xE6, # } bslash +- EUR . ~ o/ ae
0xB6, 0xB4, 0x00, 0xB7, 0x00, 0x7C, # par ' . mid . |
]
@@ -102,6 +97,44 @@ shift = [
]
altgr = [
0x40, 0xA3, 0x24, 0xBD, 0xA5, 0x7B, 0x5B, 0x5D, # @ GBP $ 1/2 YEN { [ ]
0x7D, 0xB1, 0x7C, 0x80, 0x00, 0x7E, 0xB4, 0x5E, # } +- | EUR . ~ ' ^
0x7D, 0xB1, 0x7C, 0x20AC, 0x00, 0x7E, 0xB4, 0x5E, # } +- | EUR . ~ ' ^
0xBE, 0x00, 0x00, 0xB7, 0x00, 0x5C, # 3/4 . . mid . backslash
]
[layouts.cs]
name = "Czech"
short_name = "cs"
# QWERTZ. The number row types accented letters (digits with Shift), and
# AltGr on the number row gives the dead accents.
scancodes = [
0x29, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08,
0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x10, 0x11, 0x12,
0x15, 0x1a, 0x1b, 0x21, 0x22, 0x25, 0x26, 0x27,
0x28, 0x2b, 0x2c, 0x2d, 0x2e, 0x2f, 0x30, 0x31,
0x33, 0x34, 0x35, 0x56,
]
base = [
0x3B, 0x2B, 0x11B, 0x161, 0x10D, 0x159, 0x17E, 0xFD, # ; + e-caron s-caron c-caron r-caron z-caron y-acute
0xE1, 0xED, 0xE9, 0x3D, 0xB4, 0x00, 0x00, 0x00, # a-acute i-acute e-acute = (dead acute) . . .
0x7A, 0xFA, 0x29, 0x00, 0x00, 0x00, 0x00, 0x16F, # z u-acute ) . . . . u-ring
0xA7, 0xA8, 0x79, 0x00, 0x00, 0x00, 0x00, 0x00, # section (dead diaeresis) y . . . . .
0x2C, 0x2E, 0x2D, 0x5C, # , . - backslash
]
shift = [
0xB0, 0x31, 0x32, 0x33, 0x34, 0x35, 0x36, 0x37, # (dead ring) 1 2 3 4 5 6 7
0x38, 0x39, 0x30, 0x25, 0x2C7, 0x00, 0x00, 0x00, # 8 9 0 % (dead caron) . . .
0x5A, 0x2F, 0x28, 0x00, 0x00, 0x00, 0x00, 0x22, # Z / ( . . . . "
0x21, 0x27, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, # ! ' Y . . . . .
0x3F, 0x3A, 0x5F, 0x7C, # ? : _ |
]
altgr = [
0x00, 0x7E, 0x2C7, 0x5E, 0x2D8, 0xB0, 0x2DB, 0x60, # . dead: tilde caron circumflex breve ring ogonek grave
0x2D9, 0xB4, 0x2DD, 0xA8, 0xB8, 0x5C, 0x7C, 0x20AC, # dead: dot acute double-acute diaeresis cedilla; backslash | EUR
0x00, 0xF7, 0xD7, 0x5B, 0x5D, 0x142, 0x141, 0x24, # . divide multiply [ ] l-stroke L-stroke $
0xDF, 0xA4, 0x00, 0x23, 0x26, 0x40, 0x7B, 0x7D, # sharp-s currency . # & @ { }
0x3C, 0x3E, 0x2A, 0x00, # < > * .
]
dead_keys = [
0xB4, 0x2C7, 0xA8, 0xB0, 0x7E, 0x5E,
0x2D8, 0x2DB, 0x60, 0x2D9, 0x2DD, 0xB8,
]