aewl

changeset 72:d0eb0bb63c40

I prefer the tiled/floating indicator on the right side
author Anselm R. Garbe <garbeam@wmii.de>
date Fri, 14 Jul 2006 18:59:25 +0200
parents 7681ef838201
children c2ddb9dbbd10
files bar.c
diffstat 1 files changed, 9 insertions(+), 5 deletions(-) [+]
line diff
     1.1 --- a/bar.c	Fri Jul 14 18:55:50 2006 +0200
     1.2 +++ b/bar.c	Fri Jul 14 18:59:25 2006 +0200
     1.3 @@ -22,16 +22,15 @@
     1.4  void
     1.5  draw_bar()
     1.6  {
     1.7 -	int i;
     1.8 +	int i, modw;
     1.9  	char *mode = arrange == tiling ? "#" : "~";
    1.10  
    1.11  	dc.x = dc.y = 0;
    1.12  	dc.w = bw;
    1.13  	drawtext(NULL, False, False);
    1.14  
    1.15 -	dc.w = textw(mode) + dc.font.height;
    1.16 -	drawtext(mode, True, True);
    1.17 -
    1.18 +	modw = textw(mode) + dc.font.height;
    1.19 +	dc.w = 0;
    1.20  	for(i = 0; i < TLast; i++) {
    1.21  		dc.x += dc.w;
    1.22  		dc.w = textw(tags[i]) + dc.font.height;
    1.23 @@ -43,8 +42,13 @@
    1.24  		drawtext(sel->name, True, True);
    1.25  	}
    1.26  	dc.w = textw(stext) + dc.font.height;
    1.27 -	dc.x = bx + bw - dc.w;
    1.28 +	dc.x = bx + bw - dc.w - modw;
    1.29  	drawtext(stext, False, False);
    1.30 +
    1.31 +	dc.x = bx + bw - modw;
    1.32 +	dc.w = modw;
    1.33 +	drawtext(mode, True, True);
    1.34 +
    1.35  	XCopyArea(dpy, dc.drawable, barwin, dc.gc, 0, 0, bw, bh, 0, 0);
    1.36  	XFlush(dpy);
    1.37  }