From efedfae6a340bac4ad49843c178ae1b45a92352c Mon Sep 17 00:00:00 2001 From: Thorsten Behrens Date: Thu, 20 Jun 2024 23:38:43 +0200 Subject: Revert attempted clipboard fixes on branch This is a squashed revert, consisting of: * Revert "tdf#161054: drop support of last empty span as paragraph mark format" * Revert "tdf#161023: Empty spans may only define paragraph marks in text documents" * Revert "This block seems obsolete now, try to drop it" * Revert "Make sure to export autostyles from inside frames anchored to page" * Revert "tdf#160253: fix list identifier export decision code" --- sd/qa/unit/import-tests2.cxx | 52 -------------------------------------------- 1 file changed, 52 deletions(-) (limited to 'sd/qa/unit/import-tests2.cxx') diff --git a/sd/qa/unit/import-tests2.cxx b/sd/qa/unit/import-tests2.cxx index a69a30ef991a..ac730a24d6bf 100644 --- a/sd/qa/unit/import-tests2.cxx +++ b/sd/qa/unit/import-tests2.cxx @@ -1982,58 +1982,6 @@ CPPUNIT_TEST_FIXTURE(SdImportTest2, testMasterSlides) CPPUNIT_ASSERT_EQUAL(sal_Int32(7), xMasterPages->getCount()); } -CPPUNIT_TEST_FIXTURE(SdImportTest2, testTdf161023) -{ - // Given a shape with three paragraphs (18pt), all directly assigned a smaller font (10pt) - createSdImpressDoc("odp/tdf161023.fodp"); - auto shape = getShapeFromPage(0, 0); - - // 1st paragraph, not empty - { - auto paragraph(getParagraphFromShape(0, shape)); - CPPUNIT_ASSERT_EQUAL(u"a"_ustr, paragraph->getString()); - auto run(getRunFromParagraph(0, paragraph)); - CPPUNIT_ASSERT_EQUAL(u"a"_ustr, run->getString()); - uno::Reference xPropSet(run, uno::UNO_QUERY_THROW); - double fCharHeight = 0; - xPropSet->getPropertyValue("CharHeight") >>= fCharHeight; - CPPUNIT_ASSERT_EQUAL(10.0, fCharHeight); - // No more runs - CPPUNIT_ASSERT_THROW(getRunFromParagraph(1, paragraph), container::NoSuchElementException); - } - - // Empty 2nd paragraph, consisting of a single span: this span was treated as "paragraph mark" - { - auto paragraph(getParagraphFromShape(1, shape)); - CPPUNIT_ASSERT_EQUAL(u""_ustr, paragraph->getString()); - auto run(getRunFromParagraph(0, paragraph)); - CPPUNIT_ASSERT_EQUAL(u""_ustr, run->getString()); - uno::Reference xPropSet(run, uno::UNO_QUERY_THROW); - double fCharHeight = 0; - xPropSet->getPropertyValue("CharHeight") >>= fCharHeight; - // Without the fix, this would fail with - // - Expected: 10 - // - Actual : 18 - CPPUNIT_ASSERT_EQUAL(10.0, fCharHeight); - // No more runs - CPPUNIT_ASSERT_THROW(getRunFromParagraph(1, paragraph), container::NoSuchElementException); - } - - // 3rd paragraph, not empty - { - auto paragraph(getParagraphFromShape(2, shape)); - CPPUNIT_ASSERT_EQUAL(u"c"_ustr, paragraph->getString()); - auto run(getRunFromParagraph(0, paragraph)); - CPPUNIT_ASSERT_EQUAL(u"c"_ustr, run->getString()); - uno::Reference xPropSet(run, uno::UNO_QUERY_THROW); - double fCharHeight = 0; - xPropSet->getPropertyValue("CharHeight") >>= fCharHeight; - CPPUNIT_ASSERT_EQUAL(10.0, fCharHeight); - // No more runs - CPPUNIT_ASSERT_THROW(getRunFromParagraph(1, paragraph), container::NoSuchElementException); - } -} - CPPUNIT_PLUGIN_IMPLEMENT(); /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ -- cgit