SVG: tspan

Christina Roßmanith ChrRossmanith at gmx.de
Tue May 1 12:47:03 PDT 2012


Hi,

consider the following SVG example:

<svg><text><tspan>q</tspan></text></svg>

which is rendered blank instead of showing the letter 'q'.

<tspan> prevents q being added to sText here (svgreader.cxx):

visitChildren(boost::bind(
                                   (rtl::OUStringBuffer& 
(rtl::OUStringBuffer::*)(const rtl::OUString& 
str))&rtl::OUStringBuffer::append,
                                   boost::ref(sText),
                                   
boost::bind(&xml::dom::XNode::getNodeValue,
                                               _1)),
                               xElem,
                               xml::dom::NodeType_TEXT_NODE);

In visitChildren() an output of getNodeValue() shows that <tspan> has an 
empty value. Who is responsible for that??? I'd expect a value "q". Node 
type is NodeType_ELEMENT_NODE. Is that what is expected? Or should 
<tspan> and <text> both be treated as NodeType_TEXT_NODE?

Christina
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/libreoffice/attachments/20120501/e4eb9aed/attachment.html>


More information about the LibreOffice mailing list