Bug 452928

Summary: Cannot exit edit mode with the Esc key when no windows are open or all are minimized
Product: [Plasma] plasmashell Reporter: zocsfxljsgpmiuaanz
Component: ContainmentAssignee: Plasma Bugs List <plasma-bugs-null>
Status: RESOLVED FIXED    
Severity: minor CC: cwo.kde, dmatteo002, kde, nate, notmart
Priority: NOR Keywords: usability
Version First Reported In: 5.24.4   
Target Milestone: 1.0   
Platform: Gentoo Packages   
OS: Linux   
Latest Commit: Version Fixed/Implemented In: 6.1
Sentry Crash Report:

Description zocsfxljsgpmiuaanz 2022-04-23 21:37:18 UTC
SUMMARY
When you enter edit mode from the desktop you cannot use the Esc key to exit from it. This doesn't happen when you enter edit mode when there are open (and/or focused?) windows, pressing Esc on this last case exits edit mode properly.

STEPS TO REPRODUCE
1. Have no open windows or have all your windows minimized
2. Enter edit mode
3. Press the Esc key

OBSERVED RESULT
You are still on edit mode. :(

EXPECTED RESULT
You exit edit mode.

SOFTWARE/OS VERSIONS
Operating System: Gentoo Linux
KDE Plasma Version: 5.24.4
KDE Frameworks Version: 5.93.0
Qt Version: 5.15.3
Graphics Platform: X11
Comment 1 Nate Graham 2022-04-25 17:52:42 UTC
You say it only happens when there are no windows open, is that correct? What specific method did you enter edit mode?
Comment 2 zocsfxljsgpmiuaanz 2022-04-25 19:03:21 UTC
> You say it only happens when there are no windows open, is that correct?
When there are no windows opens or when all windows are minimized and you can only see the desktop.
> What specific method did you enter edit mode?
It happens when I enter edit mode with the shortcut (Alt+D, E) or when selecting the right option on the contextual menu of the desktop or panel(s).
Comment 3 Nate Graham 2022-04-26 14:36:20 UTC
Can confirm. I suspect what happens is that when there are any windows visible, entering Edit mode also triggers the "Show Desktop" effect, which deactivates with the Escape key. And when it deactivates, it automatically exits edit mode. But when no windows were visible, the "Show Desktop" doesn't get triggered, so it doesn't handle the Escape key, which means the desktop itself has to handle it, and it doesn't.
Comment 4 cwo 2024-06-18 20:06:09 UTC
This seems to work with the new Edit Mode in plasma 6.1.

If you enter the global edit mode through the desktop context menu, pressing Escape will close edit mode. (Similarly for entering via the Alt-D E shortcut)

If you enter edit mode by right-clicking the panel, pressing Escape will close the Panel Settings interface, and pressing Escape a second time will exit Edit Mode.

This works if there are no open windows, only minimized windows, or both visible and minimized windows.
Comment 5 Nate Graham 2024-06-19 14:21:53 UTC
Yup, this is fixed with the new Edit Mode UX in Plasma 6.1!