From 2861d1fca3361d3617b2c8d84c91942c0dbc33ed Mon Sep 17 00:00:00 2001 From: ivan tkachenko Date: Mon, 2 May 2022 01:49:45 +0300 Subject: [PATCH] [lookandfeel] Fix collapsed width of a volume/brightness OSD on a lock screen Amends c067d4985a49cdef8ed0d96ba8019a7b945b1741. Having `preferredWidth: 1` set on an only item that also stretches with fillWidth AND without top-to-bottom sizing (fixed size imposed by parent component) doesn't really make sense. It naturally increased row layout's implicitWidth by only 1, and that value were used as an input to the final width expression (bottom-up sizing). This patch fixes the sizing model to be strictly implicit bottom-up and explicit top-down, and so the slider no longer collapses. BUG: 446185 --- lookandfeel/contents/osd/OsdItem.qml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lookandfeel/contents/osd/OsdItem.qml b/lookandfeel/contents/osd/OsdItem.qml index 76eda19eb..172b58dbd 100644 --- a/lookandfeel/contents/osd/OsdItem.qml +++ b/lookandfeel/contents/osd/OsdItem.qml @@ -49,7 +49,7 @@ RowLayout { Layout.fillWidth: true Layout.alignment: Qt.AlignVCenter // So it never exceeds the minimum popup size - Layout.preferredWidth: 1 + Layout.minimumWidth: 0 Layout.rightMargin: PlasmaCore.Units.smallSpacing visible: showingProgress from: 0