diff options
| author | iamcheeseman <[email protected]> | 2026-05-22 11:56:32 -0400 |
|---|---|---|
| committer | iamcheeseman <[email protected]> | 2026-05-22 11:56:32 -0400 |
| commit | 18d62e0d4c8ff204c9f3dac06f91c101362794e5 (patch) | |
| tree | 2cb6e2199517c7b49cc3909a226f2029f5acfe6a | |
| parent | b6b91c8b0a404d5d59087d98a063c20eb28685e0 (diff) | |
tyui: add `tyui_blank_slider()`
| -rw-r--r-- | dc/dc.c | 3 | ||||
| -rw-r--r-- | teensy/teensy_ui.h | 2 |
2 files changed, 4 insertions, 1 deletions
@@ -94,8 +94,9 @@ void tick(void) if (tyui_begin_window("2nd Window", ty_recti(110, 5, 100, 120), &winid2)) { static float value = 100; tyui_slider(0, 100, &value); - tyui_slider_ex(0, 100, &value, false, 0); 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_end_window(); } diff --git a/teensy/teensy_ui.h b/teensy/teensy_ui.h index 2dcd4f6..6230aff 100644 --- a/teensy/teensy_ui.h +++ b/teensy/teensy_ui.h @@ -16,6 +16,8 @@ #define tyui_text(...) tyui_text_ex(TYUI_ALIGN_LEFT, __VA_ARGS__) #define tyui_slider(min, max, value_ptr) \ tyui_slider_ex(min, max, value_ptr, true, TYUI_ALIGN_CENTER) +#define tyui_blank_slider(min, max, value_ptr) \ + tyui_slider_ex(min, max, value_ptr, false, 0) typedef uint8_t tyui_Align; enum { |
