diff options
author | Michael Stahl <Michael.Stahl@cib.de> | 2020-09-23 15:14:08 +0200 |
---|---|---|
committer | Michael Stahl <michael.stahl@cib.de> | 2020-09-24 20:56:27 +0200 |
commit | 38aa699f265c17548769aaa4f20e1ae35d18f202 (patch) | |
tree | d95e038a17ed9ec261824d4db098be3bb1e749e9 /sw/source/filter/xml/xmlimp.cxx | |
parent | 5d67dcc922f831d91424cae8d8758f067a6781b0 (diff) |
tdf#134782 sw: split AddParaSpacingToTableCells flag in 2
commit 3cccdabf19a99fd3f657985c1822436d7679df2b "extend
AddParaSpacingToTableCells with line spacing" changed how the
ADD_PARA_SPACING_TO_TABLE_CELLS compat flag works, to improve interop
with Word.
This commit splits out the change as a separate new compat flag
ADD_PARA_LINE_SPACING_TO_TABLE_CELLS ("AddParaLineSpacingToTableCells"),
to preserve compatibility with ODT documents that were produced
by LO < 6.4 (via SwXMLImport::SetConfigurationSettings()).
New documents and WW8/RTF/DOCX import have both flags enabled.
The combination false/true is invalid, and treated as equivalent
to false/false.
Change-Id: Ida20df8fe4a8192a714f91da95345f9726fd7d98
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103317
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl@cib.de>
Diffstat (limited to 'sw/source/filter/xml/xmlimp.cxx')
-rw-r--r-- | sw/source/filter/xml/xmlimp.cxx | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sw/source/filter/xml/xmlimp.cxx b/sw/source/filter/xml/xmlimp.cxx index c03a46d20545..c5a9bc5b7b18 100644 --- a/sw/source/filter/xml/xmlimp.cxx +++ b/sw/source/filter/xml/xmlimp.cxx @@ -1337,6 +1337,7 @@ void SwXMLImport::SetConfigurationSettings(const Sequence < PropertyValue > & aC bool bUseOldNumbering = false; bool bAddExternalLeading = false; bool bAddParaSpacingToTableCells = false; + bool bAddParaLineSpacingToTableCells = false; bool bUseFormerLineSpacing = false; bool bUseFormerObjectPositioning = false; bool bUseFormerTextWrapping = false; @@ -1409,6 +1410,8 @@ void SwXMLImport::SetConfigurationSettings(const Sequence < PropertyValue > & aC bAddExternalLeading = true; else if ( rValue.Name == "AddParaSpacingToTableCells" ) bAddParaSpacingToTableCells = true; + else if ( rValue.Name == "AddParaLineSpacingToTableCells" ) + bAddParaLineSpacingToTableCells = true; else if ( rValue.Name == "UseFormerLineSpacing" ) bUseFormerLineSpacing = true; else if ( rValue.Name == "UseFormerObjectPositioning" ) @@ -1511,6 +1514,10 @@ void SwXMLImport::SetConfigurationSettings(const Sequence < PropertyValue > & aC xProps->setPropertyValue( "AddParaSpacingToTableCells", makeAny( false ) ); } + if (!bAddParaLineSpacingToTableCells) + { + xProps->setPropertyValue("AddParaLineSpacingToTableCells", makeAny(false)); + } if( !bUseFormerTextWrapping ) { |