Kaydet (Commit) 7413216e authored tarafından Justin Luth's avatar Justin Luth Kaydeden (comit) Justin Luth

tdf#70195 docx export: default header/footer at 720

This only impacts MSWord, which otherwise suggests
a new header start at 0. LO ignores that 0 and uses
a sane default.

Change-Id: Id9790038086de1e20918d4ab498a0ce93ca53b5c
Reviewed-on: https://gerrit.libreoffice.org/59523
Tested-by: Jenkins
Reviewed-by: 's avatarJustin Luth <justin_luth@sil.org>
üst af579ed7
...@@ -971,6 +971,9 @@ DECLARE_OOXMLEXPORT_TEST(test76108, "test76108.docx") ...@@ -971,6 +971,9 @@ DECLARE_OOXMLEXPORT_TEST(test76108, "test76108.docx")
if (!pXmlDoc) return; if (!pXmlDoc) return;
//docx file after RT is getting corrupted. //docx file after RT is getting corrupted.
assertXPath(pXmlDoc, "/w:document[1]/w:body[1]/w:p[1]/w:r[1]/w:fldChar[1]", "fldCharType", "begin"); assertXPath(pXmlDoc, "/w:document[1]/w:body[1]/w:p[1]/w:r[1]/w:fldChar[1]", "fldCharType", "begin");
// tdf#70195 the default header should start at 720, not 0
assertXPath(pXmlDoc, "//w:pgMar", "header", "720");
} }
DECLARE_OOXMLEXPORT_TEST(testTCTagMisMatch, "TCTagMisMatch.docx") DECLARE_OOXMLEXPORT_TEST(testTCTagMisMatch, "TCTagMisMatch.docx")
......
...@@ -7982,14 +7982,14 @@ void DocxAttributeOutput::FormatULSpace( const SvxULSpaceItem& rULSpace ) ...@@ -7982,14 +7982,14 @@ void DocxAttributeOutput::FormatULSpace( const SvxULSpaceItem& rULSpace )
HdFtDistanceGlue aDistances( *m_rExport.GetCurItemSet() ); HdFtDistanceGlue aDistances( *m_rExport.GetCurItemSet() );
sal_Int32 nHeader = 0; sal_Int32 nHeader = 720;
if ( aDistances.HasHeader() ) if ( aDistances.HasHeader() )
nHeader = sal_Int32( aDistances.dyaHdrTop ); nHeader = sal_Int32( aDistances.dyaHdrTop );
// Page top // Page top
m_pageMargins.nTop = aDistances.dyaTop; m_pageMargins.nTop = aDistances.dyaTop;
sal_Int32 nFooter = 0; sal_Int32 nFooter = 720;
if ( aDistances.HasFooter() ) if ( aDistances.HasFooter() )
nFooter = sal_Int32( aDistances.dyaHdrBottom ); nFooter = sal_Int32( aDistances.dyaHdrBottom );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment