commit 270145d1c214d855dbe32307403cdf46915f3f82
parent f0528fa0de4cd2d9f6371b6bac5cebe0ca4681e7
Author: Maarten van Gompel <proycon@anaproy.nl>
Date: Tue, 24 Aug 2021 23:51:47 +0200
Added landscape layout
Diffstat:
M | layout.mobintl.h | | | 62 | ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ |
1 file changed, 62 insertions(+), 0 deletions(-)
diff --git a/layout.mobintl.h b/layout.mobintl.h
@@ -17,6 +17,7 @@ enum layout_id {
Cyrillic,
Arabic,
Emoji,
+ Landscape,
ComposeA,
ComposeE,
ComposeY,
@@ -77,6 +78,7 @@ static const char *default_font = "Monospace 15";
static struct key keys_full[], keys_special[], keys_simple[], keys_cyrillic[],
keys_arabic[],
keys_emoji[],
+ keys_landscape[],
keys_compose_a[], keys_compose_e[], keys_compose_y[], keys_compose_u[],
keys_compose_i[], keys_compose_o[], keys_compose_w[],
keys_compose_r[], keys_compose_t[], keys_compose_p[], keys_compose_s[],
@@ -97,6 +99,7 @@ static struct layout layouts[NumLayouts] = {
[Cyrillic] = {keys_cyrillic, "cyrillic", "cyrillic"},
[Arabic] = {keys_arabic, "arabic", "arabic"},
[Emoji] = {keys_emoji, "latin", "emoji"},
+ [Landscape] = {keys_landscape, "latin", "landscape"},
[ComposeA] = {keys_compose_a, "latin"},
[ComposeE] = {keys_compose_e, "latin"},
[ComposeY] = {keys_compose_y, "latin"},
@@ -710,6 +713,65 @@ static struct key keys_emoji[] = {
{"", "", 0.0, Last},
};
+static struct key keys_landscape[] = {
+ {"Esc", "Esc", 1.0, Code, KEY_ESC, .scheme = 1},
+ {"q", "Q", 1.0, Code, KEY_Q, &layouts[Emoji]},
+ {"w", "W", 1.0, Code, KEY_W, &layouts[ComposeW]},
+ {"e", "E", 1.0, Code, KEY_E, &layouts[ComposeE]},
+ {"r", "R", 1.0, Code, KEY_R, &layouts[ComposeR]},
+ {"t", "T", 1.0, Code, KEY_T, &layouts[ComposeT]},
+ {"y", "Y", 1.0, Code, KEY_Y, &layouts[ComposeY]},
+ {"u", "U", 1.0, Code, KEY_U, &layouts[ComposeU]},
+ {"i", "I", 1.0, Code, KEY_I, &layouts[ComposeI]},
+ {"o", "O", 1.0, Code, KEY_O, &layouts[ComposeO]},
+ {"p", "P", 1.0, Code, KEY_P, &layouts[ComposeP]},
+ {"(", "(", 0.75, Copy, KEY_9, &layouts[ComposeBracket], Shift, .scheme = 1},
+ {")", ")", 0.75, Code, KEY_0, &layouts[ComposeBracket], Shift, .scheme = 1},
+ {"Tab", "Tab", 0.75, Code, KEY_TAB, .scheme = 1},
+ {"", "", 0.0, EndRow},
+
+ {"Cmp", "Cmp", 1.5, Compose, .scheme = 1},
+ {"a", "A", 1.0, Code, KEY_A, &layouts[ComposeA]},
+ {"s", "S", 1.0, Code, KEY_S, &layouts[ComposeS]},
+ {"d", "D", 1.0, Code, KEY_D, &layouts[ComposeD]},
+ {"f", "F", 1.0, Code, KEY_F, &layouts[ComposeF]},
+ {"g", "G", 1.0, Code, KEY_G, &layouts[ComposeG]},
+ {"h", "H", 1.0, Code, KEY_H, &layouts[ComposeH]},
+ {"j", "J", 1.0, Code, KEY_J, &layouts[ComposeJ]},
+ {"k", "K", 1.0, Code, KEY_K, &layouts[ComposeK]},
+ {"l", "L", 1.0, Code, KEY_L, &layouts[ComposeL]},
+ {";", ":", 1.0, Code, KEY_SEMICOLON, .scheme = 1},
+ {"'", "\"", 1.0, Code, KEY_APOSTROPHE, &layouts[ComposeBracket], .scheme = 1},
+ {"-", "_", 0.5, Code, KEY_MINUS, &layouts[ComposeBracket], .scheme = 1},
+ {"", "", 0.0, EndRow},
+
+ {"⇧", "⇧", 1.5, Mod, Shift, .scheme = 1},
+ {"z", "Z", 1.0, Code, KEY_Z, &layouts[ComposeZ]},
+ {"x", "X", 1.0, Code, KEY_X, &layouts[ComposeX]},
+ {"c", "C", 1.0, Code, KEY_C, &layouts[ComposeC]},
+ {"v", "V", 1.0, Code, KEY_V, &layouts[ComposeV]},
+ {"b", "B", 1.0, Code, KEY_B, &layouts[ComposeB]},
+ {"n", "N", 1.0, Code, KEY_N, &layouts[ComposeN]},
+ {"m", "M", 1.0, Code, KEY_M, &layouts[ComposeM]},
+ {"↑", "↑", 0.75, Code, KEY_UP, .scheme = 1},
+ {"↓", "↓", 0.75, Code, KEY_DOWN, .scheme = 1},
+ {"/", "?", 0.75, Code, KEY_SLASH, .scheme = 1},
+ {"⌫", "⌫", 1.5, Code, KEY_BACKSPACE, .scheme = 1},
+ {"", "", 0.0, EndRow},
+
+ {"Sym", "Sym", 1.0, NextLayer, .scheme = 1},
+ {"Ctr", "Ctr", 1.0, Mod, Ctrl, .scheme = 1},
+ {"Alt", "Alt", 0.5, Mod, Alt, .scheme = 1},
+ {",", "'", 0.5, Code, KEY_COMMA, &layouts[ComposeMath]},
+ {"", "", 3.0, Code, KEY_SPACE},
+ {".", "?", 1.0, Code, KEY_DOT, &layouts[ComposeMath]},
+ {"Agr", "AGr", 1.0, Mod, AltGr, .scheme = 1},
+ {"Enter", "Enter", 2.0, Code, KEY_ENTER, .scheme = 1},
+
+ /* end of layout */
+ {"", "", 0.0, Last},
+};
+
static struct key keys_compose_w[] = {
{"ŵ", "Ŵ", 1.0, Copy, 0x0175, 0, 0x0174},
{"", "", 9.0, Pad},