From c2d344bd8c3a665a957c77fe3c1741d8bfe875ec Mon Sep 17 00:00:00 2001 From: FrHun <28605587+frhun@users.noreply.github.com> Date: Thu, 26 May 2022 15:34:32 +0200 Subject: [PATCH] ThemeEditor: Fix layout for new layout system --- Userland/Applications/ThemeEditor/AlignmentProperty.gml | 2 +- Userland/Applications/ThemeEditor/ColorProperty.gml | 2 +- Userland/Applications/ThemeEditor/FlagProperty.gml | 2 +- Userland/Applications/ThemeEditor/MainWidget.cpp | 2 +- Userland/Applications/ThemeEditor/MetricProperty.gml | 2 +- Userland/Applications/ThemeEditor/PathProperty.gml | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Userland/Applications/ThemeEditor/AlignmentProperty.gml b/Userland/Applications/ThemeEditor/AlignmentProperty.gml index e0a62ee7e6..235bb90a26 100644 --- a/Userland/Applications/ThemeEditor/AlignmentProperty.gml +++ b/Userland/Applications/ThemeEditor/AlignmentProperty.gml @@ -2,7 +2,7 @@ layout: @GUI::HorizontalBoxLayout { spacing: 4 } - shrink_to_fit: true + preferred_height: "fit" @GUI::Label { name: "name" diff --git a/Userland/Applications/ThemeEditor/ColorProperty.gml b/Userland/Applications/ThemeEditor/ColorProperty.gml index 77504033a0..975317bc18 100644 --- a/Userland/Applications/ThemeEditor/ColorProperty.gml +++ b/Userland/Applications/ThemeEditor/ColorProperty.gml @@ -2,7 +2,7 @@ layout: @GUI::HorizontalBoxLayout { spacing: 4 } - shrink_to_fit: true + preferred_height: "fit" @GUI::Label { name: "name" diff --git a/Userland/Applications/ThemeEditor/FlagProperty.gml b/Userland/Applications/ThemeEditor/FlagProperty.gml index e5e4cb66cb..ab71d41dfe 100644 --- a/Userland/Applications/ThemeEditor/FlagProperty.gml +++ b/Userland/Applications/ThemeEditor/FlagProperty.gml @@ -2,7 +2,7 @@ layout: @GUI::HorizontalBoxLayout { spacing: 4 } - shrink_to_fit: true + preferred_height: "fit" @GUI::CheckBox { name: "checkbox" diff --git a/Userland/Applications/ThemeEditor/MainWidget.cpp b/Userland/Applications/ThemeEditor/MainWidget.cpp index 034e3bc16b..9583d8c2fe 100644 --- a/Userland/Applications/ThemeEditor/MainWidget.cpp +++ b/Userland/Applications/ThemeEditor/MainWidget.cpp @@ -468,7 +468,7 @@ void MainWidget::add_property_tab(PropertyTab const& property_tab) group_box->layout()->set_spacing(12); // 1px less on the left makes the text line up with the group title. group_box->layout()->set_margins({ 8, 8, 8, 7 }); - group_box->set_shrink_to_fit(true); + group_box->set_preferred_height(GUI::SpecialDimension::Fit); for (auto const& property : group.properties) { NonnullRefPtr row_widget = group_box->add(); diff --git a/Userland/Applications/ThemeEditor/MetricProperty.gml b/Userland/Applications/ThemeEditor/MetricProperty.gml index b49896bcff..11c8e2c8a6 100644 --- a/Userland/Applications/ThemeEditor/MetricProperty.gml +++ b/Userland/Applications/ThemeEditor/MetricProperty.gml @@ -2,7 +2,7 @@ layout: @GUI::HorizontalBoxLayout { spacing: 4 } - shrink_to_fit: true + preferred_height: "fit" @GUI::Label { name: "name" diff --git a/Userland/Applications/ThemeEditor/PathProperty.gml b/Userland/Applications/ThemeEditor/PathProperty.gml index d42d0cb863..4d5d0e3f56 100644 --- a/Userland/Applications/ThemeEditor/PathProperty.gml +++ b/Userland/Applications/ThemeEditor/PathProperty.gml @@ -2,7 +2,7 @@ layout: @GUI::HorizontalBoxLayout { spacing: 4 } - shrink_to_fit: true + preferred_height: "fit" @GUI::Label { name: "name"