Skip to content

Commit

Permalink
Add colemak keyboard layout (#2766)
Browse files Browse the repository at this point in the history
Co-authored-by: Tilman Sauerbeck <[email protected]>
  • Loading branch information
tilman3 and tilman2 authored Mar 25, 2024
1 parent 9bdcabb commit e0be85e
Showing 1 changed file with 46 additions and 1 deletion.
47 changes: 46 additions & 1 deletion luaui/configs/keyboard_layouts.lua
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,44 @@ scanToCode["azerty"]["="] = "="
scanToCode["azerty"]["\\"] = "\\"
-- NEEDS CORRECTION ABOVE

scanToCode["colemak"] = {
Q = "Q",
W = "W",
E = "F",
R = "P",
T = "G",
Y = "J",
U = "L",
I = "U",
O = "Y",
P = ";",
A = "A",
S = "R",
D = "S",
F = "T",
G = "D",
H = "H",
J = "N",
K = "E",
L = "I",
Z = "Z",
X = "X",
C = "C",
V = "V",
B = "B",
N = "K",
M = "M",
[";"] = "O",
["'"] = "'",
[","] = ",",
["."] = ".",
["/"] = "/",
["`"] = "`",
["-"] = "-",
["="] = "=",
["\\"] = "\\",
}

scanToCode["dvorak"] = {
Q = "'",
W = ",",
Expand Down Expand Up @@ -120,7 +158,14 @@ scanToCode["de-neo"] = {
-- NEEDS CORRECTION ABOVE
}

local layouts = { 'qwerty', 'qwertz', 'azerty', 'dvorak', 'de-neo' }
local layouts = {
'qwerty',
'qwertz',
'azerty',
'colemak',
'dvorak',
'de-neo',
}

local function sanitizeKey(key, layout)
if not (type(key) == "string") then
Expand Down

0 comments on commit e0be85e

Please sign in to comment.