sw/source/core/layout/flowfrm.cxx |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

New commits:
commit 9c5c63d567be3623d609feda47026631cb48263b
Author:     Satya <skompe...@opentext.com>
AuthorDate: Mon Jul 31 20:59:07 2023 +0530
Commit:     Justin Luth <jl...@mail.com>
CommitDate: Mon Jul 31 20:04:22 2023 +0200

    tdf#156372 sw: Stop adding GetLower to every cell in header table
    
    The code was doubling the lower spacing of the last paragraph
    in every cell of the table. This change is to not add the space
    when in tables, since that was intended to only apply
    to the last paragraph in the header.
    
    Change-Id: Ia8c2b31e3e56302735e858c39f80cc35e190af6b
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154643
    Tested-by: Jenkins
    Reviewed-by: Justin Luth <jl...@mail.com>
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/155101

diff --git a/sw/source/core/layout/flowfrm.cxx 
b/sw/source/core/layout/flowfrm.cxx
index 1b9ecf1cf03c..01f6b9e3cb34 100644
--- a/sw/source/core/layout/flowfrm.cxx
+++ b/sw/source/core/layout/flowfrm.cxx
@@ -1811,9 +1811,11 @@ SwTwips SwFlowFrame::CalcLowerSpace( const 
SwBorderAttrs* _pAttrs ) const
     // tdf#128195 Consider para spacing below last paragraph in header
     bool bHasSpacingBelowPara = 
m_rThis.GetUpper()->GetFormat()->getIDocumentSettingAccess().get(
         DocumentSettingId::HEADER_SPACING_BELOW_LAST_PARA);
-    if (bHasSpacingBelowPara && !m_rThis.IsInFly() && 
m_rThis.FindFooterOrHeader() && !GetFollow()
-        && !m_rThis.GetIndNext())
+    if (bHasSpacingBelowPara && !m_rThis.IsInTab() && !m_rThis.IsInFly()
+        && m_rThis.FindFooterOrHeader() && !GetFollow() && 
!m_rThis.GetIndNext())
+    {
         nLowerSpace += _pAttrs->GetULSpace().GetLower() + 
_pAttrs->CalcLineSpacing();
+    }
 
     return nLowerSpace;
 }

Reply via email to