From 2a2c117ac1381f57492fbaf0a0ba9fbc32636ac6 Mon Sep 17 00:00:00 2001 From: Bharadwaj Raju Date: Mon, 12 Sep 2022 20:34:47 +0000 Subject: [PATCH] Use selected text colors from theme When using Breeze light: | Before | After | | ------ | ------ | | ![Screenshot_20220913_005141](/uploads/9b15c79acaaa92e23855def9ca6bc6ab/Screenshot_20220913_005141.png) | ![Screenshot_20220913_005049](/uploads/06cb614edae21f7ddb027bebaf732edc/Screenshot_20220913_005049.png) | --- imports/NeoChat/Component/Timeline/EncryptedDelegate.qml | 2 ++ imports/NeoChat/Component/Timeline/RichLabel.qml | 2 ++ imports/NeoChat/Panel/RoomDrawer.qml | 4 ++++ 3 files changed, 8 insertions(+) diff --git a/imports/NeoChat/Component/Timeline/EncryptedDelegate.qml b/imports/NeoChat/Component/Timeline/EncryptedDelegate.qml index 243564463..7b54a31f5 100644 --- a/imports/NeoChat/Component/Timeline/EncryptedDelegate.qml +++ b/imports/NeoChat/Component/Timeline/EncryptedDelegate.qml @@ -14,6 +14,8 @@ TimelineContainer { innerObject: TextEdit { text: i18n("This message is encrypted and the sender has not shared the key with this device.") color: Kirigami.Theme.disabledTextColor + selectedTextColor: Kirigami.Theme.highlightedTextColor + selectionColor: Kirigami.Theme.highlightColor font.pointSize: Kirigami.Theme.defaultFont.pointSize selectByMouse: !Kirigami.Settings.isMobile readOnly: true diff --git a/imports/NeoChat/Component/Timeline/RichLabel.qml b/imports/NeoChat/Component/Timeline/RichLabel.qml index eb4c3cf5e..58cf0564f 100644 --- a/imports/NeoChat/Component/Timeline/RichLabel.qml +++ b/imports/NeoChat/Component/Timeline/RichLabel.qml @@ -56,6 +56,8 @@ a{ " + (isEmote ? "* " + author.displayName + " " : "") + textMessage + (isEdited ? (" " + "" + i18n(" (edited)") + "") : "") color: Kirigami.Theme.textColor + selectedTextColor: Kirigami.Theme.highlightedTextColor + selectionColor: Kirigami.Theme.highlightColor font.pointSize: model.reply === undefined && isEmoji.test(model.display) ? Kirigami.Theme.defaultFont.pointSize * 4 : Kirigami.Theme.defaultFont.pointSize selectByMouse: !Kirigami.Settings.isMobile readOnly: true diff --git a/imports/NeoChat/Panel/RoomDrawer.qml b/imports/NeoChat/Panel/RoomDrawer.qml index b62df1433..09a8461fc 100644 --- a/imports/NeoChat/Panel/RoomDrawer.qml +++ b/imports/NeoChat/Panel/RoomDrawer.qml @@ -183,6 +183,8 @@ Kirigami.OverlayDrawer { wrapMode: Text.WordWrap selectByMouse: true color: Kirigami.Theme.textColor + selectedTextColor: Kirigami.Theme.highlightedTextColor + selectionColor: Kirigami.Theme.highlightColor readOnly: true text: room && room.canonicalAlias ? room.canonicalAlias : i18n("No Canonical Alias") } @@ -197,6 +199,8 @@ Kirigami.OverlayDrawer { wrapMode: Text.WordWrap selectByMouse: true color: Kirigami.Theme.textColor + selectedTextColor: Kirigami.Theme.highlightedTextColor + selectionColor: Kirigami.Theme.highlightColor onLinkActivated: UrlHelper.openUrl(link) readOnly: true MouseArea {