shift-shell/containments/homescreens/folio/qml/settings/SettingsButton.qml
Marco Allegretti a3173160e2 Render shell-owned icons with theme masks
Use masked Kirigami icons with explicit theme colors for shell controls so the Shift icon theme renders reliably across light and dark surfaces. Replace the status-bar battery helper with theme icon names so battery glyphs also come from org.shift.icons.

Give the app-thumbnail close affordance a symbolic white X on a dark circular backing so it remains visible over previews.
2026-05-17 08:57:06 +02:00

44 lines
1.2 KiB
QML

// SPDX-FileCopyrightText: 2025 Florian Richer <florian.richer@protonmail.com>
// SPDX-License-Identifier: LGPL-2.0-or-later
import QtQuick
import QtQuick.Layouts
import QtQuick.Controls as QQC2
import org.kde.plasma.components as PC3
import org.kde.kirigami as Kirigami
PC3.ToolButton {
id: root
opacity: 0.9
implicitHeight: Kirigami.Units.gridUnit * 4
implicitWidth: Kirigami.Units.gridUnit * 5
property string iconName
property string textLabel
contentItem: ColumnLayout {
spacing: Kirigami.Units.largeSpacing
uniformCellSizes: true
Kirigami.Icon {
Layout.alignment: Qt.AlignVCenter | Qt.AlignHCenter
implicitWidth: Kirigami.Units.iconSizes.smallMedium
implicitHeight: Kirigami.Units.iconSizes.smallMedium
Layout.fillHeight: true
source: iconName
isMask: true
color: Kirigami.Theme.textColor
}
QQC2.Label {
horizontalAlignment: Text.AlignHCenter
verticalAlignment: Text.AlignTop
text: textLabel
font.bold: true
Layout.fillWidth: true
Layout.fillHeight: true
wrapMode: Text.WordWrap
}
}
}