From b5e7a60a8ada05d73b92863adee23f20091dbefb Mon Sep 17 00:00:00 2001 From: Ghostkeeper Date: Thu, 13 Jan 2022 16:38:21 +0100 Subject: [PATCH] Fix scaling of language and theme drop-downs with width The width was unknown because it's all in a scrollview that could have an infinite width. I now fixed it to scale with the viewport's width. Contributes to issue CURA-8682. --- resources/qml/Preferences/GeneralPage.qml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/resources/qml/Preferences/GeneralPage.qml b/resources/qml/Preferences/GeneralPage.qml index e7323393ec..7ea89e34ba 100644 --- a/resources/qml/Preferences/GeneralPage.qml +++ b/resources/qml/Preferences/GeneralPage.qml @@ -17,6 +17,8 @@ UM.PreferencesPage title: catalog.i18nc("@title:tab", "General") id: generalPreferencesPage + width: parent.width + function setDefaultLanguage(languageCode) { //loops through the languageList and sets the language using the languageCode @@ -128,14 +130,14 @@ UM.PreferencesPage ScrollView { + id: preferencesScrollView width: parent.width height: parent.height Column { - - //: Language selection label UM.I18nCatalog{id: catalog; name: "cura"} + width: preferencesScrollView.viewport.width Label { @@ -212,7 +214,7 @@ UM.PreferencesPage Label { id: currencyLabel - text: catalog.i18nc("@label","Currency:") + text: catalog.i18nc("@label", "Currency:") } TextField