sw/qa/extras/ooxmlexport/data/tdf104420_lostParagraph.docx |binary sw/qa/extras/ooxmlexport/ooxmlexport9.cxx | 6 ++++++ writerfilter/source/dmapper/DomainMapper.cxx | 3 ++- 3 files changed, 8 insertions(+), 1 deletion(-)
New commits: commit b71c09a31c245f2fc1e1ff3760206bb121869633 Author: Justin Luth <justin_l...@sil.org> Date: Tue Dec 6 19:20:51 2016 +0300 tdf#104420 writerfilter: no dummy para in headers Change-Id: I22bf2d85e01ce5a084babdc07a11ada0790f4933 Reviewed-on: https://gerrit.libreoffice.org/31710 Tested-by: Jenkins <c...@libreoffice.org> Reviewed-by: Justin Luth <justin_l...@sil.org> diff --git a/sw/qa/extras/ooxmlexport/data/tdf104420_lostParagraph.docx b/sw/qa/extras/ooxmlexport/data/tdf104420_lostParagraph.docx new file mode 100755 index 0000000..b5d9988 Binary files /dev/null and b/sw/qa/extras/ooxmlexport/data/tdf104420_lostParagraph.docx differ diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport9.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport9.cxx index f4bd83e..57768cd 100644 --- a/sw/qa/extras/ooxmlexport/ooxmlexport9.cxx +++ b/sw/qa/extras/ooxmlexport/ooxmlexport9.cxx @@ -55,6 +55,12 @@ DECLARE_OOXMLEXPORT_TEST(testTdf89377, "tdf89377_tableWithBreakBeforeParaStyle.d CPPUNIT_ASSERT_EQUAL( 3, getPages() ); } +DECLARE_OOXMLEXPORT_TEST(testTdf104420, "tdf104420_lostParagraph.docx") +{ + // the add/remove dummy paragraph was losing an entire header and paragraph + CPPUNIT_ASSERT_EQUAL( 2, getPages() ); +} + DECLARE_OOXMLEXPORT_TEST(testTdf41542_borderlessPadding, "tdf41542_borderlessPadding.odt") { // the page style's borderless padding should force this to 3 pages, not 1 diff --git a/writerfilter/source/dmapper/DomainMapper.cxx b/writerfilter/source/dmapper/DomainMapper.cxx index 439ecf2..929671a 100644 --- a/writerfilter/source/dmapper/DomainMapper.cxx +++ b/writerfilter/source/dmapper/DomainMapper.cxx @@ -2547,7 +2547,8 @@ void DomainMapper::sprmWithProps( Sprm& rSprm, const PropertyMapPtr& rContext ) * and remove it again when lcl_endSectionGroup is called */ if(m_pImpl->m_nTableDepth == 0 && m_pImpl->GetIsFirstParagraphInSection() - && !m_pImpl->GetIsDummyParaAddedForTableInSection() && !m_pImpl->GetIsTextFrameInserted()) + && !m_pImpl->GetIsDummyParaAddedForTableInSection() && !m_pImpl->GetIsTextFrameInserted() + && !IsInHeaderFooter()) { m_pImpl->AddDummyParaForTableInSection(); } _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits