Revert "dashboard: fix icon font descriptor for lvgl v8"
This reverts commit b0d52993e9.
This commit is contained in:
@@ -18,6 +18,8 @@
|
|||||||
#include "lvgl/lvgl.h"
|
#include "lvgl/lvgl.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#ifndef MD_ICONS
|
#ifndef MD_ICONS
|
||||||
#define MD_ICONS 1
|
#define MD_ICONS 1
|
||||||
#endif
|
#endif
|
||||||
@@ -288,6 +290,7 @@ static LV_ATTRIBUTE_LARGE_CONST const uint8_t glyph_bitmap[] = {
|
|||||||
0x7d, 0x20, 0x7, 0xff, 0x24
|
0x7d, 0x20, 0x7, 0xff, 0x24
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/*---------------------
|
/*---------------------
|
||||||
* GLYPH DESCRIPTION
|
* GLYPH DESCRIPTION
|
||||||
*--------------------*/
|
*--------------------*/
|
||||||
@@ -308,6 +311,8 @@ static const lv_font_fmt_txt_glyph_dsc_t glyph_dsc[] = {
|
|||||||
* CHARACTER MAPPING
|
* CHARACTER MAPPING
|
||||||
*--------------------*/
|
*--------------------*/
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*Collect the unicode lists and glyph_id offsets*/
|
/*Collect the unicode lists and glyph_id offsets*/
|
||||||
static const lv_font_fmt_txt_cmap_t cmaps[] =
|
static const lv_font_fmt_txt_cmap_t cmaps[] =
|
||||||
{
|
{
|
||||||
@@ -317,6 +322,8 @@ static const lv_font_fmt_txt_cmap_t cmaps[] =
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*--------------------
|
/*--------------------
|
||||||
* ALL CUSTOM DATA
|
* ALL CUSTOM DATA
|
||||||
*--------------------*/
|
*--------------------*/
|
||||||
@@ -346,6 +353,8 @@ static lv_font_fmt_txt_dsc_t font_dsc = {
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*-----------------
|
/*-----------------
|
||||||
* PUBLIC FONT
|
* PUBLIC FONT
|
||||||
*----------------*/
|
*----------------*/
|
||||||
@@ -356,17 +365,25 @@ const lv_font_t md_icons = {
|
|||||||
#else
|
#else
|
||||||
lv_font_t md_icons = {
|
lv_font_t md_icons = {
|
||||||
#endif
|
#endif
|
||||||
.get_glyph_dsc = lv_font_get_glyph_dsc_fmt_txt, /*Function pointer to get glyph's data*/ /*Function pointer to get glyph's bitmap*/
|
.get_glyph_dsc = lv_font_get_glyph_dsc_fmt_txt, /*Function pointer to get glyph's data*/
|
||||||
|
.get_glyph_bitmap = lv_font_get_bitmap_fmt_txt, /*Function pointer to get glyph's bitmap*/
|
||||||
.line_height = 41, /*The maximum line height required by the font*/
|
.line_height = 41, /*The maximum line height required by the font*/
|
||||||
.base_line = 3, /*Baseline measured from the bottom of the line*/
|
.base_line = 3, /*Baseline measured from the bottom of the line*/
|
||||||
#if !(LVGL_VERSION_MAJOR == 6 && LVGL_VERSION_MINOR == 0)
|
#if !(LVGL_VERSION_MAJOR == 6 && LVGL_VERSION_MINOR == 0)
|
||||||
|
.subpx = LV_FONT_SUBPX_NONE,
|
||||||
#endif
|
#endif
|
||||||
#if LV_VERSION_CHECK(7, 4, 0) || LVGL_VERSION_MAJOR >= 8
|
#if LV_VERSION_CHECK(7, 4, 0) || LVGL_VERSION_MAJOR >= 8
|
||||||
|
.underline_position = 0,
|
||||||
|
.underline_thickness = 0,
|
||||||
#endif
|
#endif
|
||||||
|
.static_bitmap = 0,
|
||||||
.dsc = &font_dsc, /*The custom font data. Will be accessed by `get_glyph_bitmap/dsc` */
|
.dsc = &font_dsc, /*The custom font data. Will be accessed by `get_glyph_bitmap/dsc` */
|
||||||
#if LV_VERSION_CHECK(8, 2, 0) || LVGL_VERSION_MAJOR >= 9
|
#if LV_VERSION_CHECK(8, 2, 0) || LVGL_VERSION_MAJOR >= 9
|
||||||
|
.fallback = NULL,
|
||||||
#endif
|
#endif
|
||||||
.user_data = NULL,
|
.user_data = NULL,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#endif /*#if MD_ICONS*/
|
#endif /*#if MD_ICONS*/
|
||||||
|
|||||||
Reference in New Issue
Block a user