Evas textblock: Fixed a major bug in last_at_off.
authortasn <tasn@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Wed, 8 Dec 2010 15:41:21 +0000 (15:41 +0000)
committertasn <tasn@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Wed, 8 Dec 2010 15:41:21 +0000 (15:41 +0000)
git-svn-id: http://svn.enlightenment.org/svn/e/trunk/evas@55375 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

src/lib/canvas/evas_object_textblock.c

index d41ea9c..305d809 100644 (file)
@@ -4047,14 +4047,16 @@ static Evas_Object_Textblock_Node_Format *
 _evas_textblock_node_format_last_at_off(const Evas_Object_Textblock_Node_Format *n)
 {
    const Evas_Object_Textblock_Node_Format *nnode;
+   const Evas_Object_Textblock_Node_Text *tnode;
    if (!n) return NULL;
    nnode = n;
+   tnode = n->text_node;
    do
      {
         n = nnode;
         nnode = _NODE_FORMAT(EINA_INLIST_GET(nnode)->next);
      }
-   while (nnode && (nnode->offset == 0));
+   while (nnode && (nnode->text_node == tnode) && (nnode->offset == 0));
 
    return (Evas_Object_Textblock_Node_Format *) n;
 }