summaryrefslogtreecommitdiff
path: root/sw/qa/extras
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.co.uk>2016-01-12 09:06:49 +0100
committerMiklos Vajna <vmiklos@collabora.co.uk>2016-01-12 09:07:16 +0100
commitb0058366190b63fcbc112b43d387f7600a7fe55d (patch)
tree8eea47c8653d19e2dc7e81d96f269c1663593f79 /sw/qa/extras
parent813a319fe836d1ed1c967928bc044643d0b4c07d (diff)
tdf#61511 RTF export: handle page background solid color fill
Change-Id: I562419b6d4fb791ef5b255effe9a4510d930bdbc
Diffstat (limited to 'sw/qa/extras')
-rw-r--r--sw/qa/extras/rtfexport/data/page-background.rtf (renamed from sw/qa/extras/rtfimport/data/page-background.rtf)2
-rw-r--r--sw/qa/extras/rtfexport/rtfexport.cxx7
-rw-r--r--sw/qa/extras/rtfimport/rtfimport.cxx7
3 files changed, 8 insertions, 8 deletions
diff --git a/sw/qa/extras/rtfimport/data/page-background.rtf b/sw/qa/extras/rtfexport/data/page-background.rtf
index e19d2d4c3547..68c3ccf8dc9c 100644
--- a/sw/qa/extras/rtfimport/data/page-background.rtf
+++ b/sw/qa/extras/rtfexport/data/page-background.rtf
@@ -1,6 +1,6 @@
{\rtf1\adeflang1025\ansi\ansicpg1252\uc1\adeff31507\deff0\stshfdbch31506\stshfloch31506\stshfhich31506\stshfbi31507\deflang1033\deflangfe1033\themelang1033\themelangfe0\themelangcs0
\viewbksp1
-{\*\background
+{\*\background
{\shp
{\*\shpinst\shpleft0\shptop0\shpright0\shpbottom0\shpfhdr0\shpbxmargin\shpbxignore\shpbymargin\shpbyignore\shpwr0\shpwrk0\shpfblwtxt1
{\sp
diff --git a/sw/qa/extras/rtfexport/rtfexport.cxx b/sw/qa/extras/rtfexport/rtfexport.cxx
index 58dadbc7dddd..f39e01345fc7 100644
--- a/sw/qa/extras/rtfexport/rtfexport.cxx
+++ b/sw/qa/extras/rtfexport/rtfexport.cxx
@@ -966,6 +966,13 @@ DECLARE_RTFEXPORT_TEST(testTdf94377, "tdf94377.rtf")
CPPUNIT_ASSERT_EQUAL(12.f, getProperty<float>(getRun(getParagraphOfText(2, xText, "asdf12"), 1), "CharHeight"));
}
+DECLARE_RTFEXPORT_TEST(testPageBackground, "page-background.rtf")
+{
+ // The problem was that \background was ignored.
+ uno::Reference<beans::XPropertySet> xPageStyle(getStyles("PageStyles")->getByName(DEFAULT_STYLE), uno::UNO_QUERY);
+ CPPUNIT_ASSERT_EQUAL(sal_Int32(0x92D050), getProperty<sal_Int32>(xPageStyle, "BackColor"));
+}
+
CPPUNIT_PLUGIN_IMPLEMENT();
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sw/qa/extras/rtfimport/rtfimport.cxx b/sw/qa/extras/rtfimport/rtfimport.cxx
index 5e1749fc12ec..43d0fcb891f1 100644
--- a/sw/qa/extras/rtfimport/rtfimport.cxx
+++ b/sw/qa/extras/rtfimport/rtfimport.cxx
@@ -1221,13 +1221,6 @@ DECLARE_RTFIMPORT_TEST(testFdo64671, "fdo64671.rtf")
getRun(getParagraph(1), 1, OUString("\xC5\xBD", 2, RTL_TEXTENCODING_UTF8));
}
-DECLARE_RTFIMPORT_TEST(testPageBackground, "page-background.rtf")
-{
- // The problem was that \background was ignored.
- uno::Reference<beans::XPropertySet> xPageStyle(getStyles("PageStyles")->getByName(DEFAULT_STYLE), uno::UNO_QUERY);
- CPPUNIT_ASSERT_EQUAL(sal_Int32(0x92D050), getProperty<sal_Int32>(xPageStyle, "BackColor"));
-}
-
DECLARE_RTFIMPORT_TEST(testFdo81944, "fdo81944.rtf")
{
// font properties in style were not imported