From f52fb9bd9ee73d785c5a7141c1924a89e05f212a Mon Sep 17 00:00:00 2001 From: 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com> Date: Sat, 23 Aug 2025 16:53:15 +1000 Subject: launcher: show current scheme/variant Also qsTr variant stuff --- modules/launcher/items/SchemeItem.qml | 29 +++++++++++++++++++++-------- 1 file changed, 21 insertions(+), 8 deletions(-) (limited to 'modules/launcher/items/SchemeItem.qml') diff --git a/modules/launcher/items/SchemeItem.qml b/modules/launcher/items/SchemeItem.qml index 8cc2e33..f2246dc 100644 --- a/modules/launcher/items/SchemeItem.qml +++ b/modules/launcher/items/SchemeItem.qml @@ -67,25 +67,38 @@ Item { anchors.leftMargin: Appearance.spacing.normal anchors.verticalCenter: parent.verticalCenter - width: parent.width - preview.width + width: parent.width - preview.width - anchors.leftMargin - (current.active ? current.width + Appearance.spacing.normal : 0) spacing: 0 StyledText { - id: name - - text: root.modelData?.name ?? "" + text: root.modelData?.flavour ?? "" font.pointSize: Appearance.font.size.normal } StyledText { - id: comment - - text: root.modelData?.flavour ?? "" + text: root.modelData?.name ?? "" font.pointSize: Appearance.font.size.small color: Colours.palette.m3outline elide: Text.ElideRight - width: parent.width - Appearance.rounding.normal * 2 + anchors.left: parent.left + anchors.right: parent.right + } + } + + Loader { + id: current + + anchors.right: parent.right + anchors.verticalCenter: parent.verticalCenter + + active: `${root.modelData?.name} ${root.modelData?.flavour}` === Schemes.currentScheme + asynchronous: true + + sourceComponent: MaterialIcon { + text: "check" + color: Colours.palette.m3onSurfaceVariant + font.pointSize: Appearance.font.size.large } } } -- cgit v1.2.3-freya