From c520a8e96089b9df24d6d36b6cf1d04ef76bc605 Mon Sep 17 00:00:00 2001 From: Marco Allegretti Date: Mon, 27 Apr 2026 14:28:21 +0200 Subject: [PATCH] Use system theme colors in app drawer and dock Remove hardcoded Complementary override and white color literals from AppDrawerHeader. In mobile mode the Plasma containment framework already provides Complementary context; in convergence mode the drawerOverlay Window starts a fresh Window context. Both cases now propagate correctly without an explicit override. Also set Kirigami.Theme.Window on the convergence dock FavouritesBar so icon labels and hover highlights follow the active system palette instead of the wallpaper context. --- .../homescreens/folio/qml/AppDrawerHeader.qml | 16 ++++++++-------- containments/homescreens/folio/qml/main.qml | 5 +++++ 2 files changed, 13 insertions(+), 8 deletions(-) diff --git a/containments/homescreens/folio/qml/AppDrawerHeader.qml b/containments/homescreens/folio/qml/AppDrawerHeader.qml index 60268ad8..9dfd495c 100644 --- a/containments/homescreens/folio/qml/AppDrawerHeader.qml +++ b/containments/homescreens/folio/qml/AppDrawerHeader.qml @@ -15,8 +15,9 @@ Item { id: root property Folio.HomeScreen folio - Kirigami.Theme.colorSet: Kirigami.Theme.Complementary - Kirigami.Theme.inherit: false + // Do not override the colorset: in mobile mode we inherit Complementary + // from the containment (wallpaper context, white text); in convergence mode + // the drawerOverlay Window gives us Window context (system-adaptive). function addSearchText(text: string) { searchField.text += text; @@ -57,22 +58,21 @@ Item { background: Rectangle { radius: Kirigami.Units.cornerRadius - color: Qt.rgba(255, 255, 255, (searchField.hovered || searchField.focus) ? 0.2 : 0.1) + color: Qt.rgba(Kirigami.Theme.textColor.r, Kirigami.Theme.textColor.g, + Kirigami.Theme.textColor.b, + (searchField.hovered || searchField.focus) ? 0.2 : 0.1) Behavior on color { ColorAnimation {} } } - Kirigami.Theme.inherit: false - Kirigami.Theme.colorSet: Kirigami.Theme.Complementary - topPadding: Kirigami.Units.largeSpacing + Kirigami.Units.smallSpacing bottomPadding: Kirigami.Units.largeSpacing + Kirigami.Units.smallSpacing Layout.fillWidth: true horizontalAlignment: QQC2.TextField.AlignHCenter placeholderText: i18nc("@info:placeholder", "Search applications…") - placeholderTextColor: Qt.rgba(255, 255, 255, 0.8) - color: 'white' + placeholderTextColor: Kirigami.Theme.disabledTextColor + color: Kirigami.Theme.textColor font.weight: Font.Bold diff --git a/containments/homescreens/folio/qml/main.qml b/containments/homescreens/folio/qml/main.qml index 1c8de4f0..8bc812ae 100644 --- a/containments/homescreens/folio/qml/main.qml +++ b/containments/homescreens/folio/qml/main.qml @@ -366,6 +366,11 @@ ContainmentItem { maskManager: root.maskManager homeScreen: folioHomeScreen transform: Translate { y: dockOverlay.dockOffset } + // Dock is an opaque panel — use Window colorset so all content + // (labels, hover highlights, icon tints) follows the system theme + // instead of the containment's Complementary wallpaper context. + Kirigami.Theme.inherit: false + Kirigami.Theme.colorSet: Kirigami.Theme.Window } }