Evas textblock: Fixed a wrong test for end of string.
authortasn <tasn@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Wed, 13 Apr 2011 10:22:55 +0000 (10:22 +0000)
committertasn <tasn@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Wed, 13 Apr 2011 10:22:55 +0000 (10:22 +0000)
git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/evas@58624 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

src/lib/canvas/evas_object_textblock.c

index 406eedb..956472f 100644 (file)
@@ -3067,7 +3067,6 @@ _layout_get_word_mixwrap_common(Ctxt *c, Evas_Object_Textblock_Format *fmt,
    int orig_wrap;
    Eina_Unicode ch;
    const Eina_Unicode *str = GET_ITEM_TEXT(ti);
-   /* FIXME-tom: a lot of str[] to check if NULL, need to fix that. */
 
    wrap = _layout_text_cutoff_get(c, fmt, ti);
    /* Avoiding too small textblocks to even contain one char */
@@ -3101,7 +3100,7 @@ _layout_get_word_mixwrap_common(Ctxt *c, Evas_Object_Textblock_Format *fmt,
                     {
                        wrap = twrap;
                        ch = GET_PREV(str, wrap);
-                       return (str[wrap]) ? wrap : -1;
+                       return (!IS_AT_END(ti, wrap)) ? wrap : -1;
                     }
                }
           }