feat(xml): add spinbox support (#8957)

Co-authored-by: Liam Howatt <30486941+liamHowatt@users.noreply.github.com>
This commit is contained in:
Gabor Kiss-Vamosi
2025-09-30 20:26:55 +02:00
committed by GitHub
parent 89d7d11a13
commit 1623876507
11 changed files with 336 additions and 10 deletions
Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

@@ -0,0 +1,35 @@
#if LV_BUILD_TEST
#include "../lvgl.h"
#include "unity/unity.h"
void setUp(void)
{
/* Function run before every test */
}
void tearDown(void)
{
/* Function run after every test */
lv_obj_clean(lv_screen_active());
}
void test_spinbox_with_attrs(void)
{
lv_obj_t * scr = lv_screen_active();
const char * attrs_1[] = {
"min_value", "0",
"max_value", "3000",
"digit_count", "5",
"dec_point_pos", "3",
"value", "1234",
"align", "center",
NULL, NULL,
};
lv_xml_create(scr, "lv_spinbox", attrs_1);
TEST_ASSERT_EQUAL_SCREENSHOT("xml/lv_spinbox.png");
}
#endif