Bug 463389

Summary: Full screen windows open a new desktop : can't disable, buggy behavior when closing.
Product: [Plasma] kwin Reporter: Lapineige <lp.kde>
Component: generalAssignee: KWin default assignee <kwin-bugs-null>
Status: RESOLVED DOWNSTREAM    
Severity: normal CC: nate
Priority: NOR    
Version First Reported In: 5.26.4   
Target Milestone: ---   
Platform: Kubuntu   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description Lapineige 2022-12-23 11:48:34 UTC
SUMMARY
1) When I open a window in fullscreen, it goes on a newly created virtual desktop (with desktop change slide animation). I believe it's the "fullscreen" desktop effect. This effect is disabled. Enabling it and disabling it again changes nothing.
2) When I close the fullscreen windows, virtual desktop is removed (with no visible animation).
But if I exit fullscreen first, no matter what I do next (even opening another window in fullscreen), if I close that window it removes one virtual desktop. And then I have to recreate it, reorganize the windows again and so on.
This can be chained : 3 fullscreen windows close will destroy 3 virtual desktops.
This works with any window (tested with Firefox, VLC, Dolphin, Gwenview, games…)

This issue has been here for at least 3 major (5.xx) versions, and Kubuntu 21.10.

STEPS TO REPRODUCE
1. Open a window in fullscreen (this create a new virtual desktop)
2. Exit full screen and close it  // close it.

OBSERVED RESULT
Fullscreen windows opens in a new virtual desktop.
Current virtual desktop is removed.

EXPECTED RESULT
- No virtual desktop is created
- closing a non fullscreen window don't close the virtual desktop.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Kubuntu 22.10 + backports
(available in About System)
KDE Plasma Version: 5.26.4 (bug here since older versions)
KDE Frameworks Version: 5.100.0 (bug here since older versions)
Qt Version: 5.15.6 (bug here since older versions)

ADDITIONAL INFORMATION
Comment 1 Vlad Zahorodnii 2023-01-06 10:19:48 UTC
kwin creates no virtual desktops when a fullscreen window is shown. it sounds like you run kwin with third party scripts. there are scripts that put maximized and fullscreen windows on new desktops, e.g. https://store.kde.org/p/1171196.
Comment 2 Lapineige 2023-01-06 20:45:17 UTC
As far as I can see (in the desktop effect "add more" menu), I don't use any third party script.
Comment 3 Lapineige 2023-01-06 20:46:35 UTC
(In reply to Lapineige from comment #2)
> As far as I can see (in the desktop effect "add more" menu), I don't use any
> third party script.

Oh, my bad, I do have this one Maximize To New Virtual Desktop activated, it's in the "Kwin script" menu.
I don't remember downloading it but that's another story...

Thanks.