Closed prankousky closed 5 years ago
Back when I still used to hide my bar I tried working around this by creating a secondary placeholder bar. It's not going to be pretty though because when your bar is hidden (while the placeholder is still there) you obviously will have a gap.
If you're using i3 (which I assume you are) then there's no way around this. For that reason I actually preferred having it overlap stuff as it was hidden most of the time.
Grabbed this from a backup, hope it's what I actually used back then. This should give you an invisible bar unless you aren't using a compositor. In that case you're even more out of luck:
[bar/top_placeholder]
monitor = eDP-1
width = <your screen width>
height = <height of your actual bar>
modules-left = placeholder
[module/placeholder]
type = custom/script
width = 1
Thank you @tadly . I was hoping that there'd be a solution that would allow the bar to be there when not using fullscreen (so no gap), but display it on hover when fullscreen is enabled.
Currently, I don't run anything in fullscreen, actually. I would run firefox in fullscreen, but it runs on my largest monitor, where I definitely want to see polybar all the time, or at least at most times...
Okay that's different to what I gathered from your initial request.
If I understood you correctly you basically want:
There's another project of mine - savery - which can detect when the active window enters/leaves fullscreen. This feature I specifically added so I could completely hide my tray when entering fullscreen.
As your cases is the opposite, I would:
override-redirect = true
enter_fullscreen_action
to start the service systemctl --user start <service>
leave_fullscreen_action
to stop the service systemctl --user stop <service>
Example service as I use it:
[Unit]
Description=hideIt.sh - Polybar top
Requires=wm.target polybar@top.service
After=polybar@top.service
PartOf=polybar@top.service
[Service]
Type=simple
ExecStart=/usr/bin/hideIt.sh -N '^polybar-top_eDP1$' -d top -s 1 -H
Restart=on-failure
RestartSec=1
StartLimitBurst=3
[Install]
WantedBy=wm.target
Hope this covers everything.
Thank you. Sorry, not a native speaker... What I am trying to achieve is
I will not be able to test savery until back on my main computer late next week, but I will definitely check it out then :)
Closing due to inactivity.
If you need any more help just leave a comment.
Hi everybody,
I have read this issue already and set my polybar to
override-redirect = true
. When I do this, I am able to hide my polybar (and restore by hovering over it), however my terminal (qterminal
) is overlapped by polybar whenever it is there (thereby permanently hiding the first line).In order to prevent this, I either need to use
override-redirect ? true offset-x = 2 offset-y = 5
, or disable it completely# override-redirect = true
.I think this script is fantastic (just stumbled upon it on reddit) and would love to implement it in my workflow. But unless I always let polybar overlap my terminal (which happens when I use override), I cannot use it. Is there another way to do this?
I use multiple screens. It is usually terminal on the left screen, webbrowser on the right. When I use override-redirect, of course, the browser gets overlapped by polybar as well.
My WM is
i3-gaps
.Thanks for any ideas on how to fix this =)