Binary file not shown.
BIN
OpenSans-Regular.ttf
Normal file
BIN
OpenSans-Regular.ttf
Normal file
Binary file not shown.
16
README.md
16
README.md
@@ -106,16 +106,18 @@ With meson <0\.55 use `ninja` instead of `meson compile`\.
|
||||
|
||||
## Fonts
|
||||
|
||||
In order to work with [LVGL], fonts need to be converted to bitmaps, stored as C arrays. Unl0kr currently uses a combination of the [Montserrat] font for text and the [FontAwesome] font for pictograms. For both fonts only limited character ranges are included to reduce the binary size. To (re)generate the C file containing the combined font, run the following command
|
||||
In order to work with [LVGL], fonts need to be converted to bitmaps, stored as C arrays. Unl0kr currently uses a combination of the [OpenSans] font for text and the [FontAwesome] font for pictograms. For both fonts only limited character ranges are included to reduce the binary size. To (re)generate the C file containing the combined font, run the following command
|
||||
|
||||
```
|
||||
$ npx lv_font_conv --bpp 4 --size 32 --no-compress -o montserrat_extended_32.c --format lvgl \
|
||||
--font Montserrat-Regular.ttf \
|
||||
$ npx lv_font_conv --bpp 4 --size 32 --no-compress -o font_32.c --format lvgl \
|
||||
--font OpenSans-Regular.ttf \
|
||||
--range '0x0020-0x007F' \
|
||||
--range '0x00A0-0x00FF' \
|
||||
--range '0x0100-0x017F' \
|
||||
--range '0x0370-0x03FF' \
|
||||
--range '0x2000-0x206F' \
|
||||
--range '0x20A0-0x20CF' \
|
||||
--range '0x2200-0x22FF' \
|
||||
--font FontAwesome5-Solid+Brands+Regular.woff \
|
||||
--range '0xF001,0xF008,0xF00B,0xF00C,0xF00D,0xF011,0xF013,0xF015,0xF019,0xF01C,0xF021,0xF026,0xF027,0xF028,0xF03E,0xF0E0,0xF304,0xF043,0xF048,0xF04B,0xF04C,0xF04D,0xF051,0xF052,0xF053,0xF054,0xF067,0xF068,0xF06E,0xF070,0xF071,0xF074,0xF077,0xF078,0xF079,0xF07B,0xF093,0xF095,0xF0C4,0xF0C5,0xF0C7,0xF0C9,0xF0E7,0xF0EA,0xF0F3,0xF11C,0xF124,0xF158,0xF1EB,0xF240,0xF241,0xF242,0xF243,0xF244,0xF287,0xF293,0xF2ED,0xF55A,0xF7C2,0xF8A2' \
|
||||
--range '0xF042' \
|
||||
@@ -124,12 +126,14 @@ $ npx lv_font_conv --bpp 4 --size 32 --no-compress -o montserrat_extended_32.c -
|
||||
|
||||
Below is a short explanation of the different unicode ranges used above.
|
||||
|
||||
- [Montserrat]
|
||||
- [OpenSans]
|
||||
- Basic Latin (`0x0020-0x007F`)
|
||||
- Latin-1 supplement (`0x00A0-0x00FF`)
|
||||
- Latin extended A (`0x0100-0x017F`)
|
||||
- Greek and Coptic (`0x0370-0x03FF`)
|
||||
- General punctuation (`0x2000-0x206F`)
|
||||
- Currency symbols (`0x20A0-0x20CF`)
|
||||
- Mathematical operators (`0x2200-0x22FF`)
|
||||
- [FontAwesome]
|
||||
- Standard `LV_SYMBOL_*` glyphs (`0xF001,0xF008,0xF00B,0xF00C,0xF00D,0xF011,0xF013,0xF015,0xF019,0xF01C,0xF021,0xF026,0xF027,0xF028,0xF03E,0xF0E0,0xF304,0xF043,0xF048,0xF04B,0xF04C,0xF04D,0xF051,0xF052,0xF053,0xF054,0xF067,0xF068,0xF06E,0xF070,0xF071,0xF074,0xF077,0xF078,0xF079,0xF07B,0xF093,0xF095,0xF0C4,0xF0C5,0xF0C7,0xF0C9,0xF0E7,0xF0EA,0xF0F3,0xF11C,0xF124,0xF158,0xF1EB,0xF240,0xF241,0xF242,0xF243,0xF244,0xF287,0xF293,0xF2ED,0xF55A,0xF7C2,0xF8A2`)
|
||||
- [adjust] (`0xF042`)
|
||||
@@ -163,7 +167,7 @@ The mouse cursor image was taken from [lv_sim_emscripten].
|
||||
|
||||
Unl0kr is licensed under the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
|
||||
|
||||
The [Montserrat] font is licensed under the Open Font License.
|
||||
The [OpenSans] font is licensed under the Apache License 2.0.
|
||||
|
||||
The [FontAwesome] font is licensed under the Open Font License version 1.1.
|
||||
|
||||
@@ -174,7 +178,7 @@ The [FontAwesome] font is licensed under the Open Font License version 1.1.
|
||||
[FontAwesome]: https://fontawesome.com
|
||||
[LVGL]: https://lvgl.io
|
||||
[Make it possible to use multiple devices with the libinput and XKB drivers]: https://github.com/lvgl/lv_drivers/pull/165
|
||||
[Montserrat]: https://fonts.google.com/specimen/Montserrat
|
||||
[OpenSans]: https://fonts.google.com/specimen/Open+Sans
|
||||
[Use LV_LOG instead of printf in fbdev driver]: https://github.com/lvgl/lv_drivers/pull/167
|
||||
[adjust]: https://fontawesome.com/v5.15/icons/adjust?style=solid
|
||||
[arrow-alt-circle-up]: https://fontawesome.com/v5.15/icons/arrow-alt-circle-up?style=solid
|
||||
|
Submodule lv_drivers updated: e0ec5d5194...97e500b200
2
lvgl
2
lvgl
Submodule lvgl updated: e7ba9b93af...bd19083aed
@@ -30,10 +30,10 @@ unl0kr_sources = [
|
||||
'command_line.c',
|
||||
'config.c',
|
||||
'cursor.c',
|
||||
'font_32.c',
|
||||
'indev.c',
|
||||
'log.c',
|
||||
'main.c',
|
||||
'montserrat_extended_32.c',
|
||||
'sq2lv_layouts.c',
|
||||
'theme.c',
|
||||
'themes.c'
|
||||
|
14549
montserrat_extended_32.c
14549
montserrat_extended_32.c
File diff suppressed because it is too large
Load Diff
236
sq2lv_layouts.c
236
sq2lv_layouts.c
@@ -79,19 +79,19 @@ static const int switcher_dests_upper_us[] = { \
|
||||
|
||||
/* Layer: Numbers / symbols - generated from numbers */
|
||||
|
||||
static const int num_keys_numbers_us = 34;
|
||||
static const int num_keys_numbers_us = 35;
|
||||
|
||||
static const char * const keycaps_numbers_us[] = { \
|
||||
"1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "\n", \
|
||||
"@", "#", "$", "%", "&", "-", "_", "+", "(", ")", "\n", \
|
||||
",", "\"", "'", ":", ";", "!", "?", LV_SYMBOL_BACKSPACE, "\n", \
|
||||
"*/=", ",", "\"", "'", ":", ";", "!", "?", LV_SYMBOL_BACKSPACE, "\n", \
|
||||
"ABC", LV_SYMBOL_LEFT, " ", LV_SYMBOL_RIGHT, ".", LV_SYMBOL_OK, "" \
|
||||
};
|
||||
|
||||
static const lv_btnmatrix_ctrl_t attributes_numbers_us[] = { \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3, \
|
||||
SQ2LV_CTRL_NON_CHAR | 3, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3, \
|
||||
SQ2LV_CTRL_NON_CHAR | 3, SQ2LV_CTRL_NON_CHAR | 2, 7, SQ2LV_CTRL_NON_CHAR | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3 \
|
||||
};
|
||||
|
||||
@@ -99,19 +99,51 @@ static const int num_modifiers_numbers_us = 0;
|
||||
|
||||
static const int * const modifier_idxs_numbers_us = NULL;
|
||||
|
||||
static const int num_switchers_numbers_us = 1;
|
||||
static const int num_switchers_numbers_us = 2;
|
||||
|
||||
static const int switcher_idxs_numbers_us[] = { \
|
||||
28 \
|
||||
20, 29 \
|
||||
};
|
||||
|
||||
static const int switcher_dests_numbers_us[] = { \
|
||||
0 \
|
||||
3, 0 \
|
||||
};
|
||||
|
||||
/* Layer: Symbols - generated from symbols */
|
||||
|
||||
static const int num_keys_symbols_us = 35;
|
||||
|
||||
static const char * const keycaps_symbols_us[] = { \
|
||||
"~", "`", "|", "·", "√", "π", "τ", "÷", "×", "¶", "\n", \
|
||||
"©", "®", "£", "€", "¥", "^", "°", "*", "{", "}", "\n", \
|
||||
"123", "\\", "/", "<", ">", "=", "[", "]", LV_SYMBOL_BACKSPACE, "\n", \
|
||||
"ABC", LV_SYMBOL_LEFT, " ", LV_SYMBOL_RIGHT, ".", LV_SYMBOL_OK, "" \
|
||||
};
|
||||
|
||||
static const lv_btnmatrix_ctrl_t attributes_symbols_us[] = { \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, \
|
||||
SQ2LV_CTRL_NON_CHAR | 3, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3, \
|
||||
SQ2LV_CTRL_NON_CHAR | 3, SQ2LV_CTRL_NON_CHAR | 2, 7, SQ2LV_CTRL_NON_CHAR | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3 \
|
||||
};
|
||||
|
||||
static const int num_modifiers_symbols_us = 0;
|
||||
|
||||
static const int * const modifier_idxs_symbols_us = NULL;
|
||||
|
||||
static const int num_switchers_symbols_us = 2;
|
||||
|
||||
static const int switcher_idxs_symbols_us[] = { \
|
||||
20, 29 \
|
||||
};
|
||||
|
||||
static const int switcher_dests_symbols_us[] = { \
|
||||
2, 0 \
|
||||
};
|
||||
|
||||
/* Layer array */
|
||||
|
||||
static const int num_layers_us = 3;
|
||||
static const int num_layers_us = 4;
|
||||
|
||||
static const sq2lv_layer_t layers_us[] = {
|
||||
{
|
||||
@@ -143,6 +175,16 @@ static const sq2lv_layer_t layers_us[] = {
|
||||
.num_switchers = num_switchers_numbers_us,
|
||||
.switcher_idxs = switcher_idxs_numbers_us,
|
||||
.switcher_dests = switcher_dests_numbers_us
|
||||
},
|
||||
{
|
||||
.num_keys = num_keys_symbols_us,
|
||||
.keycaps = keycaps_symbols_us,
|
||||
.attributes = attributes_symbols_us,
|
||||
.num_modifiers = num_modifiers_symbols_us,
|
||||
.modifier_idxs = modifier_idxs_symbols_us,
|
||||
.num_switchers = num_switchers_symbols_us,
|
||||
.switcher_idxs = switcher_idxs_symbols_us,
|
||||
.switcher_dests = switcher_dests_symbols_us
|
||||
}
|
||||
};
|
||||
|
||||
@@ -182,7 +224,7 @@ static const int switcher_idxs_lower_de[] = { \
|
||||
};
|
||||
|
||||
static const int switcher_dests_lower_de[] = { \
|
||||
1, 2, 3 \
|
||||
1, 2, 4 \
|
||||
};
|
||||
|
||||
/* Layer: Uppercase letters - generated from upper */
|
||||
@@ -214,24 +256,24 @@ static const int switcher_idxs_upper_de[] = { \
|
||||
};
|
||||
|
||||
static const int switcher_dests_upper_de[] = { \
|
||||
0, 2, 3 \
|
||||
0, 2, 4 \
|
||||
};
|
||||
|
||||
/* Layer: Numbers / symbols - generated from numbers */
|
||||
|
||||
static const int num_keys_numbers_de = 36;
|
||||
static const int num_keys_numbers_de = 37;
|
||||
|
||||
static const char * const keycaps_numbers_de[] = { \
|
||||
"1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "\n", \
|
||||
"@", "#", "€", "%", "&", "-", "_", "+", "(", ")", "\n", \
|
||||
";", "\"", "'", ":", "=", "<", ">", LV_SYMBOL_BACKSPACE, "\n", \
|
||||
"*/=", ";", "\"", "'", ":", "=", "<", ">", LV_SYMBOL_BACKSPACE, "\n", \
|
||||
"abc", "äÄ", LV_SYMBOL_LEFT, " ", LV_SYMBOL_RIGHT, ",", ".", LV_SYMBOL_OK, "" \
|
||||
};
|
||||
|
||||
static const lv_btnmatrix_ctrl_t attributes_numbers_de[] = { \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3, \
|
||||
SQ2LV_CTRL_NON_CHAR | 3, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3, \
|
||||
SQ2LV_CTRL_NON_CHAR | 3, SQ2LV_CTRL_MOD_INACTIVE | 3, SQ2LV_CTRL_NON_CHAR | 2, 7, SQ2LV_CTRL_NON_CHAR | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3 \
|
||||
};
|
||||
|
||||
@@ -239,14 +281,46 @@ static const int num_modifiers_numbers_de = 0;
|
||||
|
||||
static const int * const modifier_idxs_numbers_de = NULL;
|
||||
|
||||
static const int num_switchers_numbers_de = 2;
|
||||
static const int num_switchers_numbers_de = 3;
|
||||
|
||||
static const int switcher_idxs_numbers_de[] = { \
|
||||
28, 29 \
|
||||
20, 29, 30 \
|
||||
};
|
||||
|
||||
static const int switcher_dests_numbers_de[] = { \
|
||||
0, 3 \
|
||||
3, 0, 4 \
|
||||
};
|
||||
|
||||
/* Layer: Symbols - generated from symbols */
|
||||
|
||||
static const int num_keys_symbols_de = 37;
|
||||
|
||||
static const char * const keycaps_symbols_de[] = { \
|
||||
"~", "`", "´", "|", "·", "√", "µ", "÷", "×", "¶", "\n", \
|
||||
"©", "®", "£", "$", "¥", "^", "°", "*", "{", "}", "\n", \
|
||||
"123", "\\", "/", "§", "π", "τ", "[", "]", LV_SYMBOL_BACKSPACE, "\n", \
|
||||
"abc", "äÄ", LV_SYMBOL_LEFT, " ", LV_SYMBOL_RIGHT, ",", ".", LV_SYMBOL_OK, "" \
|
||||
};
|
||||
|
||||
static const lv_btnmatrix_ctrl_t attributes_symbols_de[] = { \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, \
|
||||
SQ2LV_CTRL_NON_CHAR | 3, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3, \
|
||||
SQ2LV_CTRL_NON_CHAR | 3, SQ2LV_CTRL_MOD_INACTIVE | 3, SQ2LV_CTRL_NON_CHAR | 2, 7, SQ2LV_CTRL_NON_CHAR | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3 \
|
||||
};
|
||||
|
||||
static const int num_modifiers_symbols_de = 0;
|
||||
|
||||
static const int * const modifier_idxs_symbols_de = NULL;
|
||||
|
||||
static const int num_switchers_symbols_de = 3;
|
||||
|
||||
static const int switcher_idxs_symbols_de[] = { \
|
||||
20, 29, 30 \
|
||||
};
|
||||
|
||||
static const int switcher_dests_symbols_de[] = { \
|
||||
2, 0, 4 \
|
||||
};
|
||||
|
||||
/* Layer: Special characters - generated from eschars */
|
||||
@@ -283,7 +357,7 @@ static const int switcher_dests_special_de[] = { \
|
||||
|
||||
/* Layer array */
|
||||
|
||||
static const int num_layers_de = 4;
|
||||
static const int num_layers_de = 5;
|
||||
|
||||
static const sq2lv_layer_t layers_de[] = {
|
||||
{
|
||||
@@ -316,6 +390,16 @@ static const sq2lv_layer_t layers_de[] = {
|
||||
.switcher_idxs = switcher_idxs_numbers_de,
|
||||
.switcher_dests = switcher_dests_numbers_de
|
||||
},
|
||||
{
|
||||
.num_keys = num_keys_symbols_de,
|
||||
.keycaps = keycaps_symbols_de,
|
||||
.attributes = attributes_symbols_de,
|
||||
.num_modifiers = num_modifiers_symbols_de,
|
||||
.modifier_idxs = modifier_idxs_symbols_de,
|
||||
.num_switchers = num_switchers_symbols_de,
|
||||
.switcher_idxs = switcher_idxs_symbols_de,
|
||||
.switcher_dests = switcher_dests_symbols_de
|
||||
},
|
||||
{
|
||||
.num_keys = num_keys_special_de,
|
||||
.keycaps = keycaps_special_de,
|
||||
@@ -364,7 +448,7 @@ static const int switcher_idxs_lower_es[] = { \
|
||||
};
|
||||
|
||||
static const int switcher_dests_lower_es[] = { \
|
||||
1, 2, 3 \
|
||||
1, 2, 4 \
|
||||
};
|
||||
|
||||
/* Layer: Uppercase letters - generated from upper */
|
||||
@@ -396,24 +480,24 @@ static const int switcher_idxs_upper_es[] = { \
|
||||
};
|
||||
|
||||
static const int switcher_dests_upper_es[] = { \
|
||||
0, 2, 3 \
|
||||
0, 2, 4 \
|
||||
};
|
||||
|
||||
/* Layer: Numbers / symbols - generated from numbers */
|
||||
|
||||
static const int num_keys_numbers_es = 36;
|
||||
static const int num_keys_numbers_es = 37;
|
||||
|
||||
static const char * const keycaps_numbers_es[] = { \
|
||||
"1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "\n", \
|
||||
"@", "#", "€", "%", "&", "-", "_", "+", "(", ")", "\n", \
|
||||
",", "\"", "'", ":", ";", "!", "=", LV_SYMBOL_BACKSPACE, "\n", \
|
||||
"*/=", ",", "\"", "'", ":", ";", "!", "=", LV_SYMBOL_BACKSPACE, "\n", \
|
||||
"abc", "áÁ", LV_SYMBOL_LEFT, " ", LV_SYMBOL_RIGHT, "?", ".", LV_SYMBOL_OK, "" \
|
||||
};
|
||||
|
||||
static const lv_btnmatrix_ctrl_t attributes_numbers_es[] = { \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3, \
|
||||
SQ2LV_CTRL_NON_CHAR | 3, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3, \
|
||||
SQ2LV_CTRL_NON_CHAR | 3, SQ2LV_CTRL_MOD_INACTIVE | 3, SQ2LV_CTRL_NON_CHAR | 2, 7, SQ2LV_CTRL_NON_CHAR | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3 \
|
||||
};
|
||||
|
||||
@@ -421,14 +505,46 @@ static const int num_modifiers_numbers_es = 0;
|
||||
|
||||
static const int * const modifier_idxs_numbers_es = NULL;
|
||||
|
||||
static const int num_switchers_numbers_es = 2;
|
||||
static const int num_switchers_numbers_es = 3;
|
||||
|
||||
static const int switcher_idxs_numbers_es[] = { \
|
||||
28, 29 \
|
||||
20, 29, 30 \
|
||||
};
|
||||
|
||||
static const int switcher_dests_numbers_es[] = { \
|
||||
0, 3 \
|
||||
3, 0, 4 \
|
||||
};
|
||||
|
||||
/* Layer: Symbols - generated from symbols */
|
||||
|
||||
static const int num_keys_symbols_es = 37;
|
||||
|
||||
static const char * const keycaps_symbols_es[] = { \
|
||||
"~", "`", "|", "·", "√", "π", "τ", "÷", "×", "¶", "\n", \
|
||||
"©", "®", "£", "$", "¥", "^", "°", "*", "{", "}", "\n", \
|
||||
"123", "\\", "/", "<", ">", "=", "[", "]", LV_SYMBOL_BACKSPACE, "\n", \
|
||||
"abc", "áÁ", LV_SYMBOL_LEFT, " ", LV_SYMBOL_RIGHT, "?", ".", LV_SYMBOL_OK, "" \
|
||||
};
|
||||
|
||||
static const lv_btnmatrix_ctrl_t attributes_symbols_es[] = { \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, \
|
||||
SQ2LV_CTRL_NON_CHAR | 3, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3, \
|
||||
SQ2LV_CTRL_NON_CHAR | 3, SQ2LV_CTRL_MOD_INACTIVE | 3, SQ2LV_CTRL_NON_CHAR | 2, 7, SQ2LV_CTRL_NON_CHAR | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3 \
|
||||
};
|
||||
|
||||
static const int num_modifiers_symbols_es = 0;
|
||||
|
||||
static const int * const modifier_idxs_symbols_es = NULL;
|
||||
|
||||
static const int num_switchers_symbols_es = 3;
|
||||
|
||||
static const int switcher_idxs_symbols_es[] = { \
|
||||
20, 29, 30 \
|
||||
};
|
||||
|
||||
static const int switcher_dests_symbols_es[] = { \
|
||||
2, 0, 4 \
|
||||
};
|
||||
|
||||
/* Layer: Special characters - generated from eschars */
|
||||
@@ -465,7 +581,7 @@ static const int switcher_dests_special_es[] = { \
|
||||
|
||||
/* Layer array */
|
||||
|
||||
static const int num_layers_es = 4;
|
||||
static const int num_layers_es = 5;
|
||||
|
||||
static const sq2lv_layer_t layers_es[] = {
|
||||
{
|
||||
@@ -498,6 +614,16 @@ static const sq2lv_layer_t layers_es[] = {
|
||||
.switcher_idxs = switcher_idxs_numbers_es,
|
||||
.switcher_dests = switcher_dests_numbers_es
|
||||
},
|
||||
{
|
||||
.num_keys = num_keys_symbols_es,
|
||||
.keycaps = keycaps_symbols_es,
|
||||
.attributes = attributes_symbols_es,
|
||||
.num_modifiers = num_modifiers_symbols_es,
|
||||
.modifier_idxs = modifier_idxs_symbols_es,
|
||||
.num_switchers = num_switchers_symbols_es,
|
||||
.switcher_idxs = switcher_idxs_symbols_es,
|
||||
.switcher_dests = switcher_dests_symbols_es
|
||||
},
|
||||
{
|
||||
.num_keys = num_keys_special_es,
|
||||
.keycaps = keycaps_special_es,
|
||||
@@ -546,7 +672,7 @@ static const int switcher_idxs_lower_fr[] = { \
|
||||
};
|
||||
|
||||
static const int switcher_dests_lower_fr[] = { \
|
||||
1, 2, 3 \
|
||||
1, 2, 4 \
|
||||
};
|
||||
|
||||
/* Layer: Uppercase letters - generated from upper */
|
||||
@@ -578,24 +704,24 @@ static const int switcher_idxs_upper_fr[] = { \
|
||||
};
|
||||
|
||||
static const int switcher_dests_upper_fr[] = { \
|
||||
0, 2, 3 \
|
||||
0, 2, 4 \
|
||||
};
|
||||
|
||||
/* Layer: Numbers / symbols - generated from numbers */
|
||||
|
||||
static const int num_keys_numbers_fr = 34;
|
||||
static const int num_keys_numbers_fr = 35;
|
||||
|
||||
static const char * const keycaps_numbers_fr[] = { \
|
||||
"1", "2", "3", "4", "5", "6", "7", "8", "9", "0", "\n", \
|
||||
"@", "#", "€", "%", "&", "-", "_", "+", "(", ")", "\n", \
|
||||
",", "\"", "'", ":", ";", "!", "?", LV_SYMBOL_BACKSPACE, "\n", \
|
||||
"*/=", ",", "\"", "'", ":", ";", "!", "?", LV_SYMBOL_BACKSPACE, "\n", \
|
||||
"abc", LV_SYMBOL_LEFT, " ", LV_SYMBOL_RIGHT, "âÂ", LV_SYMBOL_OK, "" \
|
||||
};
|
||||
|
||||
static const lv_btnmatrix_ctrl_t attributes_numbers_fr[] = { \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3, \
|
||||
SQ2LV_CTRL_NON_CHAR | 3, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3, \
|
||||
SQ2LV_CTRL_NON_CHAR | 3, SQ2LV_CTRL_NON_CHAR | 2, 7, SQ2LV_CTRL_NON_CHAR | 2, SQ2LV_CTRL_MOD_INACTIVE | 3, SQ2LV_CTRL_NON_CHAR | 3 \
|
||||
};
|
||||
|
||||
@@ -603,14 +729,46 @@ static const int num_modifiers_numbers_fr = 0;
|
||||
|
||||
static const int * const modifier_idxs_numbers_fr = NULL;
|
||||
|
||||
static const int num_switchers_numbers_fr = 2;
|
||||
static const int num_switchers_numbers_fr = 3;
|
||||
|
||||
static const int switcher_idxs_numbers_fr[] = { \
|
||||
28, 32 \
|
||||
20, 29, 33 \
|
||||
};
|
||||
|
||||
static const int switcher_dests_numbers_fr[] = { \
|
||||
0, 3 \
|
||||
3, 0, 4 \
|
||||
};
|
||||
|
||||
/* Layer: Symbols - generated from symbols */
|
||||
|
||||
static const int num_keys_symbols_fr = 35;
|
||||
|
||||
static const char * const keycaps_symbols_fr[] = { \
|
||||
"~", "`", "|", "·", "√", "π", "τ", "÷", "×", "¶", "\n", \
|
||||
"©", "®", "£", "$", "¥", "^", "°", "*", "{", "}", "\n", \
|
||||
"123", "\\", "/", "<", ">", "=", "[", "]", LV_SYMBOL_BACKSPACE, "\n", \
|
||||
"abc", LV_SYMBOL_LEFT, " ", LV_SYMBOL_RIGHT, "âÂ", LV_SYMBOL_OK, "" \
|
||||
};
|
||||
|
||||
static const lv_btnmatrix_ctrl_t attributes_symbols_fr[] = { \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, \
|
||||
LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, \
|
||||
SQ2LV_CTRL_NON_CHAR | 3, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, LV_BTNMATRIX_CTRL_POPOVER | 2, SQ2LV_CTRL_NON_CHAR | 3, \
|
||||
SQ2LV_CTRL_NON_CHAR | 3, SQ2LV_CTRL_NON_CHAR | 2, 7, SQ2LV_CTRL_NON_CHAR | 2, SQ2LV_CTRL_MOD_INACTIVE | 3, SQ2LV_CTRL_NON_CHAR | 3 \
|
||||
};
|
||||
|
||||
static const int num_modifiers_symbols_fr = 0;
|
||||
|
||||
static const int * const modifier_idxs_symbols_fr = NULL;
|
||||
|
||||
static const int num_switchers_symbols_fr = 3;
|
||||
|
||||
static const int switcher_idxs_symbols_fr[] = { \
|
||||
20, 29, 33 \
|
||||
};
|
||||
|
||||
static const int switcher_dests_symbols_fr[] = { \
|
||||
2, 0, 4 \
|
||||
};
|
||||
|
||||
/* Layer: Special characters - generated from eschars */
|
||||
@@ -647,7 +805,7 @@ static const int switcher_dests_special_fr[] = { \
|
||||
|
||||
/* Layer array */
|
||||
|
||||
static const int num_layers_fr = 4;
|
||||
static const int num_layers_fr = 5;
|
||||
|
||||
static const sq2lv_layer_t layers_fr[] = {
|
||||
{
|
||||
@@ -680,6 +838,16 @@ static const sq2lv_layer_t layers_fr[] = {
|
||||
.switcher_idxs = switcher_idxs_numbers_fr,
|
||||
.switcher_dests = switcher_dests_numbers_fr
|
||||
},
|
||||
{
|
||||
.num_keys = num_keys_symbols_fr,
|
||||
.keycaps = keycaps_symbols_fr,
|
||||
.attributes = attributes_symbols_fr,
|
||||
.num_modifiers = num_modifiers_symbols_fr,
|
||||
.modifier_idxs = modifier_idxs_symbols_fr,
|
||||
.num_switchers = num_switchers_symbols_fr,
|
||||
.switcher_idxs = switcher_idxs_symbols_fr,
|
||||
.switcher_dests = switcher_dests_symbols_fr
|
||||
},
|
||||
{
|
||||
.num_keys = num_keys_special_fr,
|
||||
.keycaps = keycaps_special_fr,
|
||||
|
Submodule squeek2lvgl updated: 90eebad7e1...db4222c091
8
theme.c
8
theme.c
@@ -97,7 +97,7 @@ static void keyboard_draw_part_begin_cb(lv_event_t *event);
|
||||
|
||||
static void init_styles(ul_theme *theme) {
|
||||
reset_style(&(styles.widget));
|
||||
lv_style_set_text_font(&(styles.widget), &montserrat_extended_32);
|
||||
lv_style_set_text_font(&(styles.widget), &font_32);
|
||||
|
||||
reset_style(&(styles.window));
|
||||
lv_style_set_bg_opa(&(styles.window), LV_OPA_COVER);
|
||||
@@ -327,9 +327,9 @@ void ul_theme_apply(ul_theme *theme) {
|
||||
}
|
||||
|
||||
lv_theme.disp = NULL;
|
||||
lv_theme.font_small = &montserrat_extended_32;
|
||||
lv_theme.font_normal = &montserrat_extended_32;
|
||||
lv_theme.font_large = &montserrat_extended_32;
|
||||
lv_theme.font_small = &font_32;
|
||||
lv_theme.font_normal = &font_32;
|
||||
lv_theme.font_large = &font_32;
|
||||
lv_theme.apply_cb = apply_theme_cb;
|
||||
|
||||
current_theme = *theme;
|
||||
|
Reference in New Issue
Block a user