From 9a7bbb3fec5fdcc29a9367ec0584acc13870af8c Mon Sep 17 00:00:00 2001 From: Sir Blob Date: Thu, 24 Sep 2026 02:23:05 +0000 Subject: [PATCH] Show the shipped chai icon when the user copy is missing --- packages/blob.packages | 1 + shell/plugins/menu/BarWidget.qml | 10 ++++++++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/packages/blob.packages b/packages/blob.packages index 4208955..7e944fb 100644 --- a/packages/blob.packages +++ b/packages/blob.packages @@ -18,6 +18,7 @@ xdg-desktop-portal-gtk gtk4-layer-shell qt6-wayland qt6-imageformats +qt6-svg wl-clipboard wtype socat diff --git a/shell/plugins/menu/BarWidget.qml b/shell/plugins/menu/BarWidget.qml index b14645b..7000aa9 100644 --- a/shell/plugins/menu/BarWidget.qml +++ b/shell/plugins/menu/BarWidget.qml @@ -8,7 +8,10 @@ BarWidget { id: root moduleName: "blob.menu" - readonly property string iconPath: Quickshell.env("HOME") + "/.config/blob/branding/chai.svg" + readonly property string userIconPath: Quickshell.env("HOME") + "/.config/blob/branding/chai.svg" + readonly property string shippedIconPath: Quickshell.env("BLOB_PATH") + "/branding/chai.svg" + property bool useShippedIcon: false + readonly property string iconPath: useShippedIcon ? shippedIconPath : userIconPath readonly property int iconSize: Math.round(Style.font.body * 1.35) property string iconSvg: "" @@ -33,7 +36,10 @@ BarWidget { watchChanges: true printErrors: false onLoaded: root.iconSvg = text() - onLoadFailed: root.iconSvg = "" + onLoadFailed: { + if (!root.useShippedIcon) root.useShippedIcon = true + else root.iconSvg = "" + } onFileChanged: reload() }