From 64240f40eeb0a5c2bf3a4460be4a81a5dd99590a Mon Sep 17 00:00:00 2001 From: phillbush Date: Wed, 29 Jul 2020 22:59:25 -0300 Subject: [PATCH] changing the computation of the text y position --- xmenu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xmenu.c b/xmenu.c index 4a4ffca..4d1c223 100644 --- a/xmenu.c +++ b/xmenu.c @@ -671,7 +671,7 @@ drawtext(XftDraw *draw, XftColor *color, int x, int y, unsigned h, const char *t if (draw) { int texty; - texty = y + (h + currfont->ascent) / 2; + texty = y + (h - (currfont->ascent + currfont->descent))/2 + currfont->ascent; XftDrawStringUtf8(draw, color, currfont, x, texty, (XftChar8 *)s, len); x += ext.xOff;