francma / wob

A lightweight overlay volume/backlight/progress/anything bar for Wayland.
ISC License
896 stars 49 forks source link

Feature request: allow margin for top/bottom and left/right #110

Closed stvsu closed 1 year ago

stvsu commented 1 year ago

Looking at main.c line 129, it looks like zwlr_layer_surface_v1_set_margin allows for setting top, bottom, left and right margin.

Would you consider adding a config param to allow for margin_x = value (to set left and right) and margin_y = value (to set top and bottom)?

Ideally I would like to be able to offset the bar with different values for the x and y axis, rather than moving them in unison.

stvsu commented 1 year ago

This could also be solved by allowing two values for margin = x-axis y-axis e.g. margin = 5 3 would set a left/right margin of 5px and a top/bottom margin of 3px.

francma commented 1 year ago

Hello. I prefer the variant with:

margin = top right bottom left
margin = top-bottom right-left
margin = all

just like with css margin. Feel free to create a pull request.