[wiki] [sites] Updated for 6.1-git (2019/01/11) || Jason Green

From: <git_AT_suckless.org>
Date: Fri, 11 Jan 2019 15:19:43 +0100

commit 5886904be159ac72efa935fc58435990735e37f9
Author: Jason Green <sakuitech_AT_gmail.com>
Date: Fri Jan 11 08:08:29 2019 -0600

    Updated for 6.1-git (2019/01/11)

diff --git a/dwm.suckless.org/patches/gaps/dwm-gaps-6.1.diff b/dwm.suckless.org/patches/gaps/dwm-gaps-6.1.diff
new file mode 100644
index 00000000..19a8df9a
--- /dev/null
+++ b/dwm.suckless.org/patches/gaps/dwm-gaps-6.1.diff
_AT_@ -0,0 +1,50 @@
+diff -Naur a/config.def.h b/config.def.h
+--- a/config.def.h Sun Jan 6 22:18:53 2019
++++ b/config.def.h Sun Jan 6 22:20:36 2019
+_AT_@ -5,6 +5,7 @@
+ 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 */
++static const unsigned int gappx = 1; /* gap pixel between windows */
+ static const char *fonts[] = { "monospace:size=10" };
+ static const char dmenufont[] = "monospace:size=10";
+ static const char col_gray1[] = "#222222";
+diff -Naur a/dwm.c b/dwm.c
+--- a/dwm.c Sun Jan 6 22:18:53 2019
++++ b/dwm.c Sun Jan 6 22:25:03 2019
+_AT_@ -1673,7 +1673,7 @@
+ void
+ tile(Monitor *m)
+ {
+- unsigned int i, n, h, mw, my, ty;
++ unsigned int i, n, h, r, g = 0, mw, my, ty;
+ Client *c;
+
+ for (n = 0, c = nexttiled(m->clients); c; c = nexttiled(c->next), n++);
+_AT_@ -1681,18 +1681,20 @@
+ return;
+
+ if (n > m->nmaster)
+- mw = m->nmaster ? m->ww * m->mfact : 0;
++ mw = m->nmaster ? (m->ww - (g = gappx)) * m->mfact : 0;
+ else
+ mw = m->ww;
+ 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);
++ r = MIN(n, m->nmaster) - i;
++ h = (m->wh - my - gappx * (r - 1)) / r;
+ resize(c, m->wx, m->wy + my, mw - (2*c->bw), h - (2*c->bw), 0);
+- my += HEIGHT(c);
++ my += HEIGHT(c) + gappx;
+ } 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);
++ r = n - i;
++ h = (m->wh - ty - gappx * (r - 1)) / r;
++ resize(c, m->wx + mw + g, m->wy + ty, m->ww - mw - g - (2*c->bw), h - (2*c->bw), False);
++ ty += HEIGHT(c) + gappx;
+ }
+ }
+
Received on Fri Jan 11 2019 - 15:19:43 CET

This archive was generated by hypermail 2.3.0 : Fri Jan 11 2019 - 15:24:25 CET