use PlasmaCore.ColorScope when suitable

It is possible to put a PlasmaCore.ColorScope element, to automatically
change the colors:
if for instance the complementary scope will be set, all labels
descendent of such element would flip their color

Change-Id: I2214aca522eb094cf067d8726c5bf2a7ecbf36b3
This commit is contained in:
Marco Martin 2014-11-25 18:27:20 +01:00
parent 8415c20760
commit cb8175f1f6
3 changed files with 5 additions and 5 deletions

View File

@ -50,7 +50,7 @@ Text {
font.underline: theme.defaultFont.underline
font.weight: theme.defaultFont.weight
font.wordSpacing: theme.defaultFont.wordSpacing
color: theme.textColor
color: PlasmaCore.ColorScope.textColor
opacity: enabled? 1 : 0.6

View File

@ -36,9 +36,9 @@ QtQuickControlStyle.TextAreaStyle {
font: theme.defaultFont
backgroundColor: "transparent"
textColor: theme.viewTextColor
selectionColor: theme.viewFocusColor
selectedTextColor: theme.viewBackgroundColor
textColor: control.backgroundVisible ? theme.viewTextColor : PlasmaCore.ColorScope.textColor
selectionColor: control.backgroundVisible ? theme.viewFocusColor : PlasmaCore.ColorScope.highlightColor
selectedTextColor: control.backgroundVisible ? theme.viewBackgroundColor : PlasmaCore.ColorScope.backgroundColor
renderType: Text.NativeRendering

View File

@ -87,7 +87,7 @@ QtQuickControlStyle.ButtonStyle {
visible: control.text != ""
Layout.fillWidth: true
height: parent.height
color: control.hovered || !control.flat ? theme.buttonTextColor : theme.textColor
color: control.hovered || !control.flat ? theme.buttonTextColor : PlasmaCore.ColorScope.textColor
horizontalAlignment: icon.valid ? Text.AlignLeft : Text.AlignHCenter
verticalAlignment: Text.AlignVCenter
elide: Text.ElideRight