commit 58fa7998b8e7f34ed5723094d0b3952ccf2dc509
parent 3b01488153994d6936169165943470ba6e4303f3
Author: Anselm R. Garbe <garbeam@wmii.de>
Date: Fri, 19 May 2006 19:43:31 +0200
thx to keiss again, fixed the prevoff calculation as well
Diffstat:
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/cmd/wmiimenu.c b/cmd/wmiimenu.c
@@ -79,7 +79,10 @@ update_offsets()
w = cmdw + 2 * seek;
for(i = curroff; i > 0; i--) {
- w += blitz_textwidth(dpy, &draw.font, item.data[i]) + mrect.height;
+ tw = blitz_textwidth(dpy, &draw.font, item.data[i]);
+ if(tw > mrect.width / 3)
+ tw = mrect.width / 3;
+ w += tw + mrect.height;
if(w > mrect.width)
break;
}