From 1d942b07379e76b35f4de705b713720a9a8ed22e Mon Sep 17 00:00:00 2001 From: 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com> Date: Fri, 2 May 2025 20:58:49 +1000 Subject: scrollbar: show gutter + enable scrolling --- widgets/StyledScrollBar.qml | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) (limited to 'widgets') diff --git a/widgets/StyledScrollBar.qml b/widgets/StyledScrollBar.qml index 889a1c3..b341173 100644 --- a/widgets/StyledScrollBar.qml +++ b/widgets/StyledScrollBar.qml @@ -6,11 +6,25 @@ ScrollBar { id: root contentItem: StyledRect { + opacity: 0 radius: Appearance.rounding.full - color: Qt.alpha(Appearance.colours.m3secondary, 0.5) + color: Qt.alpha(Appearance.colours.m3secondary, 0.6) } background: StyledRect { implicitWidth: 10 + opacity: 0 + radius: Appearance.rounding.full + color: Qt.alpha(Appearance.colours.m3surfaceContainerLow, 0.4) + + MouseArea { + anchors.fill: parent + onWheel: event => { + if (event.angleDelta.y > 0) + root.decrease(); + else if (event.angleDelta.y < 0) + root.increase(); + } + } } } -- cgit v1.2.3-freya