Desktop: Enable window resize controls on Wayland compositors #3183
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.
Needs #3177
Closes #3189 (needs testing on X11 #3190)
This PR adds support for window resize controls on Wayland compositors that allow disabling the standard server-side window frame (i.e., when client-side decorations are enabled).
Resize controls: Implemented for all compositors that support client-side decorations.
Fallback behavior: On compositors that force server-side decorations (e.g. tiling WMs like Hyprland, Sway, etc.), we skip drawing resize borders and shadows. Since these would otherwise render inside the compositor’s frame, we delegate resizing entirely to the compositor.
No duplicate titlebars: In testing, compositors either support client-side decorations or omit drawing their own titlebar. This ensures we don’t end up with a double titlebar when rendering our own decorations.
Note: This relies on two pending PRs in winit. Until they are merged, we temporarily depend on my fork of winit.
rust-windowing/winit#4357
rust-windowing/winit#4361
2025-09-16.12-31-58.mp4