PaperWM
PaperWM copied to clipboard
Godot constantly refocuses itself
Describe the bug When switching between windows, Godot always seems to refocus itself. This happens with the main godot editor then also when launching the game.
Godot is the only program I've experienced this with
To Reproduce I'm not sure if it's only godot causing this but
- Open Window 1 (anything, firefox or something)
- Open Godot
- Switch to window 1
- PaperWM scrolls back to godot
Expected behavior Should switch to Firefox and stay on firefox until keyboard shortcut/gesture to switch back
Screenshots Screencast from 2023-12-23 09-51-20.webm
System information:
Please execute ./gather-system-info.sh
in you PaperWM clone and paste the output below.
Distribution: NixOS
GNOME Shell 45.2
Display server: Wayland
PaperWM branch/tag: release
PaperWM commit: 6bead84704bf4db8fb7eb2ecd94bb1212059f7c3
Enabled extensions:
- [email protected]
- [email protected]
- blur-my-shell@aunetx
- [email protected]
Additional context A workaround for now seems to be to fullscreen the window (like double clicking the window's topbar), but it's tedious and annoying to have to do
Thanks for reporting - yep, that would be annoying.
Any other applications this is happening on?
Lastly, how was Godot installed? (distro repo or flatpak? or some other way?) - just going to try reproduce.
Thanks @tmayoff - I can reproduce so will dig into this soon.
You reproduced it already, but to answer the questions, seems to just be Godot that this is happening with, it was installed through nixpkgs on nixos
Right, Godot seems to be doing some really funny stuff when it comes to focusing/defocusing (sometimes when another window gets focus, it toggles focus on godot windows).
Anyways, suspect this is an upstream godot issue, as other linux window managers are seeing this behaviour, see:
- https://github.com/godotengine/godot/issues/68305 (see last comment from a few days ago)
- https://github.com/godotengine/godot/issues/74378
- https://github.com/godotengine/godot/issues/86438
- https://github.com/godotengine/godot/issues/86442
Marking as upstream for now.
I noticed some games doing the same but don't remember which exactly. I think it also depended on if it was fullscreen or not and if it was capturing the mouse or not. But I haven't had the same problem with any "normal" desktop apps.
I have a similar problem with Spotify (flatpak). It randomly steals focus and PaperWM scrolls to it. A workaround is to send it to scratch.