Description
I am getting this error: error: 'lv_font_montserrat_20' was not declared in this scope
when trying to set a bigger font
What MCU/Processor/Board and compiler are you using?
nRF52 and ST7789
What LVGL version are you using?
8.3.5
What do you want to achieve?
Make text bigger in the label
What have you tried so far?
Tried the code below.
Code to reproduce
//Change the active screen's background color
//lv_obj_set_style_bg_color(lv_scr_act(), lv_color_hex(0x003a57), LV_PART_MAIN);
lv_obj_set_style_bg_color(lv_scr_act(), lv_color_black(), LV_PART_MAIN);
//Create a white label, set its text and align it to the center
lv_obj_t * label = lv_label_create(lv_scr_act());
lv_label_set_text(label, "Hello world");
lv_obj_set_style_text_color(lv_scr_act(), lv_color_white(), LV_PART_MAIN);
lv_obj_set_style_text_font(label,&lv_font_montserrat_20,0);
lv_obj_align(label, LV_ALIGN_CENTER, 0, 0);