about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorAnselm R. Garbe <arg@10kloc.org>2006-08-22 19:55:20 +0200
committerAnselm R. Garbe <arg@10kloc.org>2006-08-22 19:55:20 +0200
commitdc83b9e988d12bd59ac7a5ab425308fc46ae5ed2 (patch)
tree92d4579a05b0bdcefb76eb26e196bdb9ab7c3119
parent8b4bc8270a975a14c1fb7db0a94d83f4ba4d2734 (diff)
downloaddwm-dc83b9e988d12bd59ac7a5ab425308fc46ae5ed2.tar.gz
titlebars contain tags in the right now
-rw-r--r--draw.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/draw.c b/draw.c
index 0ded26b..2ccaf6a 100644
--- a/draw.c
+++ b/draw.c
@@ -149,18 +149,17 @@ drawtitle(Client *c)
 	XSetWindowBorder(dpy, c->win, dc.bg);
 	XMapWindow(dpy, c->title);
 
-	dc.x = dc.y = 0;
-
-	dc.w = 0;
+	dc.y = dc.w = 0;
+	dc.x = c->tw;
 	for(i = 0; i < ntags; i++) {
 		if(c->tags[i]) {
-			dc.x += dc.w;
 			dc.w = textw(tags[i]);
+			dc.x -= dc.w;
 			drawtext(tags[i], !istile);
 		}
 	}
-	dc.x += dc.w;
-	dc.w = c->tw - dc.x;
+	dc.w = dc.x;
+	dc.x = 0;
 	drawtext(c->name, !istile);
 	XCopyArea(dpy, dc.drawable, c->title, dc.gc, 0, 0, c->tw, c->th, 0, 0);
 	XSync(dpy, False);
548588a79c1093e6372555f2c'>ecc95c9 ^
12b1d43 ^
9ed5de0 ^

d7e1708 ^
71fd06f ^




95766d6 ^
1076f2b
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29