m_monitor is a WP<CMonitor> (weak_ptr). In onUnmap(), calling
m_monitor->activeWorkspaceID() without .lock() causes SIGABRT when
the monitor has been destroyed before the XWayland unmap event
arrives, e.g. when a window on a special workspace is unmapped.
* input: implement follow_mouse_shrink
Add a new config option `input:follow_mouse_shrink` (INT, 0-300, default 0)
that shrinks inactive window hitboxes by the specified number of pixels for
focus detection purposes. This creates a dead zone in gaps between windows
where moving the cursor will not trigger a focus change.
The shrink only applies to inactive (non-focused) windows and only during
mouse-move focus checks (follow_mouse = 1). Click and scroll interactions
are unaffected — clicking on a window in the shrunk area still works
normally once the window is focused.
Closes#9973
* tests: add integration test for follow_mouse_shrink
* subsurface: use geometry-aware damage and recurse into nested trees
Replace per-surface damageSurface() calls in recheckDamageForSubsurfaces()
with box-based damage that tracks each subsurface's last known global
position and size. When geometry changes, both the old and new areas are
damaged to correctly clear stale pixels and paint the new location.
Additionally, recurse into child subsurfaces so that nested subsurface
trees are properly damage-checked, with a depth limit of 32 to guard
against cycles. Cached geometry is invalidated on map/unmap to avoid
stale comparisons across surface lifecycle transitions.
* clang-format
* xwayland: prefer monitor-aware hover coords
Introduce monitor-aware XWayland coordinate helpers and keep the X11 hover path anchored to the main surface box while preserving detailed debug logging, reducing dependence on nearest-monitor guesses in layout-sensitive input paths.
* xwayland: use window monitor for reported coords
Report X11 window positions through the window's known monitor instead of the generic nearest-monitor heuristic so boundary-aligned outputs keep stable XWayland coordinates.
* xwayland: use window monitor for real position restore
Convert XWayland geometry back into compositor space using the window's current monitor when available so vertically offset layouts do not round-trip through the wrong output.
* xwayland: use window monitor for unmanaged geometry
Restore override-redirect X11 geometry through the window's known monitor so helper windows and popups avoid nearest-monitor misclassification on offset layouts.
* xwayland: remove monitor conversion debug logging
Drop the temporary XWayland hover and coordinate conversion diagnostics now that the monitor-selection bug is confirmed and the window-monitor based conversions fix the issue.
* xwayland: drop unrelated focused-motion change
Remove the exploratory X11-specific pointer focus scaling from InputManager so the monitor mapping fix stays narrowly scoped to the XWayland coordinate conversion changes that actually resolve the bug.
* clang-format XWaylandManager
* view: consolidate group flags and apply window rules
Replace individual boolean flags with a bitmask for group policies and ensure that window-specific group rules are correctly inherited when windows are initialized or added to a group.
* tests: add cases for locked groups and invade rule
Add tests to verify window grouping behavior, specifically checking that locked groups prevent merging by default and that the 'invade' group rule correctly overrides this lock policy.
m_alpha was freed by fullyDestroy, but was then being touched because setCallbackOnEnd is activated by tick, which is the same function that updates animating variables
---------
Co-authored-by: Vaxry <vaxry@vaxry.net>
Rewrites layouts to be much smaller, and deal with much less annoying
BS. Improves the overall architecture, unifies handling of pseudotiling,
and various other improvements.
* fix: track explicit workspace assignments to prevent X11 configure overwrites
Instead of only checking for special workspaces, track when workspaces are
explicitly assigned via window rules or user actions (movetoworkspace).
This prevents onX11ConfigureRequest from overwriting any explicit workspace
assignment based on window position.
Changes:
- Add m_workspaceExplicitlyAssigned flag to CWindow
- Set flag when window rules assign workspace
- Set flag when user moves window via dispatcher
- Check flag in onX11ConfigureRequest instead of just special workspace
- Add debug logging for explicit workspace assignments
* fix: simplify X11 configure request handling for special workspaces
X11 apps send configure requests with positions based on XWayland's
monitor layout, which could incorrectly move windows off special
workspaces.
Skip workspace reassignment when the window is on a special workspace
or staying on the same monitor, but always run z-order, fullscreen flag,
and damage logic since the configure request may include geometry changes.