From eca200f67e64a309ada5ccaf0be052bbd0193523 Mon Sep 17 00:00:00 2001 From: Marco Martin Date: Wed, 27 May 2015 18:18:25 +0200 Subject: [PATCH] use color contexts Change-Id: Iea8cc397ddd431c61390ddc70c3fab808ef9f72f --- src/declarativeimports/plasmastyle/ProgressBarStyle.qml | 2 ++ src/declarativeimports/plasmastyle/SliderStyle.qml | 6 ++++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/declarativeimports/plasmastyle/ProgressBarStyle.qml b/src/declarativeimports/plasmastyle/ProgressBarStyle.qml index 6d2e9b30f..303ea7e52 100644 --- a/src/declarativeimports/plasmastyle/ProgressBarStyle.qml +++ b/src/declarativeimports/plasmastyle/ProgressBarStyle.qml @@ -57,6 +57,7 @@ ProgressBarStyle { height: style.implicitHeight imagePath: style.imagePath prefix: "bar-inactive" + colorGroup: PlasmaCore.ColorScope.colorGroup } } @@ -66,6 +67,7 @@ ProgressBarStyle { anchors.verticalCenter: parent.verticalCenter imagePath: style.imagePath prefix: "bar-active" + colorGroup: PlasmaCore.ColorScope.colorGroup width: control.indeterminate ? units.gridUnit * 2 : Math.max(margins.left + margins.right, parent.width) height: style.implicitHeight diff --git a/src/declarativeimports/plasmastyle/SliderStyle.qml b/src/declarativeimports/plasmastyle/SliderStyle.qml index 4824c7de7..99a5fdf58 100644 --- a/src/declarativeimports/plasmastyle/SliderStyle.qml +++ b/src/declarativeimports/plasmastyle/SliderStyle.qml @@ -36,6 +36,7 @@ QtQuickControlStyle.SliderStyle { PlasmaCore.Svg { id: grooveSvg imagePath: "widgets/slider" + colorGroup: PlasmaCore.ColorScope.colorGroup } handle: Item { @@ -57,13 +58,13 @@ QtQuickControlStyle.SliderStyle { elementId: "horizontal-slider-handle" } } - groove: PlasmaCore.FrameSvgItem { id: groove imagePath: "widgets/slider" prefix: "groove" height: implicitHeight * Math.max(1, Math.floor(units.devicePixelRatio)) + colorGroup: PlasmaCore.ColorScope.colorGroup PlasmaCore.FrameSvgItem { id: highlight @@ -73,6 +74,7 @@ QtQuickControlStyle.SliderStyle { width: styleData.handlePosition anchors.verticalCenter: parent.verticalCenter + colorGroup: PlasmaCore.ColorScope.colorGroup visible: value > 0 && slider.enabled } @@ -83,7 +85,7 @@ QtQuickControlStyle.SliderStyle { id: repeater model: control.stepSize > 0 ? 1 + (control.maximumValue - control.minimumValue) / control.stepSize : 0 Rectangle { - color: theme.textColor + color: PlasmaCore.ColorScope.textColor width: 1 ; height: 3 y: repeater.height //Position ticklines from styleData.handleWidth to width - styleData.handleWidth/2