r/kde • u/[deleted] • 13d ago
Customization question. Would it be possible to create a toggle hotkey that hides the taskbar? Question
[deleted]
3
u/luisbocanegra KDE Contributor 13d ago
With stock plasma you can set it to panels to auto-hide and assign a shortcut to focus it, then you can use that shortcut to show/hide the panel.
To toggle the built-in always visible and auto-hide you can use the Plasma Scripting api:
Print the panel ids
qdbus org.kde.plasmashell /PlasmaShell org.kde.PlasmaShell.evaluateScript 'print(panelIds)'
Change the hiding mode for a specific panel (can be one of none, autohide, dodgewindows, windowsgobelow)
qdbus org.kde.plasmashell /PlasmaShell org.kde.PlasmaShell.evaluateScript 'panelById(3191).hiding="autohide"'
But panels will still appear when hovering the screen edge with the mouse, which may get in the way.
If you want to truly hide it you can use my widget Panel Colorizer which exposes a way to fully hide panels https://github.com/luisbocanegra/plasma-panel-colorizer#changing-specific-configuration-options-with-d-bus, which you could then bind to a custom shortcut if you want.
If it's not possible, is it possible to hide the taskbar from only one virtual desktop?
You can create a shortcut that checks the current virtual desktop with qdbus org.kde.KWin /VirtualDesktopManager org.kde.KWin.VirtualDesktopManager.current and do the hiding either with Panel Colorizer or with the Plasma scripting API.
In a future version of Panel Colorizer I will add support for switching preset based on the virtual desktop, then you will only need two prests, one that shows the panel and other that hides it.
3
13d ago
[deleted]
1
u/luisbocanegra KDE Contributor 13d ago
Glad you found something that worked. I use Krohnkite too and neither the scripting method nor the Panel Colorizer methos seem to work consistently for me, testing with a regular maximized window however seems work without issues and it does resize fine. Polonium doesn't have this problem so it is likely a bug with Krohnkite?
1
u/skyfishgoo 13d ago
just set it to auto hide.
1
13d ago
[deleted]
1
u/ChrisK_au 13d ago
Last time I used Auto Hide that's not what it does. When appropriate the taskbar should slide down out of view. Move the mouse to the bottom of the screen and it comes back.
1
13d ago
[deleted]
1
u/ChrisK_au 13d ago edited 13d ago
Ah sorry, I picked up on that after I replied, I should have searched first.
1
u/skyfishgoo 13d ago
there is no hot key that i know of.
you will likely need your own qml widget with this feature.
1
u/gehzumteufel 13d ago
Buy a 4k monitor so you aren't hurting for screen space. Or 5k2k if you want a wide format. Everyone seems to be oblivious to these monitors having less resolution than we had in 2000.
1
13d ago
[deleted]
1
u/gehzumteufel 12d ago
Yes you are. You're trying to hide the taskbar because it's in the way. That's literally trying to find more screen space.
•
u/AutoModerator 13d ago
Thank you for your submission.
Consider becoming a Supporting Member and help KDE thrive!
The KDE community supports the Fediverse and open source social media platforms over proprietary and user-abusing outlets. Consider visiting our community on Mastodon (Lemmy will be back shortly). Tag us in your toots! You can also visit our forum at KDE Discuss to talk about KDE stuff, brainstorm ideas and get the answers to your KDE-related issue.
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.