CuVoodoo STM32F1 firmware template
font.h
Go to the documentation of this file.
1 /* This program is free software: you can redistribute it and/or modify
2  * it under the terms of the GNU General Public License as published by
3  * the Free Software Foundation, either version 3 of the License, or
4  * (at your option) any later version.
5  *
6  * This program is distributed in the hope that it will be useful,
7  * but WITHOUT ANY WARRANTY; without even the implied warranty of
8  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
9  * GNU General Public License for more details.
10  *
11  * You should have received a copy of the GNU General Public License
12  * along with this program. If not, see <http://www.gnu.org/licenses/>.
13  *
14  */
20 #pragma once
21 
23 enum font_name {
28 };
29 
31 struct font_s {
32  uint8_t width;
33  uint8_t height;
34  const uint16_t *glyphs;
35 };
36 
38 #define FONT_GLYPH_NUMBERS 95
39 
41 extern const struct font_s fonts[FONT_MAX];
const uint16_t * glyphs
font glyphs: width glyph columns (left to right) times FONT_GLYPH_NUMBERS (MSb is glyph top pixel) ...
Definition: font.h:34
font_name
list of available font names
Definition: font.h:23
number of fonts available
Definition: font.h:27
custom 8x5 monospace font
Definition: font.h:24
font structure containing all properties
Definition: font.h:31
const struct font_s fonts[FONT_MAX]
list of all available fonts
Definition: font.c:321
uint8_t height
font height in pixels (max 16)
Definition: font.h:33
uint8_t width
font width in pixels
Definition: font.h:32
custom 14x9 monospace font
Definition: font.h:26
custom 10x6 monospace font
Definition: font.h:25