sw/source/filter/ww8/ww8par.cxx              |    2 ++
 writerfilter/source/dmapper/DomainMapper.cxx |    1 +
 writerfilter/source/filter/WriterFilter.cxx  |    1 +
 3 files changed, 4 insertions(+)

New commits:
commit 40987c3a4ca7caf9eea3b631972990ebf6a1f1b5
Author:     Oliver Specht <oliver.spe...@cib.de>
AuthorDate: Mon Jun 24 16:20:44 2024 +0200
Commit:     Thorsten Behrens <thorsten.behr...@allotropia.de>
CommitDate: Tue Jul 30 00:28:52 2024 +0200

    tdf#161264 don't hide paragraph with empty mail merge fields
    
    With tdf#35798 db04be037b611e296ef9f2542322c52ed82d7a2b
    paragraphs containing empty mail merge fields are hidden by default
    to remove empty lines in address blocks.
    This is now switched off when importing Word documents.
    
    Change-Id: I0f550ff3d29ac499446df9a04676a08d914d12f1
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/169469
    Tested-by: Gabor Kelemen <gabor.kelemen.ext...@allotropia.de>
    Tested-by: Jenkins
    Reviewed-by: Thorsten Behrens <thorsten.behr...@allotropia.de>
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170998

diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index a2d959d7d3f7..9d88a21b9299 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -1868,6 +1868,8 @@ void SwWW8ImplReader::ImportDop()
         DocumentSettingId::FRAME_AUTOWIDTH_WITH_MORE_PARA, true);
     m_rDoc.getIDocumentSettingAccess().set(
         DocumentSettingId::FOOTNOTE_IN_COLUMN_TO_PAGEEND, true);
+    m_rDoc.getIDocumentSettingAccess().set(
+        DocumentSettingId::EMPTY_DB_FIELD_HIDES_PARA, false);
 
     // Import Default Tabs
     tools::Long nDefTabSiz = m_xWDop->dxaTab;
diff --git a/writerfilter/source/dmapper/DomainMapper.cxx 
b/writerfilter/source/dmapper/DomainMapper.cxx
index 36fb00408ddb..2ec441c22153 100644
--- a/writerfilter/source/dmapper/DomainMapper.cxx
+++ b/writerfilter/source/dmapper/DomainMapper.cxx
@@ -143,6 +143,7 @@ DomainMapper::DomainMapper( const uno::Reference< 
uno::XComponentContext >& xCon
 
         // Enable only for new documents, since pasting from clipboard can 
influence existing doc
         m_pImpl->SetDocumentSettingsProperty("NoNumberingShowFollowBy", 
uno::Any(true));
+        
m_pImpl->SetDocumentSettingsProperty("EmptyDbFieldHidesPara",uno::Any(false));
     }
 
     // Initialize RDF metadata, to be able to add statements during the import.
diff --git a/writerfilter/source/filter/WriterFilter.cxx 
b/writerfilter/source/filter/WriterFilter.cxx
index 44efc0c42cfc..518179d17ec7 100644
--- a/writerfilter/source/filter/WriterFilter.cxx
+++ b/writerfilter/source/filter/WriterFilter.cxx
@@ -315,6 +315,7 @@ void WriterFilter::setTargetDocument(const 
uno::Reference<lang::XComponent>& xDo
     xSettings->setPropertyValue("IgnoreTabsAndBlanksForLineCalculation", 
uno::Any(true));
     xSettings->setPropertyValue("InvertBorderSpacing", uno::Any(true));
     xSettings->setPropertyValue("CollapseEmptyCellPara", uno::Any(true));
+    xSettings->setPropertyValue("EmptyDbFieldHidesPara", uno::Any(false));
     // tdf#142404 TabOverSpacing (new for compatibilityMode15/Word2013+) is a 
subset of TabOverMargin
     // (which applied to DOCX <= compatibilityMode14).
     // TabOverMargin looks at tabs beyond the normal text area,

Reply via email to