fix textblock parsing of tags with stupid trailing spaces like <br /> which people...
authordiscomfitor <discomfitor@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Thu, 22 Dec 2011 03:32:23 +0000 (03:32 +0000)
committerdiscomfitor <discomfitor@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Thu, 22 Dec 2011 03:32:23 +0000 (03:32 +0000)
git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/evas@66444 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

src/lib/canvas/evas_object_textblock.c

index 64f3d27..0646eb4 100644 (file)
@@ -5173,7 +5173,11 @@ evas_textblock_text_markup_to_utf8(const Evas_Object *obj, const char *text)
                   tag_start++; /* Skip the < */
                   tag_end--; /* Skip the > */
                   if ((tag_end > tag_start) && (*(tag_end - 1) == '/'))
-                     tag_end --; /* Skip the terminating '/' */
+                    {
+                       tag_end --; /* Skip the terminating '/' */
+                       while (*(tag_end - 1) == ' ')
+                         tag_end--; /* skip trailing ' ' */
+                    }
 
                   ttag_len = tag_end - tag_start;