diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2023-07-03 08:30:21 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.com> | 2023-07-03 10:12:49 +0200 |
commit | 16b5b21d36da87be9b50235acbbb8008ed23b8bb (patch) | |
tree | eea6e28837f07373dbf2fc4a91c1c4fe60cde344 /sw/CppunitTest_sw_core_text.mk | |
parent | 64216c8b2c451659a1f08211685e4d8ac2685de8 (diff) |
sw floattable: fix negative vert offset with on page boundary without anch text
The bugdoc has 3 floating tables on page 1, and the anchor of the last
floating table goes to page 2. All anchors are empty (no text), apart
from serving as an anchor for the floating tables. The last floating
table goes to page 2 in Writer, but not in Word.
The problem is quite similar to what commit
2d0a4ef1d83b8de6cb133970c2c35ae706fb058e (sw floattable: fix negative
vertical offset handling on page boundary, 2023-06-20) fixed already,
but here the anchor of the floating table is empty, and there it had
some text, which is a different codepath.
Fix the problem by first requesting a frame split in
SwTextFrame::FormatAdjust() even for empty paragraphs with flys (so the
fly part can go to page 1 and the empty paragraph can go to page 2) and
second disabling the SwTextFrame::FormatEmpty() optimization that would
assume no split is needed, while a split is required for a correct
layout here.
With this, the DOCX version of the original bnc#816603 document finally
renders without overlaps (4 pages, 11 floating tables).
Change-Id: Ie64ce92bf19b3dee8059fa14294d7599b41cc53f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/153866
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Tested-by: Jenkins
Diffstat (limited to 'sw/CppunitTest_sw_core_text.mk')
-rw-r--r-- | sw/CppunitTest_sw_core_text.mk | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/sw/CppunitTest_sw_core_text.mk b/sw/CppunitTest_sw_core_text.mk index 79ac4a0320bf..a04824e08e07 100644 --- a/sw/CppunitTest_sw_core_text.mk +++ b/sw/CppunitTest_sw_core_text.mk @@ -15,6 +15,7 @@ $(eval $(call gb_CppunitTest_use_common_precompiled_header,sw_core_text)) $(eval $(call gb_CppunitTest_add_exception_objects,sw_core_text, \ sw/qa/core/text/frmform \ + sw/qa/core/text/itratr \ sw/qa/core/text/text \ )) |