Repository navigation
Floating bar with rounded corners: [bar] margin and radius in shell.toml
#11327
taufardh
started this conversation in
Suggestions
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
The bar already supports glass through
shell.toml.[bar] background-alphaplus a Hyprland
layer_rulewithblur = trueon theomarchy-barnamespace gives a nice frosted bar. What's missing is the other half of
that look: a bar that floats off the screen edge with rounded corners,
matching the windows below it.
Right now this can't be done through configuration:
BarPanelinshell/plugins/bar/Bar.qmlhas itsmarginshardcoded to 0,apart from the auto-hide parking offset.
PanelWindow's owncolor, so thesurface is always a sharp-cornered, edge-to-edge rectangle.
A clone (
omarchy plugin clone omarchy.bar) isn't a real way around thiseither. Since 4.0.3, a replacement bar gets the service-less entry facade
(
pluginShellForBarEntry), so widgets that callserviceFor()orfirstPartyServiceFor()stop working under it. I tried it:agx.screen-timelost its label, and indicators and audio use the same calls. That boundary
makes sense, but it means bar shape can only change in the stock bar.
Proposal: two optional keys in the existing
[bar]section:Both default to 0, so nothing changes for anyone who doesn't set them.
Possibly also accept
"auto", which would map to the values the shellalready reads from Hyprland:
Style.gapsOutformarginandStyle.cornerRadiusforradius. That way the bar follows the user'sgaps and rounding.
Rough shape of the change in
Bar.qml:BarPanel.marginsaddmarginon the anchored edges (top, left andright for a top bar).
colorto"transparent"and draw the background as aRectangle { radius; color: root.transparent ? "transparent" : root.background }filling the loader area.
-(barSize + margin)so no sliver staysvisible.
barSize + margin, and that popupsand tooltips anchored to
barWindowstill line up.Blur needs no extra work. With
ignore_alphaon the layer rule, thefully transparent corners are skipped, so the frost follows the rounded
shape.
Omarchy 4.0.3, Hyprland, single laptop panel with a top bar.
All reactions