bar border - allow for the border size to be explicitly set ref. #364

This commit is contained in:
bakkeby
2023-06-27 16:31:02 +02:00
parent 99f6f1b52c
commit ab7d28ff0f
3 changed files with 16 additions and 8 deletions

View File

@ -15,13 +15,15 @@ setborderpx(const Arg *arg)
int delta = 2 * (m->borderpx - prev_borderpx);
#if BAR_BORDER_PATCH
for (bar = m->bar; bar; bar = bar->next) {
bar->bh = bar->bh - 2 * bar->borderpx + 2 * m->borderpx;
bar->borderpx = m->borderpx;
if (!barborderpx) {
for (bar = m->bar; bar; bar = bar->next) {
bar->bh = bar->bh - 2 * bar->borderpx + 2 * m->borderpx;
bar->borderpx = m->borderpx;
}
updatebarpos(m);
for (bar = m->bar; bar; bar = bar->next)
XMoveResizeWindow(dpy, bar->win, bar->bx, bar->by, bar->bw, bar->bh);
}
updatebarpos(m);
for (bar = m->bar; bar; bar = bar->next)
XMoveResizeWindow(dpy, bar->win, bar->bx, bar->by, bar->bw, bar->bh);
#endif // BAR_BORDER_PATCH
for (c = m->clients; c; c = c->next) {