Fix dragging the reminder flyby plane on X11#47
Closed
yumiaura wants to merge 1 commit into
Closed
Conversation
The flyby is a frameless, full-width overlay that paints a click-through mask each frame so only the plane+flag absorbs clicks. On X11 the window manager was managing it: it shifted the overlay down by the panel height (geometry jumped from y=0 to y=26) and, worse, treated a body click-drag as "move the whole window" — so grabbing the plane only flipped the cursor to the move shape while the plane never followed the drag (the WM swallowed the motion events). - Add Qt.X11BypassWindowManagerHint on xcb so the X server delivers the drag straight to us and the overlay stays glued to (0, 0). - Grow the plane/cat hit region by a few px (grow_region / GRAB_GROW_PX) so the moving plane is an easy target in the no-compositor silhouette path; the flag, pole and rope stay crisp. No effect with a compositor (that path already uses a generous bounding box).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The reminder flyby (cat-on-a-plane banner) couldn't be dragged during flight on X11. Reported symptom: "the cursor changes to the move shape but the plane stays in place."
Root cause: the flyby is a frameless, full-screen-width overlay that paints a click-through mask each frame. On X11 the window manager was managing this overlay — it shifted it down by the panel height (geometry jumped from
y=0toy=26) and treated a body click-drag as a "move the whole window" gesture. So pressing the plane flipped the cursor to the move shape, but the WM swallowed the motion and the plane never followed.The drag code itself was never broken (verified: a directly-delivered press→move→release updates the offset correctly).
Changes
X11BypassWindowManagerHinton xcb — the X server now delivers the drag straight to the overlay, and it stays glued to(0, 0)(no more panel-height shift). This is the actual fix for the reported symptom.grow_region/GRAB_GROW_PX=5) — on no-compositor sessions the overlay is clipped to its tight silhouette, so a moving plane is a painfully thin click target. The plane/cat hit region is now dilated a few px; the flag, pole and rope stay crisp. No effect when a compositor is present (that path already uses a generous bounding box).Verification
ruff check .— cleanpytest -q— 41 passed (offscreen):0X11 session: overlay geometry is now(0, 0)(was(0, 26)); renders correctly with no black box; drag offset updates on a delivered drag.