fix gradient bar: clip to 3px height, curve follows screen radius

This commit is contained in:
Damocles 2026-04-12 19:19:26 +02:00
parent a5932a8feb
commit e6c65cad45

View file

@ -27,24 +27,30 @@ PanelWindow {
opacity: M.Theme.barOpacity opacity: M.Theme.barOpacity
} }
Rectangle { Item {
anchors.top: parent.top anchors.top: parent.top
anchors.left: parent.left anchors.left: parent.left
anchors.right: parent.right anchors.right: parent.right
height: M.Theme.screenRadius > 0 ? M.Theme.screenRadius : 3 height: 3
topLeftRadius: M.Theme.screenRadius clip: true
topRightRadius: M.Theme.screenRadius
bottomLeftRadius: 0 Rectangle {
bottomRightRadius: 0 anchors.top: parent.top
gradient: Gradient { anchors.left: parent.left
orientation: Gradient.Horizontal anchors.right: parent.right
GradientStop { height: M.Theme.screenRadius > 0 ? M.Theme.screenRadius * 2 : 3
position: 0 topLeftRadius: M.Theme.screenRadius
color: M.Theme.base0C topRightRadius: M.Theme.screenRadius
} gradient: Gradient {
GradientStop { orientation: Gradient.Horizontal
position: 1 GradientStop {
color: M.Theme.base09 position: 0
color: M.Theme.base0C
}
GradientStop {
position: 1
color: M.Theme.base09
}
} }
} }
} }