also, don't set the font all the time

This commit is contained in:
Anselm R. Garbe
2007-03-02 15:16:36 +01:00
parent 5b8dce15d3
commit 724f72142f
3 changed files with 7 additions and 12 deletions

2
main.c
View File

@ -493,6 +493,8 @@ main(int argc, char *argv[]) {
dc.drawable = XCreatePixmap(dpy, root, mw, mh, DefaultDepth(dpy, screen));
dc.gc = XCreateGC(dpy, root, 0, 0);
XSetLineAttributes(dpy, dc.gc, 1, LineSolid, CapButt, JoinMiter);
if(!dc.font.set)
XSetFont(dpy, dc.gc, dc.font.xfont->fid);
if(maxname)
cmdw = textw(maxname);
if(cmdw > mw / 3)