dwm

Mahdi's build of dwm
git clone git://mahdi.pw/dwm.git
Log | Files | Refs | README | LICENSE

dwm-underlinetags-6.2.diff (1605B)


      1 diff -pu dwm.git/config.def.h dwm.underlinetags/config.def.h
      2 --- dwm.git/config.def.h	2021-02-27 20:04:32.030570909 -0600
      3 +++ dwm.underlinetags/config.def.h	2021-03-16 16:42:26.278703624 -0500
      4 @@ -21,6 +21,11 @@ static const char *colors[][3]      = {
      5  /* tagging */
      6  static const char *tags[] = { "1", "2", "3", "4", "5", "6", "7", "8", "9" };
      7  
      8 +static const unsigned int ulinepad	= 5;	/* horizontal padding between the underline and tag */
      9 +static const unsigned int ulinestroke	= 2;	/* thickness / height of the underline */
     10 +static const unsigned int ulinevoffset	= 0;	/* how far above the bottom of the bar the line should appear */
     11 +static const int ulineall 		= 0;	/* 1 to show underline on all tags, 0 for just the active ones */
     12 +
     13  static const Rule rules[] = {
     14  	/* xprop(1):
     15  	 *	WM_CLASS(STRING) = instance, class
     16 diff -pu dwm.git/dwm.c dwm.underlinetags/dwm.c
     17 --- dwm.git/dwm.c	2021-02-27 20:04:32.030570909 -0600
     18 +++ dwm.underlinetags/dwm.c	2021-03-16 16:41:21.468077151 -0500
     19 @@ -719,6 +719,8 @@ drawbar(Monitor *m)
     20  		w = TEXTW(tags[i]);
     21  		drw_setscheme(drw, scheme[m->tagset[m->seltags] & 1 << i ? SchemeSel : SchemeNorm]);
     22  		drw_text(drw, x, 0, w, bh, lrpad / 2, tags[i], urg & 1 << i);
     23 +		if (ulineall || m->tagset[m->seltags] & 1 << i) /* if there are conflicts, just move these lines directly underneath both 'drw_setscheme' and 'drw_text' :) */
     24 +			drw_rect(drw, x + ulinepad, bh - ulinestroke - ulinevoffset, w - (ulinepad * 2), ulinestroke, 1, 0);
     25  		if (occ & 1 << i)
     26  			drw_rect(drw, x + boxs, boxs, boxw, boxw,
     27  				m == selmon && selmon->sel && selmon->sel->tags & 1 << i,