From 6bf5113bbef25445d16c7c40b3e9ff7bc38327d3 Mon Sep 17 00:00:00 2001 From: Matthieu Gallien Date: Wed, 28 Aug 2024 22:11:22 +0200 Subject: [PATCH] left align UI elements in settings but inside a centered box Signed-off-by: Matthieu Gallien --- src/gui/generalsettings.ui | 377 +++--------------------- src/gui/networksettings.ui | 571 +++++++++++++++++++------------------ 2 files changed, 323 insertions(+), 625 deletions(-) diff --git a/src/gui/generalsettings.ui b/src/gui/generalsettings.ui index 27f51910e8844..da90806cf4834 100644 --- a/src/gui/generalsettings.ui +++ b/src/gui/generalsettings.ui @@ -29,6 +29,12 @@ + + + 645 + 16777215 + + QFrame::Shape::StyledPanel @@ -50,19 +56,6 @@ - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - @@ -106,39 +99,10 @@ - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - - - - - Qt::Orientation::Horizontal - - - QSizePolicy::Policy::Expanding - - - - 40 - 20 - - - - @@ -152,39 +116,10 @@ - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - - - - - Qt::Orientation::Horizontal - - - QSizePolicy::Policy::Expanding - - - - 40 - 20 - - - - @@ -198,38 +133,12 @@ - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - @@ -243,36 +152,10 @@ - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - @@ -280,36 +163,10 @@ - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - @@ -317,36 +174,10 @@ - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - @@ -360,25 +191,12 @@ - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - - + Qt::Orientation::Horizontal @@ -430,6 +248,12 @@ 0 + + + 645 + 16777215 + + QFrame::Shape::StyledPanel @@ -471,19 +295,6 @@ - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - @@ -559,36 +370,10 @@ - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - @@ -605,19 +390,6 @@ - - - - - 0 - 0 - - - - Check Now - - - @@ -631,6 +403,19 @@ + + + + + 0 + 0 + + + + Check Now + + + @@ -691,6 +476,12 @@ 0 + + + 645 + 16777215 + + QFrame::Shape::StyledPanel @@ -713,19 +504,6 @@ - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - @@ -742,36 +520,10 @@ - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - @@ -788,36 +540,10 @@ - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - @@ -831,36 +557,10 @@ - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - @@ -874,19 +574,6 @@ - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - diff --git a/src/gui/networksettings.ui b/src/gui/networksettings.ui index 6e584b1800ac2..40ea461e3e843 100644 --- a/src/gui/networksettings.ui +++ b/src/gui/networksettings.ui @@ -6,262 +6,14 @@ 0 0 - 524 - 527 + 645 + 817 Form - - - - - Qt::Orientation::Vertical - - - - 20 - 40 - - - - - - - - 0 - - - 0 - - - - - - 0 - 0 - - - - QFrame::Shape::StyledPanel - - - - 9 - - - 0 - - - 6 - - - - - Qt::Orientation::Vertical - - - - 20 - 40 - - - - - - - - Limit to 3/4 of estimated bandwidth - - - Limit automatically - - - - - - - Use global settings - - - - - - - - - true - - - 999999 - - - 80 - - - - - - - - 0 - 0 - - - - KBytes/s - - - - - - - - - No limit - - - true - - - - - - - Limit to - - - - - - - Download Bandwidth: - - - - - - - - - - - 0 - 0 - - - - QFrame::Shape::StyledPanel - - - - 9 - - - 0 - - - 6 - - - - - Limit to - - - - - - - - - true - - - 1 - - - 999999 - - - 10 - - - - - - - - 0 - 0 - - - - KBytes/s - - - - - - - - - Qt::Orientation::Vertical - - - - 20 - 40 - - - - - - - - Limit to 3/4 of estimated bandwidth - - - Limit automatically - - - - - - - Use global settings - - - - - - - No limit - - - true - - - - - - - Upload Bandwidth: - - - - - autoUploadLimitRadioButton - uploadLimitRadioButton - noUploadLimitRadioButton - verticalSpacer_3 - globalUploadSettingsRadioButton - label_4 - - - - + @@ -273,11 +25,60 @@ 0 + + + 645 + 16777215 + + QFrame::Shape::StyledPanel - - + + + + + Proxy Settings: + + + Qt::AlignmentFlag::AlignCenter + + + + + + + Use global settings + + + proxyButtonGroup + + + + + + + No proxy + + + true + + + proxyButtonGroup + + + + + + + Use system proxy + + + proxyButtonGroup + + + + Qt::Orientation::Horizontal @@ -290,7 +91,17 @@ - + + + + Manually specify proxy + + + proxyButtonGroup + + + + @@ -478,59 +289,259 @@ - - + + + + + + + + 0 + 0 + + + + + 645 + 16777215 + + + + QFrame::Shape::StyledPanel + + + + 9 + + + 0 + + + + + Download Bandwidth: + + + Qt::AlignmentFlag::AlignCenter + + + + + Use global settings - - proxyButtonGroup - - - + + - Manually specify proxy + No limit + + + true - - proxyButtonGroup - - - + + + + Limit to 3/4 of estimated bandwidth + - Use system proxy + Limit automatically - - proxyButtonGroup - - - + + - No proxy + Limit to + + + + + + + + + true + + + 999999 + + + 80 + + + + + + + + 0 + 0 + + + + KBytes/s + + + + + + + + + Qt::Orientation::Vertical + + + + 20 + 40 + + + + + + + + + + + + 0 + 0 + + + + + 645 + 16777215 + + + + QFrame::Shape::StyledPanel + + + + 9 + + + 0 + + + + + Upload Bandwidth: + + + Qt::AlignmentFlag::AlignCenter + + + + + + + Use global settings + + + + + + + No limit true - - proxyButtonGroup - - - + + + + Limit to 3/4 of estimated bandwidth + - Proxy Settings: + Limit automatically + + + + + + + Limit to + + + + + + true + + + 1 + + + 999999 + + + 10 + + + + + + + + 0 + 0 + + + + KBytes/s + + + + + + + + + Qt::Orientation::Vertical + + + + 20 + 40 + + + + + autoUploadLimitRadioButton + uploadLimitRadioButton + noUploadLimitRadioButton + verticalSpacer_3 + globalUploadSettingsRadioButton + label_4 + + + + Qt::Orientation::Vertical + + + + 20 + 40 + + + +