Bug 168116 - FILEOPEN RTF Empty, hidden paragraph between tables is visible
Summary: FILEOPEN RTF Empty, hidden paragraph between tables is visible
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All All
: medium normal
Assignee: Mike Kaganski
URL:
Whiteboard: target:26.2.0
Keywords:
Depends on:
Blocks: RTF-Tables
  Show dependency treegraph
 
Reported: 2025-08-26 10:33 UTC by Gabor Kelemen (Collabora)
Modified: 2025-10-10 07:34 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
Example file from Word (135.63 KB, application/msword)
2025-08-26 10:33 UTC, Gabor Kelemen (Collabora)
Details
How it looks in Word 2016 and Writer master (53.39 KB, image/png)
2025-08-26 10:33 UTC, Gabor Kelemen (Collabora)
Details
A minimized reproducer (220 bytes, application/msword)
2025-09-10 14:53 UTC, Mike Kaganski
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Gabor Kelemen (Collabora) 2025-08-26 10:33:31 UTC
Created attachment 202517 [details]
Example file from Word

Attached example file contains several tables separated by empty, hidden paragraphs.

The first of these paragraphs stays visible when the formatting marks are hidden or the document is printed, creating different layout compared to Word.

1. Open attached document
2. Hide the formatting marks or switch to Print view
-> the first two tables are separated by an empty paragraph, but they should be rendered as if they were a single table, like the other ones are.

Version: 26.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 7f4868348c14b305fcd75744e1e3544d0d3a5d61
CPU threads: 14; OS: Windows 10 X86_64 (build 19045); UI render: Skia/Raster; VCL: win
Locale: hu-HU (hu_HU); UI: en-US
Calc: threaded

and way back to 3.3, this was never good.
Comment 1 Gabor Kelemen (Collabora) 2025-08-26 10:33:54 UTC
Created attachment 202518 [details]
How it looks in Word 2016 and Writer master
Comment 2 BogdanB 2025-08-26 11:51:00 UTC
Confirm the bad empty line with
Version: 25.8.0.4 (X86_64)
Build ID: 48f00303701489684e67c38c28aff00cd5929e67
CPU threads: 16; OS: Linux 6.8; UI render: default; VCL: gtk3
Locale: ro-RO (ro_RO.UTF-8); UI: en-US
Calc: threaded
Comment 3 Mike Kaganski 2025-09-10 14:53:12 UTC
Created attachment 202777 [details]
A minimized reproducer

The attachment shows that the problem is treatment of the hidden paragraph mark.
Comment 4 Mike Kaganski 2025-10-09 13:20:50 UTC
https://gerrit.libreoffice.org/c/core/+/192103
Comment 5 Mike Kaganski 2025-10-09 13:28:42 UTC
Note that attachment 202777 [details] will not be fixed by the proposed change; only the original bugdoc from attachment 202517 [details] will.
Comment 6 Commit Notification 2025-10-10 07:33:49 UTC
Mike Kaganski committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/caebd1b8ec8d5dc4982637bdf5aa5a9323e7d946

tdf#168116: an ugly hack to handle linebreak-before-hidden-paragraph-mark

It will be available in 26.2.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 7 Mike Kaganski 2025-10-10 07:34:06 UTC
Let me call it fixed.