Environment
- OS: CachyOS (Arch-based)
- Kernel: 6.19.11-1-cachyos
- Compositor: Niri (Wayland)
- Windsurf version: 1.108.2
- Electron: 39
Problem
The /usr/bin/windsurf launcher script and .desktop file use --ozone-platform-hint=auto, which causes Electron to choose XWayland even when a Wayland session is active (WAYLAND_DISPLAY=wayland-1).
This can be confirmed by checking the environment of the main Windsurf process:
ELECTRON_OZONE_PLATFORM_HINT=auto
WAYLAND_DISPLAY=wayland-1
DISPLAY=:0 ← running under XWayland
And verifying it has X11 windows registered:
xwininfo -root -tree | grep -i windsurf # returns results → XWayland
Workaround
Set --ozone-platform-hint=wayland in ~/.config/windsurf-flags.conf, or set ELECTRON_OZONE_PLATFORM_HINT=wayland in ~/.config/environment.d/.
After applying the workaround:
ELECTRON_OZONE_PLATFORM_HINT=wayland
WAYLAND_DISPLAY=wayland-1
# no X11 windows registered → native Wayland
Expected behavior
When XDG_SESSION_TYPE=wayland, Windsurf should default to native Wayland. VS Code has the same open issue for reference: microsoft/vscode#207033.
Environment
Problem
The
/usr/bin/windsurflauncher script and.desktopfile use--ozone-platform-hint=auto, which causes Electron to choose XWayland even when a Wayland session is active (WAYLAND_DISPLAY=wayland-1).This can be confirmed by checking the environment of the main Windsurf process:
And verifying it has X11 windows registered:
Workaround
Set
--ozone-platform-hint=waylandin~/.config/windsurf-flags.conf, or setELECTRON_OZONE_PLATFORM_HINT=waylandin~/.config/environment.d/.After applying the workaround:
Expected behavior
When
XDG_SESSION_TYPE=wayland, Windsurf should default to native Wayland. VS Code has the same open issue for reference: microsoft/vscode#207033.