From 68281b0874abfe1db751d998aaf2d81a5ce87d97 Mon Sep 17 00:00:00 2001 From: mx Date: Sun, 29 Nov 2026 14:41:28 +0100 Subject: [PATCH] Let plugins drop their bar pill with a "background" setting A plugin bar widget whose settings say background: "transparent" sits straight on the bar, like the tray's transparent background. Co-Authored-By: Claude Opus 5.5 --- quickshell/bar/modules/PluginModule.qml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/quickshell/bar/modules/PluginModule.qml b/quickshell/bar/modules/PluginModule.qml index 49af3b5..324db17 100644 --- a/quickshell/bar/modules/PluginModule.qml +++ b/quickshell/bar/modules/PluginModule.qml @@ -23,6 +23,12 @@ GlassPill { // Omarchy widgets report emptiness through hasVisualContent instead. readonly property var widgetObject: loader.item readonly property bool shown: !!widget && (noctalia || widgetObject.hasVisualContent !== false) && widget.implicitWidth > 0 + // A plugin can offer a "background" setting; "transparent" drops the + // pill so its widget sits straight on the bar, like the tray's option. + readonly property bool bare: settings.background === "transparent" + color: bare ? "transparent" : Qt.alpha(Theme.surface, surfaceOpacity) + border.width: bare ? 0 : 1 + plain: bare implicitHeight: ModuleRegistry.pillHeight implicitWidth: shown ? Math.ceil(widget.implicitWidth) + 8 : 0 visible: implicitWidth > 0