summaryrefslogtreecommitdiff
path: root/sd
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.com>2018-11-16 17:34:46 +0100
committerMiklos Vajna <vmiklos@collabora.com>2018-11-16 20:43:26 +0100
commitcd348a6244a092c251a8e1362cd78de562d7bef6 (patch)
tree466c0d97c656dd2b59d9dc1acb9c20b93a4eaa4b /sd
parentd28bea8bfa99b46460243173e95632923b9642a8 (diff)
oox smartart, accent process: add support for zorder offsets
The oox::drawingml::Shape -> css::drawing::XShape converter doesn't support ZOrder, so just give each drawingml::Shape a default ZOrder. This way the offsets can be applied, and sorting can move the shapes to their correct place. This makes parent text of the bugdoc readable. Change-Id: Ib87a096fba66aad4a4f35d19473ea88dab340fd0 Reviewed-on: https://gerrit.libreoffice.org/63478 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
Diffstat (limited to 'sd')
-rw-r--r--sd/qa/unit/import-tests-smartart.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/sd/qa/unit/import-tests-smartart.cxx b/sd/qa/unit/import-tests-smartart.cxx
index 898350abfba5..56c504e40b72 100644
--- a/sd/qa/unit/import-tests-smartart.cxx
+++ b/sd/qa/unit/import-tests-smartart.cxx
@@ -462,12 +462,13 @@ void SdImportTestSmartArt::testAccentProcess()
uno::Reference<drawing::XShape> xGroupShape(xGroup, uno::UNO_QUERY);
CPPUNIT_ASSERT(xGroupShape.is());
- // The pair if a parent (text + shape) and a child, so 3 shapes in total.
+ // The pair is a parent (shape + text) and a child, so 3 shapes in total.
+ // The order is importent, first is at the back, last is at the front.
uno::Reference<drawing::XShapes> xFirstPair(xGroup->getByIndex(0), uno::UNO_QUERY);
CPPUNIT_ASSERT(xFirstPair.is());
CPPUNIT_ASSERT_EQUAL(static_cast<sal_Int32>(3), xFirstPair->getCount());
- uno::Reference<text::XText> xFirstParentText(xFirstPair->getByIndex(0), uno::UNO_QUERY);
+ uno::Reference<text::XText> xFirstParentText(xFirstPair->getByIndex(1), uno::UNO_QUERY);
CPPUNIT_ASSERT(xFirstParentText.is());
CPPUNIT_ASSERT_EQUAL(OUString("a"), xFirstParentText->getString());
uno::Reference<drawing::XShape> xFirstParent(xFirstParentText, uno::UNO_QUERY);