Change in plasma-framework[master]: use PlasmaCore.ColorScope when suitable
Marco Martin (Code Review)
noreply at kde.org
Tue Nov 25 17:29:36 UTC 2014
Marco Martin has uploaded a new change for review.
https://gerrit.vesnicky.cesnet.cz/r/177
Change subject: use PlasmaCore.ColorScope when suitable
......................................................................
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
---
M src/declarativeimports/plasmacomponents/qml/Label.qml
M src/declarativeimports/plasmacomponents/qml/styles/TextAreaStyle.qml
M src/declarativeimports/plasmacomponents/qml/styles/ToolButtonStyle.qml
3 files changed, 5 insertions(+), 5 deletions(-)
git pull ssh://gerrit.vesnicky.cesnet.cz:29418/plasma-framework refs/changes/77/177/1
diff --git a/src/declarativeimports/plasmacomponents/qml/Label.qml b/src/declarativeimports/plasmacomponents/qml/Label.qml
index 1243ca6..a22efb6 100644
--- a/src/declarativeimports/plasmacomponents/qml/Label.qml
+++ b/src/declarativeimports/plasmacomponents/qml/Label.qml
@@ -50,7 +50,7 @@
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
diff --git a/src/declarativeimports/plasmacomponents/qml/styles/TextAreaStyle.qml b/src/declarativeimports/plasmacomponents/qml/styles/TextAreaStyle.qml
index 68f1a8b..90af0c5 100644
--- a/src/declarativeimports/plasmacomponents/qml/styles/TextAreaStyle.qml
+++ b/src/declarativeimports/plasmacomponents/qml/styles/TextAreaStyle.qml
@@ -36,9 +36,9 @@
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
diff --git a/src/declarativeimports/plasmacomponents/qml/styles/ToolButtonStyle.qml b/src/declarativeimports/plasmacomponents/qml/styles/ToolButtonStyle.qml
index af04469..cf19524 100644
--- a/src/declarativeimports/plasmacomponents/qml/styles/ToolButtonStyle.qml
+++ b/src/declarativeimports/plasmacomponents/qml/styles/ToolButtonStyle.qml
@@ -87,7 +87,7 @@
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
--
To view, visit https://gerrit.vesnicky.cesnet.cz/r/177
To unsubscribe, visit https://gerrit.vesnicky.cesnet.cz/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I2214aca522eb094cf067d8726c5bf2a7ecbf36b3
Gerrit-PatchSet: 1
Gerrit-Project: plasma-framework
Gerrit-Branch: master
Gerrit-Owner: Marco Martin <notmart at gmail.com>
Gerrit-Reviewer: David Edmundson <david at davidedmundson.co.uk>
More information about the Plasma-devel
mailing list