Important
This project is no longer being maintained
Now that Plasma 6 has been released with Dodge Window feature builtin, I have no need for this anymore. If anyone need to have this on Plasma 5 feel free to fork and fix it or start a new one.
A KWin script that hides Plasma panels when there are maximized windows (all/top/bottom/left/right).
2023-07-18_03-46-27.mp4
- I like to have a panel on a clean desktop but to stay away if I maximize
- There is windows can cover but panel still shows behind translucent/blurred windows and I don't like that
- Windows can cover sometimes doesnt show when hovering if maximized windows is present
- To replicate Latte Dock's "dodge" mode
- This had only been tested on single/double monitor setups and can only handle a single window as of now
- Panel on screen edge between two monitors does not auto hide, this is a Plasma BUG:351175
- Primary monitor must be the left one!
If the right monitor is set as primary it will toggle panels on the opposite screen??? I could not find a solution for this due to my lack of knowledge on how Plasma and KWin scripting work but if someone knows how let me know or open a PR :)
- I am a newbie so expect messy code and bugs 🐞
- Configurable which panels to hide (
top
,bottom
,left
,right
) - Toggles auto hide only on screen with visible maximized window
- Unhides panel on minimize of maximized window
- Hides panel on unminimize of maximized window
- Whitelist mode
- Virtual desktop switching support
- Configurable window class blacklist
- Handle multiple windows on same screen
- Minimizing/maximizing stacked windows (partially)
- Handle tiled windows
- Multi monitor support
- Handle windows position relative to the screen they are on
- Handle windows switching between screens (
Alt
+F3
>Move to Screen
)
- Show on Peek at desktop
- Dodge mode (hide when a window enters panel area)
- Dodge on panels set to dodge (only for panels with auto-hide enabled)
- ?
Download it from KDE Store or use KWin Scripts
> Get New Scripts
/Discover
> Plasma Addons
> search
> panel auto hide
Just clone the repo. make
commands have been set up to do all the things.
make build
- Build the.kwinscript
filemake clean
- Remove the.kwinscript
filemake install
- Install the script to your Plasmamake uninstall
- Uninstall the script from your Plasmamake debug
- Seeprint()
outputs (unfortunately shows all kwin scripts on your system and does not update in real time)
- When a window is created/maximized/unmaximized it gets on which iscreen it is
- Then calls
org.kde.plasmashell /PlasmaShell evaluateScript
usingcallDBus
with passed screen and window properties - The plasma script loops through all panels
- Checks if the panel screen property is the same as the window one
- If it is then toggles between
autohide
andwindowsbelow
depending on the window maximized state
- The dodge mode works by listening for windows geometry chanages
- If a windows enters the area of a panel that can hide and has dodge mode enabled, the panel will be hidden
- When the window leaves the panel area the panel is restored
- The reason for using
windowsbelow
is because:- Tiled windows using shortcuts automatically enter the panel, making it dodge as intended
- Dodge movement seems smoother
- Switching from
autohide
towindowscover
doesnt bring the panel back without hovering it first
PRs are welcome!
- Based on (but not forked from) fin444/truely-maximized
- Config ui file was adapted from zeroxoneafour/polonium
- This tubbadu's reddit comment on how to toggle panels auto hide