summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKatarina Behrens <Katarina.Behrens@cib.de>2015-06-17 21:06:37 +0200
committerKatarina Behrens <Katarina.Behrens@cib.de>2015-06-18 10:07:31 +0200
commitf3b51162b68acc7b22c2c5b41a8b29038153afab (patch)
tree88c4e115b3ce575c3aad7af0c86e9a9085549ffa
parentf03f2489edfb02150a147e071a81b46c5c27c606 (diff)
Bugfix test for tdf#88295
Change-Id: Ic9c4330e9b14e43448302132b6c01a8d93001d2f
-rw-r--r--sd/qa/unit/data/odp/transparent_background.odpbin0 -> 11687 bytes
-rw-r--r--sd/qa/unit/export-tests.cxx19
2 files changed, 19 insertions, 0 deletions
diff --git a/sd/qa/unit/data/odp/transparent_background.odp b/sd/qa/unit/data/odp/transparent_background.odp
new file mode 100644
index 000000000000..ce599db54c17
--- /dev/null
+++ b/sd/qa/unit/data/odp/transparent_background.odp
Binary files differ
diff --git a/sd/qa/unit/export-tests.cxx b/sd/qa/unit/export-tests.cxx
index f82b523f53e5..4149a302f5fe 100644
--- a/sd/qa/unit/export-tests.cxx
+++ b/sd/qa/unit/export-tests.cxx
@@ -121,6 +121,7 @@ public:
void testBulletColor();
void testBulletMarginAndIndentation();
void testParaMarginAndindentation();
+ void testTransparentBackground();
void testFdo90607();
#if !defined WNT
@@ -155,6 +156,7 @@ public:
CPPUNIT_TEST(testBulletColor);
CPPUNIT_TEST(testBulletMarginAndIndentation);
CPPUNIT_TEST(testParaMarginAndindentation);
+ CPPUNIT_TEST(testTransparentBackground);
#if !defined WNT
CPPUNIT_TEST(testBnc822341);
@@ -333,6 +335,23 @@ void SdExportTest::testN828390_5()
xDocShRef->DoClose();
}
+void SdExportTest::testTransparentBackground()
+{
+ ::sd::DrawDocShellRef xDocShRef = loadURL(getURLFromSrc("/sd/qa/unit/data/odp/transparent_background.odp"), ODP);
+ xDocShRef = saveAndReload( xDocShRef, ODP );
+
+ SdDrawDocument *pDoc = xDocShRef->GetDoc();
+ CPPUNIT_ASSERT_MESSAGE( "no document", pDoc != NULL );
+ const SdrPage *pPage = pDoc->GetPage (1);
+ CPPUNIT_ASSERT_MESSAGE( "no page", pPage != NULL );
+
+ const SdrTextObj *pObj1 = dynamic_cast<SdrTextObj *>( pPage->GetObj( 0 ) );
+ checkFontAttributes<Color, SvxBackgroundColorItem>( pObj1, Color(COL_TRANSPARENT) );
+
+ const SdrTextObj *pObj2 = dynamic_cast<SdrTextObj *>( pPage->GetObj( 1 ) );
+ checkFontAttributes<Color, SvxBackgroundColorItem>( pObj2, Color(COL_YELLOW));
+}
+
void SdExportTest::testMediaEmbedding()
{
::sd::DrawDocShellRef xDocShRef = loadURL(getURLFromSrc("/sd/qa/unit/data/media_embedding.odp"), ODP);