Fix keymap generator, drop prototype keymap

This commit is contained in:
Ondrej Jirman 2021-08-31 19:00:49 +02:00
parent f1e3f6dce6
commit 62e2ebe7ec
3 changed files with 2 additions and 65 deletions

View File

@ -1,63 +0,0 @@
# physical layout Row:Col -> KEY COMBO_KEY1 COMBO_KEY2
# combo1 is using FN key, combo2 is using PINE key
# see factory-keymap.jpg
# https://elixir.bootlin.com/linux/latest/source/include/uapi/linux/input-event-codes.h#L76
1:1 ESC
1:2 1 LEFTSHIFT+BACKSLASH F1
1:3 2 BACKSLASH F2
1:4 3 DOLLAR F3 # pound, really, but who uses that? also it doesn't have a keycode in Linux
1:5 4 EURO F4
1:6 5 LEFTSHIFT+GRAVE F5
1:7 6 GRAVE F6
1:8 7 MINUS F7
1:9 8 EQUAL F8
1:10 9 LEFTSHIFT+MINUS F9
1:11 0 PLUS F10
1:12 BACKSPACE DELETE
2:1 TAB
2:2 Q
2:3 W
2:4 E
2:5 R
2:6 T
2:7 Y Z
2:8 U
2:9 I
2:10 O
2:11 P
2:12 ENTER
3:1 LEFTMETA LEFTSHIFT+SYSRQ # LEFTMETA = PINE key
3:2 A
3:3 S
3:4 D
3:5 F
3:6 G
3:7 H
3:8 J
3:9 K
3:10 L
3:11 SEMICOLON INSERT
4:1 LEFTSHIFT
4:2 Z
4:3 X
4:4 C LEFTCTRL
4:5 V
4:6 B
4:7 N
4:8 M
4:9 COMMA HOME
4:10 DOT UP
4:11 SLASH END
5:1 LEFTCTRL
5:2 FN
5:3 LEFTALT
5:4 SPACE
5:5 RIGHTALT
5:6 APOSTROPHE LEFT
5:7 LEFTBRACE DOWN
5:8 RIGHTBRACE RIGHT

View File

@ -13,7 +13,7 @@
1:8 7 MINUS F7
1:9 8 EQUAL F8
1:10 9 LEFTSHIFT+MINUS F9
1:11 0 PLUS F10
1:11 0 KPPLUS F10
1:12 BACKSPACE DELETE
2:1 TAB

View File

@ -57,7 +57,7 @@ foreach (explode("\n", $kmap) as $ln) {
for ($i = 0; $i < 3; $i++) {
$alt = $alts[$i] ?? null;
if (!$alt)
if ($alt === null)
break;
$keys = preg_split('#\+#', $alt, -1, PREG_SPLIT_NO_EMPTY);