sw/source/core/layout/tabfrm.cxx | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)
New commits: commit 9e453a7af284cf17cb0debd2ab027f626e6e4a62 Author: Michael Stahl <michael.st...@allotropia.de> AuthorDate: Fri Aug 25 18:31:42 2023 +0200 Commit: Caolán McNamara <caolan.mcnam...@collabora.com> CommitDate: Tue Sep 12 16:24:57 2023 +0200 (related? tdf#155177) sw: layout: fix another RemoveFollowFlowLine SNAFU This happens with the following commit, on testForcepoint76, for no obvious reason. A follow table frame is in SwTabFrame::MakeAll(), then its follow flow line becomes empty and it does SetRemoveFollowFlowLinePending() on the master, then it formats its follow flow line (but at that time there's again a text frame in it), then that content moves backward, formats its uppers until it gets to the master table frame, which wants to join the row frame that's being formatted on the stack. Obviously a SwFrameDeleteGuard in lcl_RecalcRow() can't hurt, but it needs an additional change later to prevent it from moving rows of the follow back. Change-Id: Idca90b7eb67994385ccd306562ea26ff39e884f9 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156117 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.st...@allotropia.de> (cherry picked from commit 8c24bc5baa1f501943bf955e07787d80cb7a5763) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156146 Reviewed-by: Caolán McNamara <caolan.mcnam...@collabora.com> diff --git a/sw/source/core/layout/tabfrm.cxx b/sw/source/core/layout/tabfrm.cxx index f7e889094adc..3cfa29f92aab 100644 --- a/sw/source/core/layout/tabfrm.cxx +++ b/sw/source/core/layout/tabfrm.cxx @@ -1712,6 +1712,8 @@ static void lcl_RecalcRow(SwRowFrame & rRow, tools::Long const nBottom) if( bCheck ) { + SwFrameDeleteGuard g(&rRow); + // #115759# - force another format of the // lowers, if at least one of it was invalid. bCheck = SwContentFrame::CalcLowers(rRow, *rRow.GetUpper(), nBottom, true); @@ -2303,7 +2305,9 @@ void SwTabFrame::MakeAll(vcl::RenderContext* pRenderContext) if ( !bSplit && GetFollow() ) { bool bDummy; - if ( GetFollow()->ShouldBwdMoved( GetUpper(), bDummy ) ) + if (!(HasFollowFlowLine() + && GetFollow()->GetFirstNonHeadlineRow()->IsDeleteForbidden()) + && GetFollow()->ShouldBwdMoved(GetUpper(), bDummy)) { SwFrame *pTmp = GetUpper(); SwTwips nDeadLine = aRectFnSet.GetPrtBottom(*pTmp);