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.
This commit is contained in:
Ghostkeeper 2022-01-13 16:38:21 +01:00
parent 404e02d585
commit b5e7a60a8a
No known key found for this signature in database
GPG Key ID: D2A8871EE34EC59A

View File

@ -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
{