From 1904ced6793e3a99f7272ad513cc6200afc31448 Mon Sep 17 00:00:00 2001 From: nico Date: Fri, 11 Sep 2026 20:57:10 +0200 Subject: [PATCH] Filter out IME popup toplevels from the window switcher too Same fix as the taskbar: Hyprland.toplevels includes fcitx's "Input" / "Default IME" popups, which don't appear in hyprctl clients and don't get a real workspace assigned. Filter on that here as well. Co-Authored-By: Claude Sonnet 5 Claude-Session: https://claude.ai/code/session_01Dujsk9jYfxUVLtb5B8eC94 --- quickshell/default/Bar.qml | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/quickshell/default/Bar.qml b/quickshell/default/Bar.qml index da50e93..e8c547a 100644 --- a/quickshell/default/Bar.qml +++ b/quickshell/default/Bar.qml @@ -1407,6 +1407,13 @@ Variants { WlrLayershell.namespace: "window-switcher" WlrLayershell.layer: WlrLayer.Top + // Hyprland.toplevels includes things hyprctl clients doesn't + // (e.g. fcitx's "Input" / "Default IME" popups) - those never + // get a real workspace assigned, unlike genuine windows. + readonly property var filteredToplevels: Hyprland.toplevels.values.filter(function (tl) { + return tl.workspace !== null + }) + HyprlandFocusGrab { windows: [ winSwitchPopup ] active: true @@ -1427,7 +1434,7 @@ Variants { spacing: 2 Text { - visible: Hyprland.toplevels.values.length === 0 + visible: winSwitchPopup.filteredToplevels.length === 0 text: root.isGerman ? "Keine Fenster ge\u00f6ffnet" : "No open windows" font.family: "JetBrainsMono Nerd Font" font.pixelSize: 12 @@ -1435,7 +1442,7 @@ Variants { } Repeater { - model: Hyprland.toplevels + model: winSwitchPopup.filteredToplevels Rectangle { id: winRow