diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2020-03-05 15:57:33 +0100 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2020-05-15 10:13:18 +0200 |
commit | d22c0aa1bd6435e84f21f509b014209985c3c83b (patch) | |
tree | dd3104bfddd343e4f294a9be72a3453d40d96e4f /sw/source/filter/ww8/wrtw8sty.cxx | |
parent | e2a27e1eff3d9f003842f58eb4f7085f3a3eab29 (diff) |
sw padded numbering: add DOC footnote filter
Import side: remove the duplication between SwWW8ImplReader::CoreLoad()
and WW8ListManager::ReadLVL(). The CoreLoad() version did not support
reading 0x16 as it did a "& 0xf" on the value before parsing.
Export side: Writer supports footnote numbering type per-document, Word
supports it per-section. So next to the per-document export add a
per-section one, that's what Word actually reads. Similar code was there
already for DOCX.
(cherry picked from commit 5c7d0c5bafd244f1bfb3930e0229f1f3f2371c82)
Conflicts:
sw/source/filter/ww8/ww8par.cxx
Change-Id: Ic94e953cfee4514aabe507a8bcf75445bf05f401
Diffstat (limited to 'sw/source/filter/ww8/wrtw8sty.cxx')
-rw-r--r-- | sw/source/filter/ww8/wrtw8sty.cxx | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/sw/source/filter/ww8/wrtw8sty.cxx b/sw/source/filter/ww8/wrtw8sty.cxx index bfe6483b7f41..d43c96f8f3c8 100644 --- a/sw/source/filter/ww8/wrtw8sty.cxx +++ b/sw/source/filter/ww8/wrtw8sty.cxx @@ -1330,6 +1330,7 @@ void WW8AttributeOutput::StartSection() void WW8AttributeOutput::SectFootnoteEndnotePr() { const SwFootnoteInfo& rInfo = m_rWW8Export.m_pDoc->GetFootnoteInfo(); + const SwEndNoteInfo& rEndNoteInfo = m_rWW8Export.m_pDoc->GetEndNoteInfo(); m_rWW8Export.InsUInt16( NS_sprm::sprmSRncFtn ); switch( rInfo.eNum ) { @@ -1337,6 +1338,13 @@ void WW8AttributeOutput::SectFootnoteEndnotePr() case FTNNUM_CHAPTER: m_rWW8Export.pO->push_back( sal_uInt8/*rncRstSect*/ (1) ); break; default: m_rWW8Export.pO->push_back( sal_uInt8/*rncCont*/ (0) ); break; } + + m_rWW8Export.InsUInt16(NS_sprm::sprmSNfcFtnRef); + sal_uInt8 nId = WW8Export::GetNumId(rInfo.aFormat.GetNumberingType()); + SwWW8Writer::InsUInt16(*m_rWW8Export.pO, nId); + m_rWW8Export.InsUInt16(NS_sprm::sprmSNfcEdnRef); + nId = WW8Export::GetNumId(rEndNoteInfo.aFormat.GetNumberingType()); + SwWW8Writer::InsUInt16(*m_rWW8Export.pO, nId); } void WW8AttributeOutput::SectionFormProtection( bool bProtected ) |