lv_binfont_loader.h

API reference for lv_binfont_loader.h

Report on GitHub

Functions

lv_binfont_create

Loads a lv_font_t object from a binary font file

 
lv_font_t * lv_binfont_create(const char *path)
Parameters
NameTypeDescription
pathconst char *path to font file

Returns: lv_font_t * — pointer to font where to load

lv_binfont_create_from_buffer

Loads a lv_font_t object from a memory buffer containing the binary font file. Requires LV_USE_FS_MEMFS

 
lv_font_t * lv_binfont_create_from_buffer(void *buffer, uint32_t size)
Parameters
NameTypeDescription
buffervoid *address of the font file in the memory
sizeuint32_tsize of the font file buffer

Returns: lv_font_t * — pointer to font where to load

lv_binfont_destroy

Frees the memory allocated by the lv_binfont_create() function

 
void lv_binfont_destroy(lv_font_t *font)
Parameters
NameTypeDescription
fontlv_font_t *lv_font_t object created by the lv_binfont_create function

Structs

struct

lv_binfont_font_src_t

MemberTypeDescription
font_sizeuint32_tSize of the font in pixels
pathconst char *Path to font file
bufferconst void *Address of the font file in the memory
buffer_sizeuint32_tSize of the font file buffer

Variables

lv_binfont_font_class

 
const lv_font_class_t lv_binfont_font_class

Dependencies

Indirect dependencies

How is this guide?

Last updated on

On this page