explicitly set colours for header items

the _Universal_ theme notably sets [`icon.color` on `Button`s][0] and
also the [`color` on `Label`s][1], ignoring what's set through the
`palette` property ...

[0]: 215619d71b/src/quickcontrols/universal/Button.qml (L23)
[1]: 215619d71b/src/quickcontrols/universal/Label.qml (L12)

Signed-off-by: Jyrki Gadinger <nilsding@nilsding.org>
This commit is contained in:
Jyrki Gadinger 2025-03-19 10:31:47 +01:00 committed by backportbot[bot]
parent 39f949d04a
commit fa5d3bc2f6
2 changed files with 5 additions and 0 deletions

View File

@ -198,6 +198,7 @@ Button {
id: currentAccountUser
Layout.alignment: Qt.AlignLeft | Qt.AlignBottom
width: Style.currentAccountLabelWidth
color: palette.windowText
text: UserModel.currentUser ? UserModel.currentUser.name : ""
elide: Text.ElideRight
@ -209,6 +210,7 @@ Button {
id: currentAccountServer
Layout.alignment: Qt.AlignLeft | Qt.AlignBottom
width: Style.currentAccountLabelWidth
color: palette.windowText
text: UserModel.currentUser ? UserModel.currentUser.server : ""
elide: Text.ElideRight
visible: UserModel.numUsers() > 1
@ -225,6 +227,7 @@ Button {
id: emoji
visible: UserModel.currentUser && UserModel.currentUser.statusEmoji !== ""
width: Style.userStatusEmojiSize
color: palette.windowText
text: UserModel.currentUser ? UserModel.currentUser.statusEmoji : ""
}
EnforcedPlainTextLabel {
@ -233,6 +236,7 @@ Button {
Layout.fillWidth: true
visible: UserModel.currentUser && UserModel.currentUser.statusMessage !== ""
width: Style.currentAccountLabelWidth
color: palette.windowText
text: UserModel.currentUser && UserModel.currentUser.statusMessage !== ""
? UserModel.currentUser.statusMessage
: UserModel.currentUser ? UserModel.currentUser.server : ""

View File

@ -32,6 +32,7 @@ Button {
icon.width: Style.headerButtonIconSize
icon.height: Style.headerButtonIconSize
icon.color: "transparent"
Layout.alignment: Qt.AlignRight
Layout.preferredWidth: Style.trayWindowHeaderHeight