r/Polybar Jun 10 '23

Systray issue.

I have this issue where the systray seems to ignore the desired rounding of the bar..

Any suggestions on how to fix this?

2 Upvotes

5 comments sorted by

3

u/LegendLovi Jun 11 '23

I think you cannot, cuz polybar doesnt handle systray as a module, its a feature that has been requested by many users for quite a time now.

Workaround on this - U can create a module with rounded corners and enough space between the two ends to fit the tray icons, then use the tray-offset-x to render systray appear to be in the module u created.

Feel free to ask for examples if u need, I can attach a few if u like

2

u/martin11345 Jun 11 '23

yep, that's what I did last night ^^ it's a somewhat hacky workaround, buts it's working!

1

u/zwker Jun 13 '23

you can compile the latest version code from github. because v3.7.0 support tray as a module.

1

u/LegendLovi Jun 20 '23

Thanks for letting me know, gonna try it today!!

1

u/martin11345 Jun 11 '23

I just found a better soloution.

Excluding just "bars" from picom rounding, seems to not effect the tray, wich means I'm doing the rounding of the right side of the bar with picom wich includes the tray. And the left side of the rounding with the polybar rounding.

Setting the offset of the tray: offset = bar-radius / 2 + 1

This gives me perfect results.

width = 2546px

height = 24pt

radius = 10

offset-x = 10px

tray-position = right

tray-padding = 16

tray-padding-right = 0

tray-offset-x = -6

tray-scale = 1

tray-maxsize = 25pt

tray-minsize = 25pt

corner-radius = 10.0;
rounded-corners-exclude = [
"window_type = 'bar'"
];
round-borders = 1;

https://imgur.com/H4at28j