diff options
| author | iamcheeseman <[email protected]> | 2026-05-22 19:09:14 -0400 |
|---|---|---|
| committer | iamcheeseman <[email protected]> | 2026-05-22 19:09:14 -0400 |
| commit | 2d5c6f38f73453e4b1185017ff01b02f095a5db0 (patch) | |
| tree | 4e832ff92070b1c81d40acf32e9848833b279c41 /dc/dc.c | |
| parent | b4d44545a641c2c27e63aa10d651dcec985971c1 (diff) | |
fix negative column widths
Diffstat (limited to 'dc/dc.c')
| -rw-r--r-- | dc/dc.c | 12 |
1 files changed, 10 insertions, 2 deletions
@@ -69,7 +69,7 @@ void tick(void) if (tyui_begin_window("Test Window", ty_recti(5, 5, 100, 120), &winid1)) { tyui_button("before"); - tyui_push_layout((float[]){0.5, -1, 0}); + tyui_push_layout((float[]){-50, -1, 0}); tyui_push_layout((float[]){-1, 0}); tyui_text_ex(TYUI_ALIGN_CENTER, "Buttons"); tyui_button("test1"); @@ -97,6 +97,14 @@ void tick(void) tyui_slider_ex(0, 100, &value, true, TYUI_ALIGN_LEFT); 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_pop_layout(); + tyui_end_window(); } @@ -161,7 +169,7 @@ int main(void) tick(); ty_free_temp_allocs(); - // ty_sleep(1000 / hints.ticrate); + ty_sleep(1000 / hints.ticrate); } ty_free_image(img); |
