[wiki] [sites] Update to new naming scheme || Britton Leo Kerin

From: <git_AT_suckless.org>
Date: Thu, 14 Jul 2016 02:25:14 +0200

commit b19d1646b74182bebb4a8c91b0fe8a713fd3c90d
Author: Britton Leo Kerin <britton.kerin_AT_gmail.com>
Date: Wed Jul 13 16:20:45 2016 -0800

    Update to new naming scheme

diff --git a/dwm.suckless.org/patches/clientspertag.md b/dwm.suckless.org/patches/clientspertag.md
index 851a3ca..09bc0ac 100644
--- a/dwm.suckless.org/patches/clientspertag.md
+++ b/dwm.suckless.org/patches/clientspertag.md
_AT_@ -41,7 +41,7 @@ will result on swapping between the defined value and -1.
 
 ## Download
 
- * [dwm-5.6.1-cpt.diff](dwm-5.6.1-cpt.diff) (2.9k) (20090913)
+ * [dwm-clientspertag-5.6.1.diff](dwm-clientspertag-5.6.1.diff)
 
 ## Maintainer
 
diff --git a/dwm.suckless.org/patches/dwm-5.6.1-cpt.diff b/dwm.suckless.org/patches/dwm-5.6.1-cpt.diff
deleted file mode 100644
index e32a3e4..0000000
--- a/dwm.suckless.org/patches/dwm-5.6.1-cpt.diff
+++ /dev/null
_AT_@ -1,71 +0,0 @@
-diff -ru dwm-5.6.1/dwm.c dwm-5.6.1-cpt/dwm.c
---- dwm-5.6.1/dwm.c 2009-07-26 15:01:50.000000000 +0200
-+++ dwm-5.6.1-cpt/dwm.c 2009-09-13 18:08:50.000000000 +0200
-_AT_@ -268,12 +268,23 @@
- static Window root;
-
- /* configuration, allows nested code to access above variables */
-+static int cpt = -1;
-+static void clientspertag(const Arg *arg) {
-+ const char *cmd = (const char *)arg->v;
-+ if (cmd[0]=='^') {
-+ if (cpt==-1) cpt = atoi(cmd+1);
-+ else if (cpt==atoi(cmd+1)) cpt = -1;
-+ else cpt = atoi(cmd+1);
-+ } else cpt = atoi(cmd);
-+ arrange();
-+}
- #include "config.h"
-
- /* compile-time check if all tags fit into an unsigned int bit array. */
- struct NumTags { char limitexceeded[LENGTH(tags) > 31 ? -1 : 1]; };
-
- /* function implementations */
-+
- void
- applyrules(Client *c) {
- const char *class, *instance;
-_AT_@ -674,7 +685,7 @@
- drawtext(m->lt[m->sellt]->symbol, dc.norm, False);
- dc.x += dc.w;
- }
-- snprintf(ntext, sizeof ntext, "%u", n);
-+ snprintf(ntext, sizeof ntext, "%d/%u", cpt, n);
- dc.w = TEXTW(ntext);
- drawtext(ntext, dc.norm, False);
- x = (dc.x += dc.w);
-_AT_@ -1435,6 +1446,7 @@
- sw = DisplayWidth(dpy, screen);
- sh = DisplayHeight(dpy, screen);
- bh = dc.h = dc.font.height + 2;
-+ cpt = -1;
- updategeom();
- /* init atoms */
- wmatom[WMProtocols] = XInternAtom(dpy, "WM_PROTOCOLS", False);
-_AT_@ -1549,6 +1561,7 @@
- for(n = 0, c = nexttiled(m->clients); c; c = nexttiled(c->next), n++);
- if(n == 0)
- return;
-+ if (cpt!=-1 && n>cpt) n = cpt;
- /* master */
- c = nexttiled(m->clients);
- mw = m->mfact * m->ww;
-_AT_@ -1563,10 +1576,15 @@
- if(h < bh)
- h = m->wh;
- for(i = 0, c = nexttiled(c->next); c; c = nexttiled(c->next), i++) {
-- resize(c, x, y, w - 2 * c->bw, /* remainder */ ((i + 1 == n)
-- ? m->wy + m->wh - y - 2 * c->bw : h - 2 * c->bw), False);
-- if(h != m->wh)
-- y = c->y + HEIGHT(c);
-+ if (cpt!=-1 && i>=cpt) {
-+ resize(c, x, m->wy, w - 2 * c->bw, /* remainder */ ((i + 1 == n)
-+ ? m->wy + m->wh - y - 2 * c->bw : h - 2 * c->bw), False);
-+ } else {
-+ resize(c, x, y, w - 2 * c->bw, /* remainder */ ((i + 1 == n)
-+ ? m->wy + m->wh - y - 2 * c->bw : h - 2 * c->bw), False);
-+ if(h != m->wh)
-+ y = c->y + HEIGHT(c);
-+ }
- }
- }
diff --git a/dwm.suckless.org/patches/dwm-clientspertag-5.6.1.diff b/dwm.suckless.org/patches/dwm-clientspertag-5.6.1.diff
new file mode 100644
index 0000000..e32a3e4
--- /dev/null
+++ b/dwm.suckless.org/patches/dwm-clientspertag-5.6.1.diff
_AT_@ -0,0 +1,71 @@
+diff -ru dwm-5.6.1/dwm.c dwm-5.6.1-cpt/dwm.c
+--- dwm-5.6.1/dwm.c 2009-07-26 15:01:50.000000000 +0200
++++ dwm-5.6.1-cpt/dwm.c 2009-09-13 18:08:50.000000000 +0200
+_AT_@ -268,12 +268,23 @@
+ static Window root;
+
+ /* configuration, allows nested code to access above variables */
++static int cpt = -1;
++static void clientspertag(const Arg *arg) {
++ const char *cmd = (const char *)arg->v;
++ if (cmd[0]=='^') {
++ if (cpt==-1) cpt = atoi(cmd+1);
++ else if (cpt==atoi(cmd+1)) cpt = -1;
++ else cpt = atoi(cmd+1);
++ } else cpt = atoi(cmd);
++ arrange();
++}
+ #include "config.h"
+
+ /* compile-time check if all tags fit into an unsigned int bit array. */
+ struct NumTags { char limitexceeded[LENGTH(tags) > 31 ? -1 : 1]; };
+
+ /* function implementations */
++
+ void
+ applyrules(Client *c) {
+ const char *class, *instance;
+_AT_@ -674,7 +685,7 @@
+ drawtext(m->lt[m->sellt]->symbol, dc.norm, False);
+ dc.x += dc.w;
+ }
+- snprintf(ntext, sizeof ntext, "%u", n);
++ snprintf(ntext, sizeof ntext, "%d/%u", cpt, n);
+ dc.w = TEXTW(ntext);
+ drawtext(ntext, dc.norm, False);
+ x = (dc.x += dc.w);
+_AT_@ -1435,6 +1446,7 @@
+ sw = DisplayWidth(dpy, screen);
+ sh = DisplayHeight(dpy, screen);
+ bh = dc.h = dc.font.height + 2;
++ cpt = -1;
+ updategeom();
+ /* init atoms */
+ wmatom[WMProtocols] = XInternAtom(dpy, "WM_PROTOCOLS", False);
+_AT_@ -1549,6 +1561,7 @@
+ for(n = 0, c = nexttiled(m->clients); c; c = nexttiled(c->next), n++);
+ if(n == 0)
+ return;
++ if (cpt!=-1 && n>cpt) n = cpt;
+ /* master */
+ c = nexttiled(m->clients);
+ mw = m->mfact * m->ww;
+_AT_@ -1563,10 +1576,15 @@
+ if(h < bh)
+ h = m->wh;
+ for(i = 0, c = nexttiled(c->next); c; c = nexttiled(c->next), i++) {
+- resize(c, x, y, w - 2 * c->bw, /* remainder */ ((i + 1 == n)
+- ? m->wy + m->wh - y - 2 * c->bw : h - 2 * c->bw), False);
+- if(h != m->wh)
+- y = c->y + HEIGHT(c);
++ if (cpt!=-1 && i>=cpt) {
++ resize(c, x, m->wy, w - 2 * c->bw, /* remainder */ ((i + 1 == n)
++ ? m->wy + m->wh - y - 2 * c->bw : h - 2 * c->bw), False);
++ } else {
++ resize(c, x, y, w - 2 * c->bw, /* remainder */ ((i + 1 == n)
++ ? m->wy + m->wh - y - 2 * c->bw : h - 2 * c->bw), False);
++ if(h != m->wh)
++ y = c->y + HEIGHT(c);
++ }
+ }
+ }
Received on Thu Jul 14 2016 - 02:25:14 CEST

This archive was generated by hypermail 2.3.0 : Thu Jul 14 2016 - 02:36:21 CEST