This commit is contained in:
2026-02-24 18:20:07 +08:00
parent f5d8c90b12
commit f3cb27e168
551 changed files with 315143 additions and 6 deletions
@@ -41,11 +41,11 @@ void lv_example_get_started_1(void)
lv_style_init(&style_label);
//lv_style_set_text_font(&style_label, cn_font_16); // 关键:设置字体
lv_style_set_text_font(&style_label, cn_font_16); // 关键:设置字体
/*Create a white label, set its text and align it to the center*/
lv_obj_t *label = lv_label_create(lv_screen_active());
//lv_obj_add_style(label, &style_label, 0);
lv_obj_add_style(label, &style_label, 0);
lv_label_set_text(label, "Hello world 你好世界!");
lv_obj_set_style_text_color(lv_screen_active(), lv_color_hex(0xffffff), LV_PART_MAIN);
lv_obj_align(label, LV_ALIGN_CENTER, 0, 0);