From c233a9187539f41c63b3ac692c07c2b055271db1 Mon Sep 17 00:00:00 2001 From: Cyrix126 Date: Wed, 11 Dec 2024 19:15:45 +0100 Subject: [PATCH] fix: minimum size button default tab --- src/app/panels/middle/gupax.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/app/panels/middle/gupax.rs b/src/app/panels/middle/gupax.rs index 874f2a9..8eab394 100644 --- a/src/app/panels/middle/gupax.rs +++ b/src/app/panels/middle/gupax.rs @@ -164,10 +164,11 @@ impl Gupax { ui.push_id(1, |ui| { ScrollArea::horizontal().show(ui, |ui| { ui.horizontal(|ui| { - let width = (ui.available_width() / Tab::COUNT as f32) + let width = ((ui.available_width() / Tab::COUNT as f32) - (ui.spacing().button_padding.y * 2.0 + ui.spacing().item_spacing.x) - - SPACE; + - SPACE) + .max(height_txt_before_button(ui, &TextStyle::Button) * 2.0); Tab::iter().enumerate().for_each(|(count, tab)| { if ui .add_sized(