X-Git-Url: https://jasonwoof.com/gitweb/?p=dwm.git;a=blobdiff_plain;f=draw.c;h=de4bdb0e4feb377d2a3803d8c9076d35f7ebd9dd;hp=1c6613f3249009eebf0c3256b8a2fca8de5f4924;hb=1f9614f82e14fa3a46e0db05346b41d6be611f88;hpb=c09bf8da071e05e2c1d714f0d31d41fe944bc11b diff --git a/draw.c b/draw.c index 1c6613f..de4bdb0 100644 --- a/draw.c +++ b/draw.c @@ -8,7 +8,7 @@ #include #include -/* static functions */ +/* static */ static void drawborder(void) @@ -90,14 +90,14 @@ drawtext(const char *text, Bool invert, Bool border) } } -/* extern functions */ +/* extern */ void drawall() { Client *c; - for(c = clients; c; c = getnext(c->next)) + for(c = clients; c; c = getnext(c->next, tsel)) drawtitle(c); drawstatus(); } @@ -131,7 +131,7 @@ drawstatus() drawtext(stext, !istile, False); XCopyArea(dpy, dc.drawable, barwin, dc.gc, 0, 0, bw, bh, 0, 0); - XFlush(dpy); + XSync(dpy, False); } void @@ -163,9 +163,8 @@ drawtitle(Client *c) dc.x += dc.w; dc.w = textw(c->name); drawtext(c->name, !istile, True); - XCopyArea(dpy, dc.drawable, c->title, dc.gc, - 0, 0, c->tw, c->th, 0, 0); - XFlush(dpy); + XCopyArea(dpy, dc.drawable, c->title, dc.gc, 0, 0, c->tw, c->th, 0, 0); + XSync(dpy, False); } unsigned long