aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJ-P Nurmi <jpnurmi@qt.io>2016-08-11 00:04:35 +0200
committerJ-P Nurmi <jpnurmi@qt.io>2016-08-11 08:48:16 +0000
commitaa377b183c93985dfc52d21127df62dfa5b8e2fe (patch)
tree5f67267bf0cd07df8fd8867d1b7e042f76c0a9ef
parent5b4963d52b0a1d894441d1e8e2b4308a0838a8b7 (diff)
Universal: fix editors in dark theme
There is no reason to force ChromeDisabledLowColor when having active focus. ChromeDisabledLowColor is the same color than light theme's BaseHighColor. Universal's foreground color is mapped to BaseHighColor, so we can simply use Universal.foreground to retain the old behavior _and_ get a working foreground color when explicitly turned to a dark editor. Task-number: QTBUG-52738 Change-Id: I2687a3df17985c5ad897f8fd80d808fa27ea918d Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
-rw-r--r--src/imports/controls/universal/TextArea.qml3
-rw-r--r--src/imports/controls/universal/TextField.qml3
2 files changed, 2 insertions, 4 deletions
diff --git a/src/imports/controls/universal/TextArea.qml b/src/imports/controls/universal/TextArea.qml
index 5ca490e7..43fd40f4 100644
--- a/src/imports/controls/universal/TextArea.qml
+++ b/src/imports/controls/universal/TextArea.qml
@@ -56,8 +56,7 @@ T.TextArea {
Universal.theme: activeFocus ? Universal.Light : undefined
- color: !enabled ? Universal.chromeDisabledLowColor :
- activeFocus ? Universal.chromeBlackHighColor : Universal.foreground
+ color: !enabled ? Universal.chromeDisabledLowColor : Universal.foreground
selectionColor: Universal.accent
selectedTextColor: Universal.chromeWhiteColor
diff --git a/src/imports/controls/universal/TextField.qml b/src/imports/controls/universal/TextField.qml
index 13587b5a..a245ba39 100644
--- a/src/imports/controls/universal/TextField.qml
+++ b/src/imports/controls/universal/TextField.qml
@@ -56,8 +56,7 @@ T.TextField {
Universal.theme: activeFocus ? Universal.Light : undefined
- color: !enabled ? Universal.chromeDisabledLowColor :
- activeFocus ? Universal.chromeBlackHighColor : Universal.foreground
+ color: !enabled ? Universal.chromeDisabledLowColor : Universal.foreground
selectionColor: Universal.accent
selectedTextColor: Universal.chromeWhiteColor
verticalAlignment: TextInput.AlignVCenter