forked from raspberrypi/pico-playground
-
Notifications
You must be signed in to change notification settings - Fork 0
/
font.h
43 lines (36 loc) · 1.02 KB
/
font.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/*
* Copyright (c) 2020 Raspberry Pi (Trading) Ltd.
*
* SPDX-License-Identifier: BSD-3-Clause
*/
#ifndef _FONT_H
#define _FONT_H
#include "pico/types.h"
typedef struct {
uint16_t bitmap_index;
uint16_t adv_w;
int8_t box_w, box_h, ofs_x, ofs_y;
} __attribute__((packed)) lv_font_fmt_txt_glyph_dsc_t;
typedef struct {
uint16_t range_start, range_length, glyph_id_start, list_length;
void *unicode_list, *glyph_id_ofs_list;
enum {
LV_FONT_FMT_TXT_CMAP_FORMAT0_TINY
} type;
} lv_font_fmt_txt_cmap_t;
typedef struct {
const uint8_t *glyph_bitmap;
const lv_font_fmt_txt_glyph_dsc_t *glyph_dsc;
const lv_font_fmt_txt_cmap_t *cmaps;
uint8_t cmap_num, bpp, kern_scale, kern_classes;
void *kern_dsc;
} lv_font_fmt_txt_dsc_t;
typedef struct {
lv_font_fmt_txt_dsc_t *dsc;
uint8_t line_height, base_line;
} lv_font_t;
extern const lv_font_t ubuntu_mono6;
extern const lv_font_t ubuntu_mono8;
extern const lv_font_t ubuntu_mono10;
extern const lv_font_t lcd;
#endif //SOFTWARE_FONT_H