Evas textblock: Fixed evas_textblock_range_text_get that didn't work on textblocks...
authortasn <tasn@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Thu, 16 Sep 2010 07:12:23 +0000 (07:12 +0000)
committertasn <tasn@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Thu, 16 Sep 2010 07:12:23 +0000 (07:12 +0000)
git-svn-id: http://svn.enlightenment.org/svn/e/trunk/evas@52339 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

src/lib/canvas/evas_object_textblock.c

index 7bb7c86..f224598 100644 (file)
@@ -6170,10 +6170,13 @@ evas_textblock_cursor_range_text_get(const Evas_Textblock_Cursor *cur1, const Ev
           }
         /* Init the offset so the first one will count starting from cur1->pos
          * and not the previous format node */
-        if ((tnode == cur1->node) && fnode)
+        if (tnode == cur1->node)
           {
-             off = _evas_textblock_node_format_pos_get(fnode) -
-                cur1->pos - fnode->offset;
+             if (fnode)
+               {
+                  off = _evas_textblock_node_format_pos_get(fnode) -
+                     cur1->pos - fnode->offset;
+               }
              text += cur1->pos;
           }
         else