diff options
-rw-r--r-- | sw/source/filter/ww8/rtfattributeoutput.cxx | 4 | ||||
-rw-r--r-- | sw/source/filter/ww8/rtfattributeoutput.hxx | 2 | ||||
-rw-r--r-- | sw/source/filter/ww8/rtfexport.cxx | 9 | ||||
-rw-r--r-- | sw/source/filter/ww8/rtfexport.hxx | 2 |
4 files changed, 9 insertions, 8 deletions
diff --git a/sw/source/filter/ww8/rtfattributeoutput.cxx b/sw/source/filter/ww8/rtfattributeoutput.cxx index fbd7206038cb..ab89690d97f9 100644 --- a/sw/source/filter/ww8/rtfattributeoutput.cxx +++ b/sw/source/filter/ww8/rtfattributeoutput.cxx @@ -1466,7 +1466,7 @@ void RtfAttributeOutput::WriteBookmarks_Impl( std::vector< rtl::OUString >& rSta rEnds.clear(); } -void RtfAttributeOutput::WriteHeaderFooter_Impl( const SwFrmFmt& rFmt, bool bHeader, const sal_Char* pStr ) +void RtfAttributeOutput::WriteHeaderFooter_Impl( const SwFrmFmt& rFmt, bool bHeader, const sal_Char* pStr, bool bTitlepg ) { OStringBuffer aSectionBreaks = m_aSectionBreaks; m_aSectionBreaks.setLength(0); @@ -1475,6 +1475,8 @@ void RtfAttributeOutput::WriteHeaderFooter_Impl( const SwFrmFmt& rFmt, bool bHea m_aSectionHeaders.append(bHeader ? OOO_STRING_SVTOOLS_RTF_HEADERY : OOO_STRING_SVTOOLS_RTF_FOOTERY); m_aSectionHeaders.append((sal_Int32)m_rExport.pAktPageDesc->GetMaster().GetULSpace().GetUpper()); + if (bTitlepg) + m_aSectionHeaders.append(OOO_STRING_SVTOOLS_RTF_TITLEPG); m_aSectionHeaders.append('{'); m_aSectionHeaders.append(pStr); m_bBufferSectionHeaders = true; diff --git a/sw/source/filter/ww8/rtfattributeoutput.hxx b/sw/source/filter/ww8/rtfattributeoutput.hxx index fcf43b765543..4ac68be6a377 100644 --- a/sw/source/filter/ww8/rtfattributeoutput.hxx +++ b/sw/source/filter/ww8/rtfattributeoutput.hxx @@ -219,7 +219,7 @@ public: void WriteField_Impl( const SwField* pFld, ww::eField eType, const String& rFldCmd, sal_uInt8 nMode ); void WriteBookmarks_Impl( std::vector< rtl::OUString >& rStarts, std::vector< rtl::OUString >& rEnds ); - void WriteHeaderFooter_Impl( const SwFrmFmt& rFmt, bool bHeader, const sal_Char* pStr ); + void WriteHeaderFooter_Impl( const SwFrmFmt& rFmt, bool bHeader, const sal_Char* pStr, bool bTitlepg ); protected: /// Output frames - the implementation. diff --git a/sw/source/filter/ww8/rtfexport.cxx b/sw/source/filter/ww8/rtfexport.cxx index ba3be68d8237..271220faba11 100644 --- a/sw/source/filter/ww8/rtfexport.cxx +++ b/sw/source/filter/ww8/rtfexport.cxx @@ -310,7 +310,7 @@ void RtfExport::WriteHeadersFooters( sal_uInt8 nHeadFootFlags, WriteHeaderFooter( rFmt, true, OOO_STRING_SVTOOLS_RTF_HEADER ); if ( nHeadFootFlags & nsHdFtFlags::WW8_HEADER_FIRST ) - WriteHeaderFooter( rFirstPageFmt, true, OOO_STRING_SVTOOLS_RTF_HEADERF ); + WriteHeaderFooter( rFirstPageFmt, true, OOO_STRING_SVTOOLS_RTF_HEADERF, true ); // footers if ( nHeadFootFlags & nsHdFtFlags::WW8_FOOTER_EVEN ) @@ -320,7 +320,7 @@ void RtfExport::WriteHeadersFooters( sal_uInt8 nHeadFootFlags, WriteHeaderFooter( rFmt, false, OOO_STRING_SVTOOLS_RTF_FOOTER ); if ( nHeadFootFlags & nsHdFtFlags::WW8_FOOTER_FIRST ) - WriteHeaderFooter( rFirstPageFmt, false, OOO_STRING_SVTOOLS_RTF_FOOTERF ); + WriteHeaderFooter( rFirstPageFmt, false, OOO_STRING_SVTOOLS_RTF_FOOTERF, true ); } void RtfExport::OutputField( const SwField* pFld, ww::eField eFldType, const String& rFldCmd, sal_uInt8 nMode ) @@ -1206,7 +1206,6 @@ void RtfExport::OutPageDescription( const SwPageDesc& rPgDsc, sal_Bool bWriteRes if( pAktPageDesc != &rPgDsc ) { pAktPageDesc = &rPgDsc; - Strm() << OOO_STRING_SVTOOLS_RTF_TITLEPG; if( pAktPageDesc->GetMaster().GetAttrSet().GetItemState( RES_HEADER, sal_False, &pItem ) == SFX_ITEM_SET ) WriteHeaderFooter(*pItem, true); @@ -1253,11 +1252,11 @@ void RtfExport::WriteHeaderFooter(const SfxPoolItem& rItem, bool bHeader) OSL_TRACE("%s end", OSL_THIS_FUNC); } -void RtfExport::WriteHeaderFooter(const SwFrmFmt& rFmt, bool bHeader, const sal_Char* pStr) +void RtfExport::WriteHeaderFooter(const SwFrmFmt& rFmt, bool bHeader, const sal_Char* pStr, bool bTitlepg) { OSL_TRACE("%s start", OSL_THIS_FUNC); - m_pAttrOutput->WriteHeaderFooter_Impl( rFmt, bHeader, pStr ); + m_pAttrOutput->WriteHeaderFooter_Impl( rFmt, bHeader, pStr, bTitlepg ); OSL_TRACE("%s end", OSL_THIS_FUNC); } diff --git a/sw/source/filter/ww8/rtfexport.hxx b/sw/source/filter/ww8/rtfexport.hxx index 60b6c347ae0c..a64beaad9e23 100644 --- a/sw/source/filter/ww8/rtfexport.hxx +++ b/sw/source/filter/ww8/rtfexport.hxx @@ -209,7 +209,7 @@ private: /// This is necessary to have the numbering table ready before the main text is being processed. void BuildNumbering(); void WriteHeaderFooter(const SfxPoolItem& rItem, bool bHeader); - void WriteHeaderFooter(const SwFrmFmt& rFmt, bool bHeader, const sal_Char* pStr); + void WriteHeaderFooter(const SwFrmFmt& rFmt, bool bHeader, const sal_Char* pStr, bool bTitlepg = false); RtfColorTbl m_aColTbl; RtfStyleTbl m_aStyTbl; |