]> Dogcows Code - chaz/openbox/commitdiff
set teh X so it gets used right
authorDana Jansens <danakj@orodu.net>
Wed, 25 Jun 2003 21:18:16 +0000 (21:18 +0000)
committerDana Jansens <danakj@orodu.net>
Wed, 25 Jun 2003 21:18:16 +0000 (21:18 +0000)
render/font.c

index e0a12a1a19bb9a6470fec532160596b558446027..9f1f5ef87385c92f97466e1cf3792597eb5da09b 100644 (file)
@@ -126,7 +126,7 @@ void RrFontDraw(XftDraw *d, RrTextureText *t, Rect *area)
     y = area->y +
         (area->height - RrFontHeight(t->font, t->shadow, t->offset)) / 2;
     /* the +2 and -4 leave a small blank edge on the sides */
-    x += 2;
+    x = area->x + 2;
     w = area->width - 4;
     h = area->height;
 
@@ -152,13 +152,12 @@ void RrFontDraw(XftDraw *d, RrTextureText *t, Rect *area)
 
     switch (t->justify) {
     case RR_JUSTIFY_LEFT:
-        x = area->x;
         break;
     case RR_JUSTIFY_RIGHT:
-        x = area->x + (w - mw);
+        x += (w - mw);
         break;
     case RR_JUSTIFY_CENTER:
-        x = area->x + (w - mw) / 2;
+        x += (w - mw) / 2;
         break;
     }
 
This page took 0.024308 seconds and 4 git commands to generate.