Kaydet (Commit) 4c31a0be authored tarafından Armin Le Grand's avatar Armin Le Grand Kaydeden (comit) Caolán McNamara

Resolves: #i125326# accept CssStyles with missing type attribute

(cherry picked from commit bb72d5b3)

Conflicts:
	svgio/source/svgreader/svgdocumenthandler.cxx

Change-Id: I5395c2cada92d5abcde9f6cc18bc237a58e77992
üst 4be799fc
......@@ -323,10 +323,26 @@ namespace svgio
{
SvgStyleNode* pNew = new SvgStyleNode(maDocument, mpTarget);
mpTarget = pNew;
const sal_uInt32 nAttributes(xAttribs->getLength());
if(0 == nAttributes)
{
// #i125326# no attributes, thus also no type="text/css". This is allowed to be missing,
// thus do mark this style as CssStyle. This is required to read the contained
// text (which defines the css style)
pNew->setTextCss(true);
}
else
{
// #i125326# there are attributes, read them. This will set isTextCss to true if
// a type="text/css" is contained as exact match, else not
mpTarget->parseAttributes(xAttribs);
}
if(pNew->isTextCss())
{
// if it is a Css style, allow reading text between the start and end tag (see
// SvgDocHdl::characters for details)
maCssContents.push_back(OUString());
}
break;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment