|
|
|
@ -1,7 +1,7 @@
|
|
|
|
|
/* Settings */
|
|
|
|
|
#if !PERTAG_VANITYGAPS_PATCH || !PERTAG_PATCH
|
|
|
|
|
#if !PERTAG_VANITYGAPS_PATCH
|
|
|
|
|
static int enablegaps = 1;
|
|
|
|
|
#endif // PERTAG_VANITYGAPS_PATCH | PERTAG_PATCH
|
|
|
|
|
#endif // PERTAG_VANITYGAPS_PATCH
|
|
|
|
|
|
|
|
|
|
static void
|
|
|
|
|
setgaps(int oh, int ov, int ih, int iv)
|
|
|
|
@ -19,7 +19,7 @@ setgaps(int oh, int ov, int ih, int iv)
|
|
|
|
|
#if PERTAG_VANITYGAPS_PATCH && PERTAG_PATCH
|
|
|
|
|
selmon->pertag->gaps[selmon->pertag->curtag] =
|
|
|
|
|
((oh & 0xFF) << 0) | ((ov & 0xFF) << 8) | ((ih & 0xFF) << 16) | ((iv & 0xFF) << 24);
|
|
|
|
|
#endif // PERTAG_VANITYGAPS_PATCH | PERTAG_PATCH
|
|
|
|
|
#endif // PERTAG_VANITYGAPS_PATCH
|
|
|
|
|
|
|
|
|
|
arrange(selmon);
|
|
|
|
|
}
|
|
|
|
@ -72,7 +72,7 @@ setgapsex(const Arg *arg)
|
|
|
|
|
#else
|
|
|
|
|
if (!enablegaps)
|
|
|
|
|
enablegaps = 1;
|
|
|
|
|
#endif // PERTAG_VANITYGAPS_PATCH | PERTAG_PATCH
|
|
|
|
|
#endif // PERTAG_VANITYGAPS_PATCH
|
|
|
|
|
|
|
|
|
|
setgaps(oh, ov, ih, iv);
|
|
|
|
|
}
|
|
|
|
@ -85,7 +85,7 @@ togglegaps(const Arg *arg)
|
|
|
|
|
selmon->pertag->enablegaps[selmon->pertag->curtag] = !selmon->pertag->enablegaps[selmon->pertag->curtag];
|
|
|
|
|
#else
|
|
|
|
|
enablegaps = !enablegaps;
|
|
|
|
|
#endif // PERTAG_VANITYGAPS_PATCH | PERTAG_PATCH
|
|
|
|
|
#endif // PERTAG_VANITYGAPS_PATCH
|
|
|
|
|
arrange(NULL);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -177,11 +177,11 @@ static void
|
|
|
|
|
getgaps(Monitor *m, int *oh, int *ov, int *ih, int *iv, unsigned int *nc)
|
|
|
|
|
{
|
|
|
|
|
unsigned int n, oe, ie;
|
|
|
|
|
#if PERTAG_PATCH
|
|
|
|
|
#if PERTAG_VANITYGAPS_PATCH && PERTAG_PATCH
|
|
|
|
|
oe = ie = selmon->pertag->enablegaps[selmon->pertag->curtag];
|
|
|
|
|
#else
|
|
|
|
|
oe = ie = enablegaps;
|
|
|
|
|
#endif // PERTAG_PATCH
|
|
|
|
|
#endif // PERTAG_VANITYGAPS_PATCH
|
|
|
|
|
Client *c;
|
|
|
|
|
|
|
|
|
|
for (n = 0, c = nexttiled(m->clients); c; c = nexttiled(c->next), n++);
|
|
|
|
|