Bug 488832 - Add a button/option that will show the logout screen with all options
Summary: Add a button/option that will show the logout screen with all options
Status: RESOLVED FIXED
Alias: None
Product: plasmashell
Classification: Plasma
Component: Lock/logout (show other bugs)
Version: 6.1.0
Platform: Other Linux
: NOR wishlist
Target Milestone: 1.0
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-06-20 21:29 UTC by Eamonn Rea
Modified: 2024-06-26 03:03 UTC (History)
6 users (show)

See Also:
Latest Commit:
Version Fixed In: 6.2.0
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Eamonn Rea 2024-06-20 21:29:04 UTC
SUMMARY
If you have a Lock/Logout widget and configure it to only show that button, clicking on it will only show "Shut Down Now" and "Cancel". There is no way to, for example, restart, unless you configure this widget to display, in that case, "Restart" *and* click that button. You are locked to only be able to "Perform Action Now", where that Action is the button you pressed. For Lock/Logout, the user might only have one button configured so as to not pollute the panel, and to simply have this as a "catch all" to display session options.

The action can be selected from KRunner by searching for, say, "Restart", but the "Desktop Sessions" category may not be the first result or the options could have jumped around and changed by the time a user presses enter.

This may be intentional, as if you do this from something like the Application Dashboard where the buttons are bigger, and the action is less generic than it is with the Lock/Logout widget. Although I still think in that case it should be customisable what options display on that screen, to restore the previous behaviour.

Alternatively, a widget that can act as a button to show any number of options as a replacement would also work.

STEPS TO REPRODUCE
1. Add Lock/Logout Widget
2. Configure it to only display "Power Off"
3. Click on the Widget
4. It does not display the other session management options, it acts like the button on the Application Dashboard/Launcher/Menu, or the option from KRunner. This is unexpected behaviour from previous Plasma versions where you would see a list of session management options, and I believe there was an option for this setting to take effect immediately.

OBSERVED RESULT
Session management screen only displays the option to perform the action you pressed immediately or to cancel. There is no way to show all session management options (Restart,  Poweroff, etc). This is a significant change in behaviour from Plasma 6.0.5 and below, where you could see all management options, so when using the Lock/Logout widget you could press the "Poweroff" looking button and then choose whether you wanted to logout, restart, poweroff, etc, without having to do so from any other screen.

EXPECTED RESULT
The options in the Application Dashboard/Launcher/Menu could, by default, have this behaviour, but Lock/Logout should at least have an option to configure it to display all session management options with a single button press. I assume Lock/Logout is using the same pattern as the Application Dashboard/Launcher/Menu.

There is an option in Power Management to "Show logout screen" on actions such as when the Power Button is pressed. There should be a way to enable this for whenever a session management button is pressed, both from Lock/Logout and if the logic is indeed shared then also in the Application Dashboard/Launcher/Menu.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: 6.9.5 Linux Zen
KDE Plasma Version: 6.1.0
KDE Frameworks Version: 6.3.0
Qt Version: 6.7.1

ADDITIONAL INFORMATION
I am using the Wayland session, but I don't think this is specific to X11 or Wayland.
Comment 1 Nate Graham 2024-06-20 21:59:03 UTC
This is intentional, but I see the problem that you're really reporting: that there's no way to use this widget to just show the logout screen with all options anymore. That's legit.
Comment 2 Eamonn Rea 2024-06-20 22:09:05 UTC
Yes, that is what it boils down to; in the context of this issue, ideally also preserving the icon would be useful as well (some users may have "Restart" as their default, although I personally have "Poweroff").

That might be excessive and very specific customisation though. Maybe in general being able to set a custom icon rather than customising it based on the selected option is the way to go, like how we can change the icon for the Application Dashboard/Launcher/Menu. I'm not sure if it's feasible, or should be a separate report, but just some thoughts :-)

The icon is certainly lower priority though, as to me this is more of a muscle-memory thing than a visual thing.
Comment 3 Antonio Rojas 2024-06-21 07:03:55 UTC
This also affects the "User switcher" applet. There is no way to restart or turn off the computer from the applet now.
Comment 4 filip.kendes1 2024-06-21 07:31:23 UTC
If you open Shortcuts -> Session Management -> Show Logout Prompt (Ctrl+Alt+Del) you get the logout prompt with all the options available.

Maybe we can add this option (whatever this shortcut triggers, I'm not sure) to the Lock/Logout widget?
Comment 5 Bug Janitor Service 2024-06-21 13:58:23 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/4475
Comment 6 Alexey Arutyunov 2024-06-22 01:16:44 UTC
(In reply to filip.kendes1 from comment #4)
> If you open Shortcuts -> Session Management -> Show Logout Prompt
> (Ctrl+Alt+Del) you get the logout prompt with all the options available.
> 
> Maybe we can add this option (whatever this shortcut triggers, I'm not sure)
> to the Lock/Logout widget?

As a workaround I created $HOME/.local/share/applications/logoutprompt.desktop file with the following contents:
---
[Desktop Entry]
Type=Application
Name=Logout
Comment=Logout Prompt
Categories=Utility;
OnlyShowIn=KDE;
Exec=qdbus-qt6 org.kde.LogoutPrompt /LogoutPrompt promptAll
Icon=system-shutdown-symbolic
StartupNotify=false
---
Then dragged it's entry from Utilities menu to the place on the panel where I had the logout button. This icon widget works exactly like the logout button used to work for me.

Hope this helps until proper fix for the widget.
Comment 7 Nate Graham 2024-06-24 17:27:29 UTC
Git commit 606ca96225a75a8c374932ab336e4ea5c03ad729 by Nate Graham, on behalf of Thomas Carmichael.
Committed on 24/06/2024 at 17:27.
Pushed by ngraham into branch 'master'.

applets/lock_logout: add "show logout screen" option


With the change to simplify the logout greeter UI when invoked with a specific option, there is currently no option to trigger the logout greeter with all of the options via any existing actions.

This adds a logout screen action which shows the logout greeter with available options.
FIXED-IN: 6.2

M  +4    -0    applets/lock_logout/contents/config/main.xml
M  +8    -1    applets/lock_logout/contents/ui/ConfigGeneral.qml
M  +7    -0    applets/lock_logout/contents/ui/data.js

https://invent.kde.org/plasma/plasma-workspace/-/commit/606ca96225a75a8c374932ab336e4ea5c03ad729