X-Git-Url: http://git.hungrycats.org/cgi-bin/gitweb.cgi?p=xscreensaver;a=blobdiff_plain;f=driver%2Fsplash.c;h=ead36d7c1c38179eefc5377dc62650bf65b79fb3;hp=52c21ad6c0e21881df9b1c0e0bf5a5dfed72007e;hb=c494fd2e6b3b25582375d62e40f4f5cc984ca424;hpb=07faf451b99879183ed7e909e43a0e065be1ee7f diff --git a/driver/splash.c b/driver/splash.c index 52c21ad6..ead36d7c 100644 --- a/driver/splash.c +++ b/driver/splash.c @@ -87,10 +87,7 @@ draw_shaded_rectangle (Display *dpy, Window window, int string_width (XFontStruct *font, char *s) { - int direction, ascent, descent; - XCharStruct overall; - XTextExtents (font, s, strlen(s), &direction, &ascent, &descent, &overall); - return overall.width; + return XTextWidth(font, s, strlen(s)); }