diff --git a/config.h b/config.h index 658fb67..fb1fa24 100644 --- a/config.h +++ b/config.h @@ -1,7 +1,7 @@ /* See LICENSE file for copyright and license details. */ /* appearance */ -static const unsigned int borderpx = 1; /* border pixel of windows */ +static const unsigned int borderpx = 0; /* border pixel of windows */ static const unsigned int snap = 32; /* snap pixel */ static const int showbar = 1; /* 0 means no bar */ static const int topbar = 1; /* 0 means bottom bar */ diff --git a/drw.o b/drw.o new file mode 100644 index 0000000..4ef281c Binary files /dev/null and b/drw.o differ diff --git a/dwm b/dwm new file mode 100755 index 0000000..15e1b67 Binary files /dev/null and b/dwm differ diff --git a/dwm-6.2.tar.gz b/dwm-6.2.tar.gz deleted file mode 100644 index e58b267..0000000 Binary files a/dwm-6.2.tar.gz and /dev/null differ diff --git a/dwm.c b/dwm.c index 6474055..e1fbd94 100644 --- a/dwm.c +++ b/dwm.c @@ -809,6 +809,8 @@ expose(XEvent *e) void focus(Client *c) { + XWindowChanges wc; + if (!c || !ISVISIBLE(c)) for (c = selmon->stack; c && !ISVISIBLE(c); c = c->snext); if (selmon->sel && selmon->sel != c) @@ -822,6 +824,11 @@ focus(Client *c) attachstack(c); grabbuttons(c, 1); XSetWindowBorder(dpy, c->win, scheme[SchemeSel][ColBorder].pixel); + if (!c->isfloating) { + wc.sibling = selmon->barwin; + wc.stack_mode = Below; + XConfigureWindow(dpy, c->win, CWSibling | CWStackMode, &wc); + } setfocus(c); } else { XSetInputFocus(dpy, root, RevertToPointerRoot, CurrentTime); @@ -1138,7 +1145,7 @@ monocle(Monitor *m) if (n > 0) /* override layout symbol */ snprintf(m->ltsymbol, sizeof m->ltsymbol, "[%d]", n); for (c = nexttiled(m->clients); c; c = nexttiled(c->next)) - resize(c, m->wx, m->wy, m->ww - 2 * c->bw, m->wh - 2 * c->bw, 0); + resize(c, m->wx - c->bw, m->wy, m->ww, m->wh, False); } void @@ -1713,12 +1720,15 @@ tile(Monitor *m) for (i = my = ty = 0, c = nexttiled(m->clients); c; c = nexttiled(c->next), i++) if (i < m->nmaster) { h = (m->wh - my) / (MIN(n, m->nmaster) - i); - resize(c, m->wx, m->wy + my, mw - (2*c->bw), h - (2*c->bw), 0); - my += HEIGHT(c); + if (n == 1) + resize(c, m->wx - c->bw, m->wy, m->ww, m->wh, False); + else + resize(c, m->wx - c->bw, m->wy + my, mw - c->bw, h - c->bw, False); + my += HEIGHT(c) - c->bw; } else { h = (m->wh - ty) / (n - i); - resize(c, m->wx + mw, m->wy + ty, m->ww - mw - (2*c->bw), h - (2*c->bw), 0); - ty += HEIGHT(c); + resize(c, m->wx + mw - c->bw, m->wy + ty, m->ww - mw, h - c->bw, False); + ty += HEIGHT(c) - c->bw; } } diff --git a/dwm.o b/dwm.o new file mode 100644 index 0000000..e22dda8 Binary files /dev/null and b/dwm.o differ diff --git a/util.o b/util.o new file mode 100644 index 0000000..56b8a42 Binary files /dev/null and b/util.o differ