From 77d193cdd127714ce4eab73d7a11a155655b7678 Mon Sep 17 00:00:00 2001 From: iamcheeseman Date: Fri, 22 May 2026 19:19:14 -0400 Subject: fix elements getting clipped with size <0 --- dc/dc.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'dc/dc.c') diff --git a/dc/dc.c b/dc/dc.c index 679d43a..aed4a7c 100644 --- a/dc/dc.c +++ b/dc/dc.c @@ -98,11 +98,13 @@ void tick(void) tyui_slider_ex(0, 100, &value, true, TYUI_ALIGN_RIGHT); tyui_blank_slider(0, 100, &value); - tyui_push_layout((float[]){-50, -1, 0}); - tyui_button("abc"); - tyui_button("xyz"); - tyui_button("abc"); - tyui_button("xyz"); + tyui_push_layout((float[]){50, -1, 0}); + tyui_slider(0, 100, &value); + if (tyui_button("inc")) + value++; + tyui_slider(0, 100, &value); + if (tyui_button("dec")) + value--; tyui_pop_layout(); tyui_end_window(); -- cgit v1.3-2-g0d8e