diff options
author | Rohit Deshmukh <rohit.deshmukh@synerzip.com> | 2014-01-22 18:03:21 +0530 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2014-02-06 15:54:57 +0100 |
commit | dcea8ba3b4fc347e7b6d9e0d5ec2fd99bd77ce6f (patch) | |
tree | c570da946b966abb17177cddc0a9653736d9861d | |
parent | d2d586446292db0747898bb0d6161637b76c33af (diff) |
Fix for Footer is missing if fisrt page different header/footer is set
Reviewed on:
https://gerrit.libreoffice.org/7589
Change-Id: I2a2f2abc0dcf5542b7b950f9a232d7155a055fdd
-rw-r--r-- | sw/qa/extras/ooxmlexport/data/testTitlePage.docx | bin | 0 -> 16479 bytes | |||
-rw-r--r-- | sw/qa/extras/ooxmlexport/ooxmlexport.cxx | 7 | ||||
-rw-r--r-- | sw/source/filter/ww8/wrtw8sty.cxx | 2 |
3 files changed, 8 insertions, 1 deletions
diff --git a/sw/qa/extras/ooxmlexport/data/testTitlePage.docx b/sw/qa/extras/ooxmlexport/data/testTitlePage.docx Binary files differnew file mode 100644 index 000000000000..72bfdf81f886 --- /dev/null +++ b/sw/qa/extras/ooxmlexport/data/testTitlePage.docx diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport.cxx index 1c820440f73d..dae77bc9bbb8 100644 --- a/sw/qa/extras/ooxmlexport/ooxmlexport.cxx +++ b/sw/qa/extras/ooxmlexport/ooxmlexport.cxx @@ -2637,6 +2637,13 @@ DECLARE_OOXMLEXPORT_TEST(testTOCFlag_u,"testTOCFlag_u.docx") OUString contents = OUString::createFromAscii((const char*)((pXmlNode->children[0]).content)); CPPUNIT_ASSERT(contents.match(" TOC \\z \\o \"1-9\" \\u \\h")); } +DECLARE_OOXMLEXPORT_TEST(testTestTitlePage, "testTitlePage.docx") +{ + xmlDocPtr pXmlDoc = parseExport("word/document.xml"); + if (!pXmlDoc) + return; + assertXPathChildren(pXmlDoc, "/w:document/w:body/w:sectPr/w:titlePg", 0); +} DECLARE_OOXMLEXPORT_TEST(testTableRowDataDisplayedTwice,"table-row-data-displayed-twice.docx") { diff --git a/sw/source/filter/ww8/wrtw8sty.cxx b/sw/source/filter/ww8/wrtw8sty.cxx index ab89a949577c..3f79db8ac02f 100644 --- a/sw/source/filter/ww8/wrtw8sty.cxx +++ b/sw/source/filter/ww8/wrtw8sty.cxx @@ -1747,7 +1747,7 @@ void MSWordExportBase::SectionProperties( const WW8_SepInfo& rSepInfo, WW8_PdAtt { const SwPageDesc *pFollow = pPd->GetFollow(); const SwFrmFmt& rFollowFmt = pFollow->GetMaster(); - if ( sw::util::IsPlausableSingleWordSection( *pPdFirstPgFmt, rFollowFmt ) ) + if ( sw::util::IsPlausableSingleWordSection( *pPdFirstPgFmt, rFollowFmt ) || titlePage ) { if (rSepInfo.pPDNd) pPdFirstPgFmt = pPd->GetPageFmtOfNode( *rSepInfo.pPDNd ); |