diff --git a/resources/qml/dialogs/AliasEditor.qml b/resources/qml/dialogs/AliasEditor.qml
index 8a79f7d2..32efff22 100644
--- a/resources/qml/dialogs/AliasEditor.qml
+++ b/resources/qml/dialogs/AliasEditor.qml
@@ -41,7 +41,7 @@ ApplicationWindow {
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 1.1)
Layout.fillWidth: true
Layout.fillHeight: false
- color: Nheko.colors.text
+ color: palette.text
Layout.bottomMargin: Nheko.paddingMedium
}
@@ -69,7 +69,7 @@ ApplicationWindow {
Text {
Layout.fillWidth: true
text: model.name
- color: model.isPublished ? Nheko.colors.text : Nheko.theme.error
+ color: model.isPublished ? palette.text : Nheko.theme.error
textFormat: Text.PlainText
}
@@ -78,8 +78,8 @@ ApplicationWindow {
Layout.margins: 2
image: ":/icons/icons/ui/star.svg"
hoverEnabled: true
- buttonTextColor: model.isCanonical ? Nheko.colors.highlight : Nheko.colors.text
- highlightColor: editingModel.canAdvertize ? Nheko.colors.highlight : buttonTextColor
+ buttonTextColor: model.isCanonical ? palette.highlight : palette.text
+ highlightColor: editingModel.canAdvertize ? palette.highlight : buttonTextColor
ToolTip.visible: hovered
ToolTip.text: model.isCanonical ? qsTr("Primary alias") : qsTr("Make primary alias")
@@ -92,8 +92,8 @@ ApplicationWindow {
Layout.margins: 2
image: ":/icons/icons/ui/building-shop.svg"
hoverEnabled: true
- buttonTextColor: model.isAdvertized ? Nheko.colors.highlight : Nheko.colors.text
- highlightColor: editingModel.canAdvertize ? Nheko.colors.highlight : buttonTextColor
+ buttonTextColor: model.isAdvertized ? palette.highlight : palette.text
+ highlightColor: editingModel.canAdvertize ? palette.highlight : buttonTextColor
ToolTip.visible: hovered
ToolTip.text: qsTr("Advertise as an alias in this room")
@@ -106,7 +106,7 @@ ApplicationWindow {
Layout.margins: 2
image: ":/icons/icons/ui/room-directory.svg"
hoverEnabled: true
- buttonTextColor: model.isPublished ? Nheko.colors.highlight : Nheko.colors.text
+ buttonTextColor: model.isPublished ? palette.highlight : palette.text
ToolTip.visible: hovered
ToolTip.text: qsTr("Publish in room directory")
@@ -139,7 +139,7 @@ ApplicationWindow {
Layout.fillWidth: true
selectByMouse: true
font.pixelSize: fontMetrics.font.pixelSize
- color: Nheko.colors.text
+ color: palette.text
placeholderText: qsTr("#new-alias:server.tld")
Component.onCompleted: forceActiveFocus()
diff --git a/resources/qml/dialogs/AllowedRoomsSettingsDialog.qml b/resources/qml/dialogs/AllowedRoomsSettingsDialog.qml
index d93f1f18..94ecf651 100644
--- a/resources/qml/dialogs/AllowedRoomsSettingsDialog.qml
+++ b/resources/qml/dialogs/AllowedRoomsSettingsDialog.qml
@@ -20,8 +20,7 @@ ApplicationWindow {
minimumHeight: 450
width: 450
height: 680
- palette: Nheko.colors
- color: Nheko.colors.window
+ color: palette.window
modality: Qt.NonModal
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
title: qsTr("Allowed rooms settings")
@@ -42,7 +41,7 @@ ApplicationWindow {
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 1.1)
Layout.fillWidth: true
Layout.fillHeight: false
- color: Nheko.colors.text
+ color: palette.text
Layout.bottomMargin: Nheko.paddingMedium
}
@@ -72,14 +71,14 @@ ApplicationWindow {
Text {
Layout.fillWidth: true
text: model.name
- color: Nheko.colors.text
+ color: palette.text
textFormat: Text.PlainText
}
Text {
Layout.fillWidth: true
text: model.isParent ? qsTr("Parent community") : qsTr("Other room")
- color: Nheko.colors.buttonText
+ color: palette.buttonText
textFormat: Text.PlainText
}
}
@@ -122,7 +121,7 @@ ApplicationWindow {
placeholderText: qsTr("Enter additional rooms not in the list yet...")
- color: Nheko.colors.text
+ color: palette.text
onTextEdited: {
roomCompleter.completer.searchString = text;
}
diff --git a/resources/qml/dialogs/ConfirmJoinRoomDialog.qml b/resources/qml/dialogs/ConfirmJoinRoomDialog.qml
index b37630c8..a3fb9831 100644
--- a/resources/qml/dialogs/ConfirmJoinRoomDialog.qml
+++ b/resources/qml/dialogs/ConfirmJoinRoomDialog.qml
@@ -19,8 +19,7 @@ ApplicationWindow {
title: summary.isSpace ? qsTr("Confirm community join") : qsTr("Confirm room join")
modality: Qt.WindowModal
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
- palette: Nheko.colors
- color: Nheko.colors.window
+ color: palette.window
width: 350
height: content.implicitHeight + Nheko.paddingLarge + footer.implicitHeight
@@ -48,7 +47,7 @@ ApplicationWindow {
Spinner {
Layout.alignment: Qt.AlignHCenter
visible: !summary.isLoaded
- foreground: Nheko.colors.mid
+ foreground: palette.mid
running: !summary.isLoaded
}
@@ -57,7 +56,7 @@ ApplicationWindow {
textFormat: TextEdit.RichText
text: summary.roomName
font.pixelSize: fontMetrics.font.pixelSize * 2
- color: Nheko.colors.text
+ color: palette.text
Layout.alignment: Qt.AlignHCenter
Layout.fillWidth: true
@@ -70,7 +69,7 @@ ApplicationWindow {
textFormat: TextEdit.RichText
text: summary.roomid
font.pixelSize: fontMetrics.font.pixelSize * 0.8
- color: Nheko.colors.text
+ color: palette.text
Layout.alignment: Qt.AlignHCenter
Layout.fillWidth: true
@@ -96,7 +95,7 @@ ApplicationWindow {
readOnly: true
textFormat: TextEdit.RichText
text: summary.roomTopic
- color: Nheko.colors.text
+ color: palette.text
Layout.alignment: Qt.AlignHCenter
Layout.fillWidth: true
@@ -109,7 +108,7 @@ ApplicationWindow {
id: promptLabel
text: summary.isKnockOnly ? qsTr("This room can't be joined directly. You can, however, knock on the room and room members can accept or decline this join request. You can additionally provide a reason for them to let you in below:") : qsTr("Do you want to join this room? You can optionally add a reason below:")
- color: Nheko.colors.text
+ color: palette.text
Layout.fillWidth: true
horizontalAlignment: Text.AlignHCenter
wrapMode: Text.Wrap
diff --git a/resources/qml/dialogs/CreateDirect.qml b/resources/qml/dialogs/CreateDirect.qml
index 4ce568bb..75013970 100644
--- a/resources/qml/dialogs/CreateDirect.qml
+++ b/resources/qml/dialogs/CreateDirect.qml
@@ -55,14 +55,14 @@ ApplicationWindow {
Label {
Layout.fillWidth: true
text: profile? profile.displayName : ""
- color: TimelineManager.userColor(userID.text, Nheko.colors.window)
+ color: TimelineManager.userColor(userID.text, palette.window)
font.pointSize: fontMetrics.font.pointSize
}
Label {
Layout.fillWidth: true
text: userID.text
- color: Nheko.colors.buttonText
+ color: palette.buttonText
font.pointSize: fontMetrics.font.pointSize * 0.9
}
}
@@ -89,7 +89,7 @@ ApplicationWindow {
Layout.fillWidth: true
Layout.alignment: Qt.AlignLeft
text: qsTr("Encryption")
- color: Nheko.colors.text
+ color: palette.text
}
ToggleButton {
Layout.alignment: Qt.AlignRight
diff --git a/resources/qml/dialogs/CreateRoom.qml b/resources/qml/dialogs/CreateRoom.qml
index cb198bb8..2164ba50 100644
--- a/resources/qml/dialogs/CreateRoom.qml
+++ b/resources/qml/dialogs/CreateRoom.qml
@@ -64,7 +64,7 @@ ApplicationWindow {
Label {
Layout.preferredWidth: implicitWidth
text: "#"
- color: Nheko.colors.text
+ color: palette.text
}
MatrixTextField {
id: newRoomAlias
@@ -75,14 +75,14 @@ ApplicationWindow {
Layout.preferredWidth: implicitWidth
property string userName: userInfoGrid.profile.userid
text: userName.substring(userName.indexOf(":"))
- color: Nheko.colors.text
+ color: palette.text
}
}
Label {
Layout.preferredWidth: implicitWidth
Layout.alignment: Qt.AlignLeft
text: qsTr("Public")
- color: Nheko.colors.text
+ color: palette.text
HoverHandler {
id: privateHover
}
@@ -101,7 +101,7 @@ ApplicationWindow {
Layout.preferredWidth: implicitWidth
Layout.alignment: Qt.AlignLeft
text: qsTr("Trusted")
- color: Nheko.colors.text
+ color: palette.text
HoverHandler {
id: trustedHover
}
@@ -122,7 +122,7 @@ ApplicationWindow {
Layout.preferredWidth: implicitWidth
Layout.alignment: Qt.AlignLeft
text: qsTr("Encryption")
- color: Nheko.colors.text
+ color: palette.text
HoverHandler {
id: encryptionHover
}
diff --git a/resources/qml/dialogs/ImagePackEditorDialog.qml b/resources/qml/dialogs/ImagePackEditorDialog.qml
index 4f30e78a..9e848150 100644
--- a/resources/qml/dialogs/ImagePackEditorDialog.qml
+++ b/resources/qml/dialogs/ImagePackEditorDialog.qml
@@ -22,8 +22,7 @@ ApplicationWindow {
title: qsTr("Editing image pack")
height: 600
width: 600
- palette: Nheko.colors
- color: Nheko.colors.base
+ color: palette.base
modality: Qt.WindowModal
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
@@ -73,13 +72,12 @@ ApplicationWindow {
anchors.verticalCenter: parent.verticalCenter
height: parent.height - Nheko.paddingSmall * 2
width: 3
- color: Nheko.colors.highlight
+ color: palette.highlight
}
}
footer: Button {
- palette: Nheko.colors
onClicked: addFilesDialog.open()
width: ListView.view.width
text: qsTr("Add images")
@@ -100,11 +98,11 @@ ApplicationWindow {
delegate: AvatarListTile {
id: packItem
- property color background: Nheko.colors.window
- property color importantText: Nheko.colors.text
- property color unimportantText: Nheko.colors.buttonText
- property color bubbleBackground: Nheko.colors.highlight
- property color bubbleText: Nheko.colors.highlightedText
+ property color background: palette.window
+ property color importantText: palette.text
+ property color unimportantText: palette.buttonText
+ property color bubbleBackground: palette.highlight
+ property color bubbleText: palette.highlightedText
required property string shortCode
required property string url
required property string body
@@ -129,7 +127,7 @@ ApplicationWindow {
id: packinfoC
Rectangle {
- color: Nheko.colors.window
+ color: palette.window
GridLayout {
anchors.fill: parent
diff --git a/resources/qml/dialogs/ImagePackSettingsDialog.qml b/resources/qml/dialogs/ImagePackSettingsDialog.qml
index 76d84a07..31a34c94 100644
--- a/resources/qml/dialogs/ImagePackSettingsDialog.qml
+++ b/resources/qml/dialogs/ImagePackSettingsDialog.qml
@@ -23,8 +23,7 @@ ApplicationWindow {
title: qsTr("Image pack settings")
height: 600
width: 800
- palette: Nheko.colors
- color: Nheko.colors.base
+ color: palette.base
modality: Qt.NonModal
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
@@ -64,7 +63,6 @@ ApplicationWindow {
footer: ColumnLayout {
Button {
- palette: Nheko.colors
onClicked: {
var dialog = packEditor.createObject(timelineRoot, {
"imagePack": packlist.newPack(false)
@@ -78,7 +76,6 @@ ApplicationWindow {
}
Button {
- palette: Nheko.colors
onClicked: {
var dialog = packEditor.createObject(timelineRoot, {
"imagePack": packlist.newPack(true)
@@ -96,11 +93,11 @@ ApplicationWindow {
delegate: AvatarListTile {
id: packItem
- property color background: Nheko.colors.window
- property color importantText: Nheko.colors.text
- property color unimportantText: Nheko.colors.buttonText
- property color bubbleBackground: Nheko.colors.highlight
- property color bubbleText: Nheko.colors.highlightedText
+ property color background: palette.window
+ property color importantText: palette.text
+ property color unimportantText: palette.buttonText
+ property color bubbleBackground: palette.highlight
+ property color bubbleText: palette.highlightedText
required property string displayName
required property bool fromAccountData
required property bool fromCurrentRoom
@@ -135,7 +132,7 @@ ApplicationWindow {
id: packinfoC
Rectangle {
- color: Nheko.colors.window
+ color: palette.window
ColumnLayout {
id: packinfo
@@ -243,7 +240,7 @@ ApplicationWindow {
background: Rectangle {
anchors.fill: parent
- color: hovered ? Nheko.colors.highlight : 'transparent'
+ color: hovered ? palette.highlight : 'transparent'
radius: 5
}
diff --git a/resources/qml/dialogs/InputDialog.qml b/resources/qml/dialogs/InputDialog.qml
index a4ca1683..49becc67 100644
--- a/resources/qml/dialogs/InputDialog.qml
+++ b/resources/qml/dialogs/InputDialog.qml
@@ -37,7 +37,7 @@ ApplicationWindow {
Label {
id: promptLabel
- color: Nheko.colors.text
+ color: palette.text
}
MatrixTextField {
diff --git a/resources/qml/dialogs/InviteDialog.qml b/resources/qml/dialogs/InviteDialog.qml
index b142818d..f5d467db 100644
--- a/resources/qml/dialogs/InviteDialog.qml
+++ b/resources/qml/dialogs/InviteDialog.qml
@@ -40,8 +40,7 @@ ApplicationWindow {
title: qsTr("Invite users to %1").arg(invitees.room.plainRoomName)
height: 380
width: 340
- palette: Nheko.colors
- color: Nheko.colors.window
+ color: palette.window
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
Shortcut {
@@ -74,12 +73,12 @@ ApplicationWindow {
anchors.centerIn: parent
id: inviteeUserid
text: model.displayName != "" ? model.displayName : model.userid
- color: inviteeButton.hovered ? Nheko.colors.highlightedText: Nheko.colors.text
+ color: inviteeButton.hovered ? palette.highlightedText: palette.text
maximumLineCount: 1
}
background: Rectangle {
- border.color: Nheko.colors.text
- color: inviteeButton.hovered ? Nheko.colors.highlight : Nheko.colors.window
+ border.color: palette.text
+ color: inviteeButton.hovered ? palette.highlight : palette.window
border.width: 1
radius: inviteeButton.height / 2
}
@@ -90,7 +89,7 @@ ApplicationWindow {
Label {
text: qsTr("Search user")
Layout.fillWidth: true
- color: Nheko.colors.text
+ color: palette.text
}
RowLayout {
spacing: Nheko.paddingMedium
@@ -100,7 +99,7 @@ ApplicationWindow {
property bool isValidMxid: text.match("@.+?:.{3,}")
- backgroundColor: Nheko.colors.window
+ backgroundColor: palette.window
placeholderText: qsTr("@joe:matrix.org", "Example user id. The name 'joe' can be localized however you want.")
Layout.fillWidth: true
onAccepted: {
@@ -158,7 +157,7 @@ ApplicationWindow {
avatarUrl: profile? profile.avatarUrl : ""
userid: inviteeEntry.text
onClicked: addInvite(inviteeEntry.text, displayName, avatarUrl)
- bgColor: del3.hovered ? Nheko.colors.dark : inviteDialogRoot.color
+ bgColor: del3.hovered ? palette.dark : inviteDialogRoot.color
}
ListView {
visible: !inviteeEntry.isValidMxid
@@ -175,7 +174,7 @@ ApplicationWindow {
userid: model.userid
avatarUrl: model.avatarUrl
onClicked: addInvite(userid, displayName, avatarUrl)
- bgColor: del2.hovered ? Nheko.colors.dark : inviteDialogRoot.color
+ bgColor: del2.hovered ? palette.dark : inviteDialogRoot.color
}
}
Rectangle {
@@ -202,7 +201,7 @@ ApplicationWindow {
userid: model.mxid
avatarUrl: model.avatarUrl
displayName: model.displayName
- bgColor: del.hovered ? Nheko.colors.dark : inviteDialogRoot.color
+ bgColor: del.hovered ? palette.dark : inviteDialogRoot.color
ImageButton {
anchors.right: parent.right
anchors.rightMargin: Nheko.paddingSmall
diff --git a/resources/qml/dialogs/JoinRoomDialog.qml b/resources/qml/dialogs/JoinRoomDialog.qml
index 57c7bad8..0974325a 100644
--- a/resources/qml/dialogs/JoinRoomDialog.qml
+++ b/resources/qml/dialogs/JoinRoomDialog.qml
@@ -14,8 +14,7 @@ ApplicationWindow {
title: qsTr("Join room")
modality: Qt.WindowModal
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
- palette: Nheko.colors
- color: Nheko.colors.window
+ color: palette.window
width: 350
height: fontMetrics.lineSpacing * 7
@@ -33,7 +32,7 @@ ApplicationWindow {
id: promptLabel
text: qsTr("Room ID or alias")
- color: Nheko.colors.text
+ color: palette.text
}
MatrixTextField {
diff --git a/resources/qml/dialogs/PhoneNumberInputDialog.qml b/resources/qml/dialogs/PhoneNumberInputDialog.qml
index f7719800..f1b8eef8 100644
--- a/resources/qml/dialogs/PhoneNumberInputDialog.qml
+++ b/resources/qml/dialogs/PhoneNumberInputDialog.qml
@@ -31,7 +31,7 @@ ApplicationWindow {
id: promptLabel
Layout.columnSpan: 2
- color: Nheko.colors.text
+ color: palette.text
}
ComboBox {
diff --git a/resources/qml/dialogs/PowerLevelEditor.qml b/resources/qml/dialogs/PowerLevelEditor.qml
index 7125c712..9fc9ee15 100644
--- a/resources/qml/dialogs/PowerLevelEditor.qml
+++ b/resources/qml/dialogs/PowerLevelEditor.qml
@@ -41,14 +41,13 @@ ApplicationWindow {
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 1.1)
Layout.fillWidth: true
Layout.fillHeight: false
- color: Nheko.colors.text
+ color: palette.text
Layout.bottomMargin: Nheko.paddingMedium
}
TabBar {
id: bar
width: parent.width
- palette: Nheko.colors
NhekoTabButton {
text: qsTr("Roles")
@@ -60,7 +59,7 @@ ApplicationWindow {
Rectangle {
Layout.fillWidth: true
Layout.fillHeight: true
- color: Nheko.colors.alternateBase
+ color: palette.alternateBase
border.width: 1
border.color: Nheko.theme.separator
@@ -78,7 +77,7 @@ ApplicationWindow {
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 1.1)
Layout.fillWidth: true
Layout.fillHeight: false
- color: Nheko.colors.text
+ color: palette.text
}
ReorderableListview {
@@ -91,7 +90,7 @@ ApplicationWindow {
Column {
Layout.fillWidth: true
- Text { visible: model.isType; text: model.displayName; color: Nheko.colors.text}
+ Text { visible: model.isType; text: model.displayName; color: palette.text}
Text {
visible: !model.isType;
text: {
@@ -104,7 +103,7 @@ ApplicationWindow {
else
return qsTr("Custom (%1)").arg(model.powerlevel)
}
- color: Nheko.colors.text
+ color: palette.text
}
}
@@ -137,7 +136,7 @@ ApplicationWindow {
z: 5
visible: false
- color: Nheko.colors.text
+ color: palette.text
Keys.onPressed: {
if (typeEntry.text.includes('.') && event.matches(StandardKey.InsertParagraphSeparator)) {
@@ -166,7 +165,7 @@ ApplicationWindow {
anchors.fill: parent
visible: false
- color: Nheko.colors.alternateBase
+ color: palette.alternateBase
RowLayout {
spacing: Nheko.paddingMedium
@@ -238,7 +237,7 @@ ApplicationWindow {
width: parent.width
//font.pixelSize: Math.ceil(quickSwitcher.textHeight * 0.6)
- color: Nheko.colors.text
+ color: palette.text
onTextEdited: {
userCompleter.completer.searchString = text;
}
@@ -318,11 +317,11 @@ ApplicationWindow {
if (model.isUser)
return model.avatarUrl.replace("mxc://", "image://MxcImage/")
else if (editingModel.adminLevel >= model.powerlevel)
- return "image://colorimage/:/icons/icons/ui/ribbon_star.svg?" + Nheko.colors.buttonText;
+ return "image://colorimage/:/icons/icons/ui/ribbon_star.svg?" + palette.buttonText;
else if (editingModel.moderatorLevel >= model.powerlevel)
- return "image://colorimage/:/icons/icons/ui/ribbon.svg?" + Nheko.colors.buttonText;
+ return "image://colorimage/:/icons/icons/ui/ribbon.svg?" + palette.buttonText;
else
- return "image://colorimage/:/icons/icons/ui/person.svg?" + Nheko.colors.buttonText;
+ return "image://colorimage/:/icons/icons/ui/person.svg?" + palette.buttonText;
}
displayName: model.displayName
enabled: false
@@ -330,8 +329,8 @@ ApplicationWindow {
Column {
Layout.fillWidth: true
- Text { visible: model.isUser; text: model.displayName; color: Nheko.colors.text}
- Text { visible: model.isUser; text: model.mxid; color: Nheko.colors.text}
+ Text { visible: model.isUser; text: model.displayName; color: palette.text}
+ Text { visible: model.isUser; text: model.mxid; color: palette.text}
Text {
visible: !model.isUser;
text: {
@@ -342,7 +341,7 @@ ApplicationWindow {
else
return qsTr("Custom (%1)").arg(model.powerlevel)
}
- color: Nheko.colors.text
+ color: palette.text
}
}
diff --git a/resources/qml/dialogs/PowerLevelSpacesApplyDialog.qml b/resources/qml/dialogs/PowerLevelSpacesApplyDialog.qml
index e66f92a2..3f816143 100644
--- a/resources/qml/dialogs/PowerLevelSpacesApplyDialog.qml
+++ b/resources/qml/dialogs/PowerLevelSpacesApplyDialog.qml
@@ -21,8 +21,7 @@ ApplicationWindow {
minimumHeight: 450
width: 450
height: 680
- palette: Nheko.colors
- color: Nheko.colors.window
+ color: palette.window
modality: Qt.NonModal
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
title: qsTr("Apply permission changes")
@@ -43,7 +42,7 @@ ApplicationWindow {
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 1.1)
Layout.fillWidth: true
Layout.fillHeight: false
- color: Nheko.colors.text
+ color: palette.text
Layout.bottomMargin: Nheko.paddingMedium
}
@@ -55,7 +54,7 @@ ApplicationWindow {
Label {
text: qsTr("Apply permissions recursively")
Layout.fillWidth: true
- color: Nheko.colors.text
+ color: palette.text
}
ToggleButton {
@@ -67,7 +66,7 @@ ApplicationWindow {
Label {
text: qsTr("Overwrite exisiting modifications in rooms")
Layout.fillWidth: true
- color: Nheko.colors.text
+ color: palette.text
}
ToggleButton {
@@ -103,7 +102,7 @@ ApplicationWindow {
Text {
Layout.fillWidth: true
text: model.displayName
- color: Nheko.colors.text
+ color: palette.text
textFormat: Text.PlainText
elide: Text.ElideRight
}
@@ -117,7 +116,7 @@ ApplicationWindow {
return qsTr("Permissions synchronized with community")
}
elide: Text.ElideRight
- color: Nheko.colors.buttonText
+ color: palette.buttonText
textFormat: Text.PlainText
}
}
diff --git a/resources/qml/dialogs/RawMessageDialog.qml b/resources/qml/dialogs/RawMessageDialog.qml
index ef7159cb..a27d988e 100644
--- a/resources/qml/dialogs/RawMessageDialog.qml
+++ b/resources/qml/dialogs/RawMessageDialog.qml
@@ -13,8 +13,7 @@ ApplicationWindow {
height: 420
width: 420
- palette: Nheko.colors
- color: Nheko.colors.window
+ color: palette.window
flags: Qt.Tool | Qt.WindowStaysOnTopHint | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
Shortcut {
@@ -25,14 +24,13 @@ ApplicationWindow {
ScrollView {
anchors.margins: Nheko.paddingMedium
anchors.fill: parent
- palette: Nheko.colors
padding: Nheko.paddingMedium
TextArea {
id: rawMessageView
font: Nheko.monospaceFont()
- color: Nheko.colors.text
+ color: palette.text
readOnly: true
selectByMouse: !Settings.mobileMode
textFormat: Text.PlainText
@@ -40,7 +38,7 @@ ApplicationWindow {
anchors.fill: parent
background: Rectangle {
- color: Nheko.colors.base
+ color: palette.base
}
}
diff --git a/resources/qml/dialogs/ReadReceipts.qml b/resources/qml/dialogs/ReadReceipts.qml
index 3d23a5fc..83b8b8af 100644
--- a/resources/qml/dialogs/ReadReceipts.qml
+++ b/resources/qml/dialogs/ReadReceipts.qml
@@ -18,8 +18,7 @@ ApplicationWindow {
width: 340
minimumHeight: 380
minimumWidth: headerTitle.width + 2 * Nheko.paddingMedium
- palette: Nheko.colors
- color: Nheko.colors.window
+ color: palette.window
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
Shortcut {
@@ -35,14 +34,13 @@ ApplicationWindow {
Label {
id: headerTitle
- color: Nheko.colors.text
+ color: palette.text
Layout.alignment: Qt.AlignCenter
text: qsTr("Read receipts")
font.pointSize: fontMetrics.font.pointSize * 1.5
}
ScrollView {
- palette: Nheko.colors
padding: Nheko.paddingMedium
ScrollBar.horizontal.visible: false
Layout.fillHeight: true
@@ -67,7 +65,7 @@ ApplicationWindow {
ToolTip.visible: hovered
ToolTip.text: model.mxid
background: Rectangle {
- color: del.hovered ? Nheko.colors.dark : readReceiptsRoot.color
+ color: del.hovered ? palette.dark : readReceiptsRoot.color
}
RowLayout {
@@ -94,7 +92,7 @@ ApplicationWindow {
ElidedLabel {
text: model.displayName
- color: TimelineManager.userColor(model ? model.mxid : "", Nheko.colors.window)
+ color: TimelineManager.userColor(model ? model.mxid : "", palette.window)
font.pointSize: fontMetrics.font.pointSize
elideWidth: del.width - Nheko.paddingMedium - avatar.width
Layout.fillWidth: true
@@ -102,7 +100,7 @@ ApplicationWindow {
ElidedLabel {
text: model.timestamp
- color: Nheko.colors.buttonText
+ color: palette.buttonText
font.pointSize: fontMetrics.font.pointSize * 0.9
elideWidth: del.width - Nheko.paddingMedium - avatar.width
Layout.fillWidth: true
diff --git a/resources/qml/dialogs/RoomDirectory.qml b/resources/qml/dialogs/RoomDirectory.qml
index 85de9b45..29adb9be 100644
--- a/resources/qml/dialogs/RoomDirectory.qml
+++ b/resources/qml/dialogs/RoomDirectory.qml
@@ -18,8 +18,7 @@ ApplicationWindow {
minimumHeight: 340
height: 420
width: 650
- palette: Nheko.colors
- color: Nheko.colors.window
+ color: palette.window
modality: Qt.NonModal
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
title: qsTr("Explore Public Rooms")
@@ -43,9 +42,9 @@ ApplicationWindow {
delegate: Rectangle {
id: roomDirDelegate
- property color background: Nheko.colors.window
- property color importantText: Nheko.colors.text
- property color unimportantText: Nheko.colors.buttonText
+ property color background: palette.window
+ property color importantText: palette.text
+ property color unimportantText: palette.buttonText
property int avatarSize: fontMetrics.height * 3.2
color: background
@@ -143,7 +142,7 @@ ApplicationWindow {
anchors.centerIn: parent
anchors.margins: Nheko.paddingLarge
running: visible
- foreground: Nheko.colors.mid
+ foreground: palette.mid
}
}
@@ -164,7 +163,7 @@ ApplicationWindow {
Layout.fillWidth: true
selectByMouse: true
font.pixelSize: fontMetrics.font.pixelSize
- color: Nheko.colors.text
+ color: palette.text
placeholderText: qsTr("Search for public rooms")
onTextChanged: searchTimer.restart()
@@ -176,7 +175,7 @@ ApplicationWindow {
Layout.minimumWidth: 0.3 * header.width
Layout.maximumWidth: 0.3 * header.width
- color: Nheko.colors.text
+ color: palette.text
placeholderText: qsTr("Choose custom homeserver")
onTextChanged: publicRooms.setMatrixServer(text)
}
diff --git a/resources/qml/dialogs/RoomMembers.qml b/resources/qml/dialogs/RoomMembers.qml
index 1cfbe077..4952a0a9 100644
--- a/resources/qml/dialogs/RoomMembers.qml
+++ b/resources/qml/dialogs/RoomMembers.qml
@@ -20,8 +20,7 @@ ApplicationWindow {
height: 650
width: 420
minimumHeight: 420
- palette: Nheko.colors
- color: Nheko.colors.window
+ color: palette.window
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
Shortcut {
@@ -77,7 +76,7 @@ ApplicationWindow {
Label {
text: qsTr("Sort by: ")
- color: Nheko.colors.text
+ color: palette.text
}
ComboBox {
@@ -94,7 +93,6 @@ ApplicationWindow {
}
ScrollView {
- palette: Nheko.colors
padding: Nheko.paddingMedium
ScrollBar.horizontal.visible: false
Layout.fillHeight: true
@@ -123,7 +121,7 @@ ApplicationWindow {
height: memberLayout.implicitHeight + Nheko.paddingSmall * 2
hoverEnabled: true
background: Rectangle {
- color: del.hovered ? Nheko.colors.dark : roomMembersRoot.color
+ color: del.hovered ? palette.dark : roomMembersRoot.color
}
RowLayout {
@@ -158,7 +156,7 @@ ApplicationWindow {
ElidedLabel {
fullText: model.mxid
- color: del.hovered ? Nheko.colors.brightText : Nheko.colors.buttonText
+ color: del.hovered ? palette.brightText : palette.buttonText
font.pixelSize: Math.ceil(fontMetrics.font.pixelSize * 0.9)
elideWidth: del.width - Nheko.paddingMedium * 2 - avatar.width - encryptInd.width
Layout.fillWidth: true
@@ -184,7 +182,7 @@ ApplicationWindow {
Layout.preferredHeight: 16
sourceSize.width: width
sourceSize.height: height
- source: sourceUrl + (ma.hovered ? Nheko.colors.highlight : Nheko.colors.buttonText)
+ source: sourceUrl + (ma.hovered ? palette.highlight : palette.buttonText)
ToolTip.visible: ma.hovered
ToolTip.text: {
if (isAdmin)
diff --git a/resources/qml/dialogs/RoomSettings.qml b/resources/qml/dialogs/RoomSettings.qml
index 845f4d7a..6bc24058 100644
--- a/resources/qml/dialogs/RoomSettings.qml
+++ b/resources/qml/dialogs/RoomSettings.qml
@@ -20,8 +20,7 @@ ApplicationWindow {
minimumHeight: 450
width: 450
height: 680
- palette: Nheko.colors
- color: Nheko.colors.window
+ color: palette.window
modality: Qt.NonModal
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
title: qsTr("Room Settings")
@@ -79,7 +78,7 @@ ApplicationWindow {
Spinner {
Layout.alignment: Qt.AlignHCenter
visible: roomSettings.isLoading
- foreground: Nheko.colors.mid
+ foreground: palette.mid
running: roomSettings.isLoading
}
@@ -130,7 +129,7 @@ ApplicationWindow {
textFormat: isNameEditingAllowed ? TextEdit.PlainText : TextEdit.RichText
text: isNameEditingAllowed ? roomSettings.plainRoomName : roomSettings.roomName
font.pixelSize: fontMetrics.font.pixelSize * 2
- color: Nheko.colors.text
+ color: palette.text
Layout.alignment: Qt.AlignHCenter
Layout.maximumWidth: parent.width - (Nheko.paddingSmall * 2) - nameChangeButton.anchors.leftMargin - (nameChangeButton.width * 2)
@@ -178,7 +177,7 @@ ApplicationWindow {
Label {
text: qsTr("%n member(s)", "", roomSettings.memberCount)
- color: Nheko.colors.text
+ color: palette.text
}
ImageButton {
@@ -213,7 +212,7 @@ ApplicationWindow {
wrapMode: TextEdit.WordWrap
background: null
selectByMouse: !Settings.mobileMode
- color: Nheko.colors.text
+ color: palette.text
horizontalAlignment: TextEdit.AlignHCenter
onLinkActivated: Nheko.openLink(link)
@@ -263,7 +262,7 @@ ApplicationWindow {
Label {
text: qsTr("SETTINGS")
font.bold: true
- color: Nheko.colors.text
+ color: palette.text
}
Item {
@@ -273,7 +272,7 @@ ApplicationWindow {
Label {
text: qsTr("Notifications")
Layout.fillWidth: true
- color: Nheko.colors.text
+ color: palette.text
}
ComboBox {
@@ -289,7 +288,7 @@ ApplicationWindow {
Label {
text: qsTr("Anyone can join")
Layout.fillWidth: true
- color: Nheko.colors.text
+ color: palette.text
}
ToggleButton {
@@ -303,7 +302,7 @@ ApplicationWindow {
Label {
text: qsTr("Allow knocking")
Layout.fillWidth: true
- color: Nheko.colors.text
+ color: palette.text
visible: knockingButton.visible
}
@@ -322,7 +321,7 @@ ApplicationWindow {
Label {
text: qsTr("Allow joining via other rooms")
Layout.fillWidth: true
- color: Nheko.colors.text
+ color: palette.text
visible: restrictedButton.visible
}
@@ -341,7 +340,7 @@ ApplicationWindow {
Label {
text: qsTr("Rooms to join via")
Layout.fillWidth: true
- color: Nheko.colors.text
+ color: palette.text
visible: allowedRoomsButton.visible
}
@@ -360,7 +359,7 @@ ApplicationWindow {
Label {
text: qsTr("Allow guests to join")
Layout.fillWidth: true
- color: Nheko.colors.text
+ color: palette.text
}
ToggleButton {
@@ -383,7 +382,7 @@ ApplicationWindow {
Label {
text: qsTr("Encryption")
- color: Nheko.colors.text
+ color: palette.text
}
ToggleButton {
@@ -422,7 +421,7 @@ ApplicationWindow {
Label {
text: qsTr("Permission")
- color: Nheko.colors.text
+ color: palette.text
}
Button {
@@ -434,7 +433,7 @@ ApplicationWindow {
Label {
text: qsTr("Aliases")
- color: Nheko.colors.text
+ color: palette.text
}
Button {
@@ -446,7 +445,7 @@ ApplicationWindow {
Label {
text: qsTr("Sticker & Emote Settings")
- color: Nheko.colors.text
+ color: palette.text
}
Button {
@@ -458,7 +457,7 @@ ApplicationWindow {
Label {
text: qsTr("Hidden events")
- color: Nheko.colors.text
+ color: palette.text
}
HiddenEventsDialog {
@@ -487,7 +486,7 @@ ApplicationWindow {
Label {
text: qsTr("INFO")
font.bold: true
- color: Nheko.colors.text
+ color: palette.text
}
Item {
@@ -496,7 +495,7 @@ ApplicationWindow {
Label {
text: qsTr("Internal ID")
- color: Nheko.colors.text
+ color: palette.text
}
AbstractButton { // AbstractButton does not allow setting text color
@@ -507,7 +506,7 @@ ApplicationWindow {
id: idLabel
text: roomSettings.roomId
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 0.8)
- color: Nheko.colors.text
+ color: palette.text
width: parent.width
horizontalAlignment: Text.AlignRight
wrapMode: Text.WrapAnywhere
@@ -531,14 +530,14 @@ ApplicationWindow {
Label {
text: qsTr("Room Version")
- color: Nheko.colors.text
+ color: palette.text
}
Label {
text: roomSettings.roomVersion
font.pixelSize: fontMetrics.font.pixelSize
Layout.alignment: Qt.AlignRight
- color: Nheko.colors.text
+ color: palette.text
}
}
diff --git a/resources/qml/dialogs/UserProfile.qml b/resources/qml/dialogs/UserProfile.qml
index 95800746..dae43caa 100644
--- a/resources/qml/dialogs/UserProfile.qml
+++ b/resources/qml/dialogs/UserProfile.qml
@@ -22,8 +22,7 @@ ApplicationWindow {
width: 420
minimumWidth: 150
minimumHeight: 150
- palette: Nheko.colors
- color: Nheko.colors.window
+ color: palette.window
title: profile.isGlobalUserProfile ? qsTr("Global User Profile") : qsTr("Room User Profile")
modality: Qt.NonModal
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
@@ -89,7 +88,7 @@ ApplicationWindow {
Layout.alignment: Qt.AlignHCenter
running: profile.isLoading
visible: profile.isLoading
- foreground: Nheko.colors.mid
+ foreground: palette.mid
}
Text {
@@ -137,7 +136,7 @@ ApplicationWindow {
readOnly: !isUsernameEditingAllowed
text: profile.displayName
font.pixelSize: 20
- color: TimelineManager.userColor(profile.userid, Nheko.colors.window)
+ color: TimelineManager.userColor(profile.userid, palette.window)
font.bold: true
Layout.alignment: Qt.AlignHCenter
Layout.maximumWidth: parent.width - (Nheko.paddingSmall * 2) - usernameChangeButton.anchors.leftMargin - (usernameChangeButton.width * 2)
@@ -315,7 +314,6 @@ ApplicationWindow {
onCurrentIndexChanged: devicelist.selectedTab = currentIndex
- palette: Nheko.colors
NhekoTabButton {
text: qsTr("Devices")
@@ -354,7 +352,7 @@ ApplicationWindow {
Layout.alignment: Qt.AlignLeft
elide: Text.ElideRight
font.bold: true
- color: Nheko.colors.text
+ color: palette.text
text: deviceId
}
@@ -400,7 +398,7 @@ ApplicationWindow {
readOnly: !deviceNameRow.isEditingAllowed
text: deviceName
- color: Nheko.colors.text
+ color: palette.text
Layout.alignment: Qt.AlignLeft
Layout.fillWidth: true
selectByMouse: true
@@ -435,7 +433,7 @@ ApplicationWindow {
Layout.fillWidth: true
Layout.alignment: Qt.AlignLeft
elide: Text.ElideRight
- color: Nheko.colors.text
+ color: palette.text
text: qsTr("Last seen %1 from %2").arg(new Date(lastTs).toLocaleString(Locale.ShortFormat)).arg(lastIp ? lastIp : "???")
}
@@ -504,7 +502,7 @@ ApplicationWindow {
ElidedLabel {
Layout.alignment: Qt.AlignVCenter
- color: Nheko.colors.text
+ color: palette.text
Layout.fillWidth: true
elideWidth: width
fullText: roomName
@@ -527,7 +525,7 @@ ApplicationWindow {
background: Rectangle {
anchors.fill: parent
- color: Nheko.colors.window
+ color: palette.window
}
}
|