Add allOutputs option to window switcher

Introduces a new configuration option for the window switcher
that allows users to filter windows by output (monitor).

Changes:
- Added `allOutputs` attribute to <windowSwitcher>
  - Default is "no" (only shows windows on the cursor's output)
  - When set to "yes", shows windows from all outputs

- Introduced LAB_VIEW_CRITERIA_CURSOR_OUTPUT flag to filter views by output
  - Windows are matched against the output nearest to the cursor
  - Bit positions of existing criteria flags shifted to accommodate new flag

- Modified OSD display behavior to show only on the cursor's output
  - Previously, the OSD would appear on all outputs simultaneously
  - Now displays only on the output nearest to the cursor location

This provides better multi-monitor support by allowing users to focus on
windows relevant to their current screen, reducing visual clutter when
working across multiple displays.
This commit is contained in:
Samet Aylak 2025-11-02 08:54:29 -05:00
parent 0f62648d39
commit 764cd942eb
No known key found for this signature in database
GPG key ID: E5DEF544B937EE49
6 changed files with 43 additions and 16 deletions

View file

@ -78,7 +78,7 @@
</theme>
<windowSwitcher show="yes" style="classic" preview="yes"
outlines="yes" allWorkspaces="no" unshade="yes">
outlines="yes" allWorkspaces="no" allOutputs="no" unshade="yes">
<fields>
<field content="icon" width="5%" />
<field content="desktop_entry_name" width="30%" />
@ -98,7 +98,7 @@
Some contents are fixed-length and others are variable-length.
See "man 5 labwc-config" for details.
<windowSwitcher show="yes" preview="no" outlines="no" allWorkspaces="yes">
<windowSwitcher show="yes" preview="no" outlines="no" allWorkspaces="yes" allOutputs="no">
<fields>
<field content="workspace" width="5%" />
<field content="state" width="3%" />
@ -118,7 +118,7 @@
then workspace name, then identifier/app-id, then the window title.
It uses 100% of OSD window width.
<windowSwitcher show="yes" preview="no" outlines="no" allWorkspaces="yes">
<windowSwitcher show="yes" preview="no" outlines="no" allWorkspaces="yes" allOutputs="no">
<fields>
<field content="custom" format="foobar %b %3s %-10o %-20W %-10i %t" width="100%" />
</fields>