summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.co.uk>2015-07-06 09:09:41 +0200
committerMichael Stahl <mstahl@redhat.com>2015-07-06 22:09:54 +0000
commitff3a1d983acc04715e16373c1ca8cc64dafdccd0 (patch)
treeaf76f361e7e18e4033f010149f00f440fb99e2d6 /sw
parent135c3c567aeda1db3d81858cdad401b1df1d2504 (diff)
tdf#92481 RTF import: handle \widowctrl
(cherry picked from commit ffc7b671e213d366e59d39ddbbef66544ebf01e5) Change-Id: I1af1d6bc150c16a2c6b0fe788a41c8c18caee6c6 Reviewed-on: https://gerrit.libreoffice.org/16785 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Michael Stahl <mstahl@redhat.com>
Diffstat (limited to 'sw')
-rw-r--r--sw/qa/extras/rtfimport/data/tdf92481.rtf6
-rw-r--r--sw/qa/extras/rtfimport/rtfimport.cxx6
2 files changed, 12 insertions, 0 deletions
diff --git a/sw/qa/extras/rtfimport/data/tdf92481.rtf b/sw/qa/extras/rtfimport/data/tdf92481.rtf
new file mode 100644
index 000000000000..09a6c5e5934f
--- /dev/null
+++ b/sw/qa/extras/rtfimport/data/tdf92481.rtf
@@ -0,0 +1,6 @@
+{\rtf1
+\widowctrl
+\pard\plain
+Hello.
+\par
+}
diff --git a/sw/qa/extras/rtfimport/rtfimport.cxx b/sw/qa/extras/rtfimport/rtfimport.cxx
index 8a223584722e..99637e853d7e 100644
--- a/sw/qa/extras/rtfimport/rtfimport.cxx
+++ b/sw/qa/extras/rtfimport/rtfimport.cxx
@@ -2313,6 +2313,12 @@ DECLARE_RTFIMPORT_TEST(testTdf92061, "tdf92061.rtf")
CPPUNIT_ASSERT_EQUAL(OUString("body-after"), getRun(getParagraph(1), 3)->getString());
}
+DECLARE_RTFIMPORT_TEST(testTdf92481, "tdf92481.rtf")
+{
+ // This was 0, RTF_WIDOWCTRL was not imported.
+ CPPUNIT_ASSERT_EQUAL(static_cast<sal_Int8>(2), getProperty<sal_Int8>(getParagraph(1), "ParaWidows"));
+}
+
CPPUNIT_PLUGIN_IMPLEMENT();
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */