diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2018-07-02 20:31:32 +1000 |
---|---|---|
committer | Aron Budea <aron.budea@collabora.com> | 2018-07-09 09:11:39 +0200 |
commit | aeacbbee40de4009c60a28e39c3698eeeb85f566 (patch) | |
tree | 8cefa785b0d0097fb3cad28d1ec9e0edaeb7070c /test | |
parent | 8b5a12fb5423326e84fb42fdd68fa31acaa1d331 (diff) |
tdf#117923: handle direct formatting for numbering in .doc
Since commit df07d6cb9f62c0a2c4b29bd850d4efb4fcd4790b, we do for DOCX.
DOC also has this problem, so set the relevant compatibility flag on
import for this format, too.
Change-Id: I3aef593341edffa878a06566da815cb72aa38004
Reviewed-on: https://gerrit.libreoffice.org/56812
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/57048
Tested-by: Aron Budea <aron.budea@collabora.com>
Reviewed-by: Aron Budea <aron.budea@collabora.com>
Diffstat (limited to 'test')
-rw-r--r-- | test/source/xmltesttools.cxx | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/test/source/xmltesttools.cxx b/test/source/xmltesttools.cxx index 57baa91fe9f6..7a6f035fc986 100644 --- a/test/source/xmltesttools.cxx +++ b/test/source/xmltesttools.cxx @@ -88,7 +88,12 @@ OUString XmlTestTools::getXPathContent(xmlDocPtr pXmlDoc, const OString& rXPath) xmlXPathNodeSetGetLength(pXmlNodes) > 0); xmlNodePtr pXmlNode = pXmlNodes->nodeTab[0]; - OUString s(convert((pXmlNode->children[0]).content)); + xmlNodePtr pXmlChild = pXmlNode->children; + OUString s; + while (pXmlChild && pXmlChild->type != XML_TEXT_NODE) + pXmlChild = pXmlChild->next; + if (pXmlChild && pXmlChild->type == XML_TEXT_NODE) + s = convert(pXmlChild->content); xmlXPathFreeObject(pXmlObj); return s; } |