summaryrefslogtreecommitdiffstats
path: root/sd
diff options
context:
space:
mode:
authornd101 <Fong@nd.com.cn>2020-03-25 13:17:48 +0800
committerThorsten Behrens <Thorsten.Behrens@CIB.de>2020-04-02 21:40:50 +0200
commit55d423e8f371e914c51f9aa18aacede46355b133 (patch)
tree377eae7cfeca7710d5a6939aad4f388ae4aa9a9b /sd
parentResolves: tdf#131767 explicitly get the odt filter (diff)
downloadcore-55d423e8f371e914c51f9aa18aacede46355b133.tar.gz
core-55d423e8f371e914c51f9aa18aacede46355b133.zip
tdf#131554 placeholder iteration fails to stop when a match is found
Wrong placeholder is returned due to iteration not stopping when a match is found. It causes a text element position to be incorrectly set. Change-Id: I58be6825cec7a61f48b46418bdf28964c1afe4ce Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91023 Reviewed-by: Xisco FaulĂ­ <xiscofauli@libreoffice.org> Reviewed-by: Michael Stahl <michael.stahl@cib.de> Tested-by: Jenkins Signed-off-by: Xisco Fauli <xiscofauli@libreoffice.org> Reviewed-on: https://gerrit.libreoffice.org/c/core/+/91472 Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Diffstat (limited to 'sd')
-rw-r--r--sd/qa/unit/data/pptx/tdf131554.pptxbin0 -> 21065 bytes
-rw-r--r--sd/qa/unit/export-tests-ooxml2.cxx11
2 files changed, 11 insertions, 0 deletions
diff --git a/sd/qa/unit/data/pptx/tdf131554.pptx b/sd/qa/unit/data/pptx/tdf131554.pptx
new file mode 100644
index 000000000000..a65f423add39
--- /dev/null
+++ b/sd/qa/unit/data/pptx/tdf131554.pptx
Binary files differ
diff --git a/sd/qa/unit/export-tests-ooxml2.cxx b/sd/qa/unit/export-tests-ooxml2.cxx
index 78452a763f01..d0ef2dac0eb7 100644
--- a/sd/qa/unit/export-tests-ooxml2.cxx
+++ b/sd/qa/unit/export-tests-ooxml2.cxx
@@ -182,6 +182,7 @@ public:
void testTdf127372();
void testTdf127379();
void testTdf98603();
+ void testTdf131554();
CPPUNIT_TEST_SUITE(SdOOXMLExportTest2);
@@ -282,6 +283,7 @@ public:
CPPUNIT_TEST(testTdf127372);
CPPUNIT_TEST(testTdf127379);
CPPUNIT_TEST(testTdf98603);
+ CPPUNIT_TEST(testTdf131554);
CPPUNIT_TEST_SUITE_END();
@@ -2633,6 +2635,15 @@ void SdOOXMLExportTest2::testTdf98603()
CPPUNIT_ASSERT_EQUAL(OUString("IL"), aLocale.Country);
}
+void SdOOXMLExportTest2::testTdf131554()
+{
+ ::sd::DrawDocShellRef xDocShRef = loadURL(m_directories.getURLFromSrc("sd/qa/unit/data/pptx/tdf131554.pptx"), PPTX);
+ xDocShRef = saveAndReload( xDocShRef.get(), PPTX );
+ uno::Reference<drawing::XShape> xShape(getShapeFromPage(1, 0, xDocShRef), uno::UNO_QUERY);
+ CPPUNIT_ASSERT_EQUAL(static_cast<sal_Int32>(5622), xShape->getPosition().X);
+ CPPUNIT_ASSERT_EQUAL(static_cast<sal_Int32>(13251), xShape->getPosition().Y);
+}
+
CPPUNIT_TEST_SUITE_REGISTRATION(SdOOXMLExportTest2);
CPPUNIT_PLUGIN_IMPLEMENT();