wvkbd/config.def.h
Frank Oltmanns d6439afcb9 Make font selection scheme specific
Add the members font and font_descriptor to struct clr_scheme, so that
it is possible to specify a font for each scheme.

During initialization create the font descriptors for each scheme.

Instead of initially setting the font descriptor when setting up the
buffer, set the font descriptor when drawing the text.

Signed-off-by: Frank Oltmanns <frank@oltmanns.dev>
Signed-off-by: Maarten van Gompel <proycon@anaproy.nl>
2023-10-29 13:07:57 +01:00

43 lines
1.2 KiB
C

#ifndef config_def_h_INCLUDED
#define config_def_h_INCLUDED
#define DEFAULT_FONT "Sans 14"
static const int transparency = 255;
struct clr_scheme schemes[] = {
{
/* colors */
.bg = {.bgra = {15, 15, 15, transparency}},
.fg = {.bgra = {45, 45, 45, transparency}},
.high = {.bgra = {100, 100, 100, transparency}},
.swipe = {.bgra = {100, 255, 100, 64}},
.text = {.color = UINT32_MAX},
.font = DEFAULT_FONT,
},
{
/* colors */
.bg = {.bgra = {15, 15, 15, transparency}},
.fg = {.bgra = {32, 32, 32, transparency}},
.high = {.bgra = {100, 100, 100, transparency}},
.swipe = {.bgra = {100, 255, 100, 64}},
.text = {.color = UINT32_MAX},
.font = DEFAULT_FONT,
}
};
/* layers is an ordered list of layouts, used to cycle through */
static enum layout_id layers[] = {
Full, // First layout is the default layout on startup
Special,
NumLayouts // signals the last item, may not be omitted
};
/* layers is an ordered list of layouts, used to cycle through */
static enum layout_id landscape_layers[] = {
Landscape, // First layout is the default layout on startup
LandscapeSpecial,
NumLayouts // signals the last item, may not be omitted
};
#endif // config_def_h_INCLUDED