From 2b23005fbff5a3d7e218a867e1aadb491abeac55 Mon Sep 17 00:00:00 2001 From: Michael Aaron Murphy Date: Fri, 8 Mar 2024 14:38:28 +0100 Subject: [PATCH] fix(segmented_button): hidden new tab button on shrink --- src/widget/segmented_button/horizontal.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/widget/segmented_button/horizontal.rs b/src/widget/segmented_button/horizontal.rs index d62a183b..36decb28 100644 --- a/src/widget/segmented_button/horizontal.rs +++ b/src/widget/segmented_button/horizontal.rs @@ -150,7 +150,7 @@ where if max_size.width >= visible_width { state.buttons_visible += 1; } else { - visible_width -= button_size.width - (max_height * 2.0); + visible_width = max_size.width - max_height; break; }