diff --git a/examples/components/buttons/button_default.xml b/examples/components/buttons/button_default.xml
index 8289f88..96b683c 100644
--- a/examples/components/buttons/button_default.xml
+++ b/examples/components/buttons/button_default.xml
@@ -1,7 +1,7 @@
-
+
@@ -21,6 +21,6 @@
-
+
diff --git a/examples/components/buttons/button_error.xml b/examples/components/buttons/button_error.xml
index 1f302aa..fd79f02 100644
--- a/examples/components/buttons/button_error.xml
+++ b/examples/components/buttons/button_error.xml
@@ -1,7 +1,7 @@
-
+
@@ -22,6 +22,6 @@
-
+
diff --git a/examples/components/buttons/button_warning.xml b/examples/components/buttons/button_warning.xml
index 2243f15..1b4ea8b 100644
--- a/examples/components/buttons/button_warning.xml
+++ b/examples/components/buttons/button_warning.xml
@@ -1,7 +1,7 @@
-
+
@@ -11,6 +11,7 @@
border_width="0"
radius="12"
shadow_width="0"
+ text_color="0x111111"
/>
-
-
-
+
+
-
+
-
-
+
+
-
+
diff --git a/examples/widgets/slider_box/slider_box_gen.c b/examples/widgets/slider_box/slider_box_gen.c
index 6b8fcec..5c68d7d 100644
--- a/examples/widgets/slider_box/slider_box_gen.c
+++ b/examples/widgets/slider_box/slider_box_gen.c
@@ -68,6 +68,7 @@ lv_obj_t * slider_box_create(lv_obj_t * parent)
static void slider_box_constructor(const lv_obj_class_t * class_p, lv_obj_t * obj)
{
+ ui_init();
LV_UNUSED(class_p);
LV_TRACE_OBJ_CREATE("begin");
@@ -80,20 +81,24 @@ static void slider_box_constructor(const lv_obj_class_t * class_p, lv_obj_t * ob
lv_style_init(&style_main);
lv_style_set_bg_color(&style_main, lv_color_hex(0x666666));
lv_style_set_bg_opa(&style_main, 255);
- lv_style_set_border_width(&style_main, 2);
- lv_style_set_border_color(&style_main, lv_color_hex(0xaaaaaa));
- lv_style_set_radius(&style_main, 20);
+ lv_style_set_radius(&style_main, 12);
lv_style_set_width(&style_main, 180);
lv_style_set_height(&style_main, LV_SIZE_CONTENT);
lv_style_set_layout(&style_main, LV_LAYOUT_FLEX);
lv_style_set_flex_flow(&style_main, LV_FLEX_FLOW_ROW_WRAP);
lv_style_set_flex_cross_place(&style_main, LV_FLEX_ALIGN_CENTER);
lv_style_set_flex_track_place(&style_main, LV_FLEX_ALIGN_CENTER);
+ lv_style_set_pad_column(&style_main, 4);
lv_style_set_pad_row(&style_main, 10);
- lv_style_set_pad_all(&style_main, 10);
+ lv_style_set_pad_all(&style_main, 16);
+ lv_style_set_text_color(&style_main, lv_color_hex(0xffffff));
+ lv_style_set_text_font(&style_main, inter_sm);
lv_style_init(&style_button);
lv_style_set_radius(&style_button, 100);
+ lv_style_set_text_font(&style_button, inter_xl);
+ lv_style_set_bg_color(&style_button, lv_color_hex(0x222222));
+ lv_style_set_shadow_width(&style_button, 0);
style_main_inited = true;
}
@@ -108,6 +113,7 @@ static void slider_box_constructor(const lv_obj_class_t * class_p, lv_obj_t * ob
slider_box->lv_label2 = lv_label_create(slider_box->lv_button);
lv_label_set_text(slider_box->lv_label2, "-");
+ lv_obj_center(slider_box->lv_label2);
slider_box->lv_label = lv_label_create(obj);
lv_obj_set_align(slider_box->lv_label, LV_ALIGN_TOP_MID);
@@ -116,16 +122,23 @@ static void slider_box_constructor(const lv_obj_class_t * class_p, lv_obj_t * ob
lv_obj_set_flex_grow(slider_box->lv_label, 1);
lv_label_set_long_mode(slider_box->lv_label, LV_LABEL_LONG_MODE_SCROLL);
lv_obj_set_style_text_align(slider_box->lv_label, LV_TEXT_ALIGN_CENTER, 0);
+ lv_obj_set_style_text_color(slider_box->lv_label, lv_color_hex(0xffffff), 0);
+
slider_box->lv_button2 = lv_button_create(obj);
lv_obj_add_style(slider_box->lv_button2, &style_button, LV_PART_MAIN | LV_STATE_DEFAULT);
-
+ lv_obj_set_width(slider_box->lv_button2, 30);
+ lv_obj_set_height(slider_box->lv_button2, 30);
+
slider_box->lv_label3 = lv_label_create(slider_box->lv_button2);
lv_label_set_text(slider_box->lv_label3, "+");
+ lv_obj_center(slider_box->lv_label3);
slider_box->dark_slider = dark_slider_create(obj);
lv_obj_set_width(slider_box->dark_slider, lv_pct(100));
-
+ lv_obj_set_style_margin_hor(slider_box->dark_slider, 8, 0);
+ dark_slider_set_color(slider_box->dark_slider, lv_color_hex(0x44aaff));
+
slider_box_constructor_hook(obj);
LV_TRACE_OBJ_CREATE("finished");