client.c
changeset 377 b1159a638d0a
parent 372 a9b4077ec058
child 378 83576f5f0a90
equal deleted inserted replaced
376:201acf925788 377:b1159a638d0a
    50 }
    50 }
    51 
    51 
    52 static void
    52 static void
    53 resizetitle(Client *c)
    53 resizetitle(Client *c)
    54 {
    54 {
    55 	int i;
       
    56 
       
    57 	c->tw = textw(c->name);
    55 	c->tw = textw(c->name);
    58 	if(c->tw > c->w)
    56 	if(c->tw > c->w)
    59 		c->tw = c->w + 2;
    57 		c->tw = c->w + 2;
    60 	c->tx = c->x + c->w - c->tw + 2;
    58 	c->tx = c->x + c->w - c->tw + 2;
    61 	c->ty = c->y;
    59 	c->ty = c->y;
   338 
   336 
   339 void
   337 void
   340 settitle(Client *c)
   338 settitle(Client *c)
   341 {
   339 {
   342 	char **list = NULL;
   340 	char **list = NULL;
   343 	int i, n;
   341 	int n;
   344 	XTextProperty name;
   342 	XTextProperty name;
   345 
   343 
   346 	name.nitems = 0;
   344 	name.nitems = 0;
   347 	c->name[0] = 0;
   345 	c->name[0] = 0;
   348 	XGetTextProperty(dpy, c->win, &name, netatom[NetWMName]);
   346 	XGetTextProperty(dpy, c->win, &name, netatom[NetWMName]);