diff options
author | Michael Stahl <michael.stahl@allotropia.de> | 2023-07-17 21:37:07 +0200 |
---|---|---|
committer | Michael Stahl <michael.stahl@allotropia.de> | 2023-08-03 11:58:02 +0200 |
commit | 580e405f6fac9931c6d6e1ada37fd1ee9d576111 (patch) | |
tree | c62921fb9e60f5d49e26022b3b66ae338d73c7b4 /sw | |
parent | 4a5c329e22b7ad52a14ca39028e4a645c1bbbe40 (diff) |
tdf#153319 sw: don't move footnotes to follow if portions in master
SwTextFrameBreak::IsInside() may be called in different situations,
during formatting it should be possible to move the footnotes, but when
called from SwTextFrame::CalcPreps() this is problematic as it does not
format the lines, it iterates over existing lines.
The problem is that the footnote frame is moved to the follow's page,
but the footnote portion remains on the master, and then the follow is
joined while the footnote frame's mpReference still points to it.
(regression from commit 391613785ae6fbb735cf7a86ea2f6a93161a8769)
Change-Id: I4290dcd242a7f5292ad4f50c1407c9cd88e80a6a
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154557
Tested-by: Jenkins
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
(cherry picked from commit 7e9b2b71db72b8c4c9c6ca83d08d3b6b05775ac8)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/154545
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
(cherry picked from commit f70f822532d96feebd24645009f0368405dac9e4)
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/text/widorp.cxx | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sw/source/core/text/widorp.cxx b/sw/source/core/text/widorp.cxx index df0c779d6dbb..43afbd1e45e6 100644 --- a/sw/source/core/text/widorp.cxx +++ b/sw/source/core/text/widorp.cxx @@ -138,6 +138,8 @@ bool SwTextFrameBreak::IsInside( SwTextMargin const &rLine ) const bFit = nDiff >= 0; if (!bFit && rLine.MaybeHasHints() && m_pFrame->GetFollow() + // tdf#153319 RemoveFootnote only works if this frame doesn't + && !rLine.GetNext() // contain the footnote portion // if using same footnote container as the follow, pointless to try? && m_pFrame->FindFootnoteBossFrame() != m_pFrame->GetFollow()->FindFootnoteBossFrame()) { |