Evas font-engine: Fixes last commit to not seg when not using OT.
authortasn <tasn@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Tue, 26 Apr 2011 14:20:45 +0000 (14:20 +0000)
committertasn <tasn@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Tue, 26 Apr 2011 14:20:45 +0000 (14:20 +0000)
git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/evas@58936 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

src/lib/engines/common/evas_font_draw.c
src/lib/engines/common/evas_text_utils.c

index 5ec77f6..91ef164 100644 (file)
@@ -521,6 +521,9 @@ evas_common_font_draw_internal(RGBA_Image *dst, RGBA_Draw_Context *dc, RGBA_Font
 #endif
 
    im = dst->image.data;
+#ifdef OT_SUPPORT
+   /* FIXME-tom: Should be applied to non-ot as well once we are capable of
+    * doing it */
    fi = text_props->font_instance;
    evas_common_font_int_reload(fi);
 
@@ -531,6 +534,7 @@ evas_common_font_draw_internal(RGBA_Image *dst, RGBA_Draw_Context *dc, RGBA_Font
         FTUNLOCK();
         fi->src->current_size = fi->size;
      }
+#endif
 
    EVAS_FONT_WALK_TEXT_START()
      {
@@ -836,6 +840,9 @@ evas_font_word_prerender(RGBA_Draw_Context *dc, const Eina_Unicode *in_text, con
    gl = dc->font_ext.func.gl_new ? 1: 0;
 
    above = 0; below = 0; baseline = 0; height = 0; descent = 0;
+#ifdef OT_SUPPORT
+   /* FIXME-tom: Should be applied to non-ot as well once we are capable of
+    * doing it */
    fi = text_props->font_instance;
    evas_common_font_int_reload(fi);
 
@@ -846,6 +853,7 @@ evas_font_word_prerender(RGBA_Draw_Context *dc, const Eina_Unicode *in_text, con
         FTUNLOCK();
         fi->src->current_size = fi->size;
      }
+#endif
 
    /* First pass: Work out how big and populate */
    /* It's a bit hackish to use index and fg here as they are internal,
index 83c7d89..4aa46ee 100644 (file)
@@ -290,6 +290,9 @@ evas_common_text_props_content_create(void *_fn, const Eina_Unicode *text,
         gl_itr++;
      }
 #else
+   /* FIXME: Move outside when we can (read comment above). */
+   text_props->font_instance = NULL;
+
    /* We are walking the string in visual ordering */
    Evas_Font_Glyph_Info *gl_itr;
    Eina_Bool use_kerning;