dwm-meillo

changeset 71:7681ef838201

bar shows if currently is tiled (Mod1-space) or floating (Mod1-Shift-space) mode
author Anselm R. Garbe <garbeam@wmii.de>
date Fri, 14 Jul 2006 18:55:50 +0200
parents e5fff8249705
children d0eb0bb63c40
files bar.c client.c
diffstat 2 files changed, 7 insertions(+), 1 deletions(-) [+]
line diff
     1.1 --- a/bar.c	Fri Jul 14 18:46:12 2006 +0200
     1.2 +++ b/bar.c	Fri Jul 14 18:55:50 2006 +0200
     1.3 @@ -23,11 +23,15 @@
     1.4  draw_bar()
     1.5  {
     1.6  	int i;
     1.7 +	char *mode = arrange == tiling ? "#" : "~";
     1.8 +
     1.9  	dc.x = dc.y = 0;
    1.10  	dc.w = bw;
    1.11  	drawtext(NULL, False, False);
    1.12  
    1.13 -	dc.w = 0;
    1.14 +	dc.w = textw(mode) + dc.font.height;
    1.15 +	drawtext(mode, True, True);
    1.16 +
    1.17  	for(i = 0; i < TLast; i++) {
    1.18  		dc.x += dc.w;
    1.19  		dc.w = textw(tags[i]) + dc.font.height;
     2.1 --- a/client.c	Fri Jul 14 18:46:12 2006 +0200
     2.2 +++ b/client.c	Fri Jul 14 18:55:50 2006 +0200
     2.3 @@ -120,6 +120,7 @@
     2.4  			focus(sel);
     2.5  		}
     2.6  	}
     2.7 +	draw_bar();
     2.8  }
     2.9  
    2.10  void
    2.11 @@ -176,6 +177,7 @@
    2.12  			focus(sel);
    2.13  		}
    2.14  	}
    2.15 +	draw_bar();
    2.16  }
    2.17  
    2.18  void