From 08c75d75c964114bdc77030622ee7a4e886b1a5e Mon Sep 17 00:00:00 2001 From: Antoine Beyeler <49431240+abey79@users.noreply.github.com> Date: Fri, 12 Jul 2024 10:03:59 +0200 Subject: [PATCH] Change default `max_scroll_height` of `egui::Table` to `f32::INFINITY` (#4817) `egui::Table` has a weirdly specific default `max_scroll_height` set to 800.0. This means that even with `vscroll(true)` and `auto_shrink([_, false])`, the table will not expend to the full available height. This PR changes this value to `f32::INFINITY`. This makes it consistent with the corresponding default value of `ScrollArea::max_size.y`, which is where that `max_scroll_height` ends up being used. --- crates/egui_extras/src/table.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/egui_extras/src/table.rs b/crates/egui_extras/src/table.rs index fd6abfee2101..b09a477bce5a 100644 --- a/crates/egui_extras/src/table.rs +++ b/crates/egui_extras/src/table.rs @@ -185,7 +185,7 @@ impl Default for TableScrollOptions { scroll_to_row: None, scroll_offset_y: None, min_scrolled_height: 200.0, - max_scroll_height: 800.0, + max_scroll_height: f32::INFINITY, auto_shrink: Vec2b::TRUE, scroll_bar_visibility: ScrollBarVisibility::VisibleWhenNeeded, }