feat: add --disable-csd and --disable-transparency for Wayland - #1
Merged
Conversation
On Wayland, WebKitGTK cannot composite an alpha surface, and GTK CSD renders as a black bar. These flags rewrite the window config before the webview is created. --disable-csd also sets GTK_CSD=0 before gtk_init.
3xian
approved these changes
Sep 2, 2026
3xian
left a comment
Owner
There was a problem hiding this comment.
The implementation is focused and safe: it rewrites Tauri's window config before webview creation, preserves existing defaults without flags, and has direct tests for parsing and config mutation. Local full checks and a launched-app smoke test pass. Non-blocking wording note: Wayland surfaces can carry alpha, and GTK_CSD=0 only disables GTK's default CSD (Tao 0.35 installs a custom titlebar); describing these as compositor/WebKitGTK compatibility workarounds would be more precise. The effective behavior still comes from decorations=false and transparent=false before window creation.
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.
On Wayland (niri, Sway, Hyprland, and similar), PinkCode's default acrylic + Overlay CSD chrome does not work:
These flags rewrite the window config before the webview is created (transparency cannot be changed after).
--disable-csdalso setsGTK_CSD=0beforegtk_init.macOS and Windows keep the existing Overlay / acrylic defaults unless the flags are passed.
Tested: unit tests for parse + config rewrite. I could not run a full Tauri Linux build in this environment (missing dbus for the GTK stack). Visual check is on niri with the same window settings we already use locally.