Evas textblock: Fixed an issue with in-line valign.
authortasn <tasn@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Thu, 14 Jul 2011 12:31:24 +0000 (12:31 +0000)
committertasn <tasn@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Thu, 14 Jul 2011 12:31:24 +0000 (12:31 +0000)
Thanks to SeoZ for the report.

git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/evas@61365 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

src/lib/canvas/evas_object_textblock.c

index 6d01ad1..043c040 100644 (file)
@@ -8461,12 +8461,13 @@ evas_object_textblock_render(Evas_Object *obj, void *output, void *context, void
                } \
              EINA_INLIST_FOREACH(ln->items, itr) \
                { \
-                  int yoff; \
+                  Evas_Coord yoff; \
                   yoff = ln->baseline; \
+                  /* FIXME: This looks correct, but it breaks stuff....
+                   * yoff = (itr->type == EVAS_TEXTBLOCK_ITEM_TEXT) ? \
+                     _ITEM_TEXT(itr)->baseline : ln->baseline; */ \
                   if (itr->format->valign != -1.0) \
-                     yoff = (itr->format->valign * (double)(ln->h - itr->h)) + \
-                     (itr->type == EVAS_TEXTBLOCK_ITEM_TEXT) ? \
-                     _ITEM_TEXT(itr)->baseline : ln->baseline; \
+                     yoff += itr->format->valign * (ln->h - itr->h); \
                   if (clip) \
                     { \
                        if ((obj->cur.geometry.x + x + ln->x + itr->x + itr->w) < (cx - 20)) \