Bug 162268 - RTF: combination of hidden text and character attributes fails
Summary: RTF: combination of hidden text and character attributes fails
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: Oliver Specht (CIB)
URL:
Whiteboard: target:25.2.0 target:24.8.3
Keywords:
: 152841 (view as bug list)
Depends on:
Blocks: Word-Line-Break
  Show dependency treegraph
 
Reported: 2024-07-30 13:56 UTC by Oliver Specht (CIB)
Modified: 2025-04-03 07:42 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
Header with hidden text (49.81 KB, application/msword)
2024-07-30 13:56 UTC, Oliver Specht (CIB)
Details
Testing emtpy line.docx: exaggerated multiline empty paragraph - cleanroom example (12.77 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2025-01-21 21:05 UTC, Justin L
Details
Testing emtpy line.word2010.pdf: how it looks in MS Word - nearly identical to LO (16.86 KB, application/pdf)
2025-01-21 21:07 UTC, Justin L
Details
Testing emtpy line.docx_import-0.png: RED = MSO 2010, BLACK = LO at comment 3's commit (5.03 KB, image/png)
2025-01-21 21:30 UTC, Justin L
Details
the attachment 198659 with double line spacing (11.52 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2025-01-28 17:55 UTC, Gabor Kelemen (allotropia)
Details
Screenshot of the regression (122.34 KB, image/png)
2025-01-28 17:57 UTC, Gabor Kelemen (allotropia)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Oliver Specht (CIB) 2024-07-30 13:56:44 UTC
Created attachment 195605 [details]
Header with hidden text

Load bugdoc

The header contains hidden text with a linebreak in 20pt and a visible line in 11pt.

In Writer the header has no content while in Word there is an empty line in 11pt

Using the bugdoc of bug 155662 there is a visible 'a' in 11pt but the line is formatted as if 20pt were valid.
With 'Toggle formatting marks' on the line is correctly formatted in 11pt.
Comment 1 Commit Notification 2024-09-09 09:10:17 UTC
Oliver Specht committed a patch related to this issue.
It has been pushed to "master":

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

tdf#162268: Import - add zero width space after line break

It will be available in 25.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 2 Commit Notification 2024-09-26 16:01:30 UTC
Oliver Specht committed a patch related to this issue.
It has been pushed to "master":

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

Revert "tdf#162268: Import - add zero width space after line break"

It will be available in 25.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 3 Commit Notification 2024-09-27 16:10:34 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/7b8cec8322b60673e686660caf875bc71117bbd0

tdf#162268 sw: ApplyParagraphMarkFormatToEmptyLineAtEndOfParagraph

It will be available in 25.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 4 Commit Notification 2024-09-27 16:10:37 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/037a765f03c95301f987e1d1d4ef715b05b25c94

tdf#162268 sw: IgnoreHiddenCharsForLineCalculation

It will be available in 25.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 5 Commit Notification 2024-10-22 18:02:22 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "libreoffice-24-8":

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

tdf#162268 sw: ApplyParagraphMarkFormatToEmptyLineAtEndOfParagraph

It will be available in 24.8.3.

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 6 Commit Notification 2024-10-22 18:03:25 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "libreoffice-24-8":

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

tdf#162268 sw: IgnoreHiddenCharsForLineCalculation

It will be available in 24.8.3.

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 Commit Notification 2024-11-06 19:29:09 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "master":

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

tdf#162268 sw: layout: hidden formatting is ignored on cell end marker

It will be available in 25.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 8 Commit Notification 2024-11-06 19:29:12 UTC
Michael Stahl committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/7fa083459eb5c5b620454c6e3092d35cdde1b281

tdf#162268 sw: formatting: paragraph style also applies to para marker

It will be available in 25.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 9 Justin L 2025-01-21 19:22:39 UTC
I assume this bug should be marked as fixed?
Comment 10 Justin L 2025-01-21 21:05:28 UTC
Created attachment 198659 [details]
Testing emtpy line.docx: exaggerated multiline empty paragraph - cleanroom example

(In reply to Commit Notification from comment #3)
> tdf#162268 sw: ApplyParagraphMarkFormatToEmptyLineAtEndOfParagraph
I tried to create a minimal example to show there was something wrong, but only succeeded in "proving" mstahl's commit is good.
Comment 11 Justin L 2025-01-21 21:07:22 UTC
Created attachment 198660 [details]
Testing emtpy line.word2010.pdf: how it looks in MS Word - nearly identical to LO
Comment 12 Justin L 2025-01-21 21:30:07 UTC
Created attachment 198662 [details]
Testing emtpy line.docx_import-0.png: RED = MSO 2010, BLACK = LO at comment 3's commit

Maybe I proved it after all? I'm seeing the little bit of extra spacing that I was trying to find.

Although the text and first three lines are "perfectly positioned", the newly positioned last line is a few pixels too low in LO.
Comment 13 Gabor Kelemen (allotropia) 2025-01-28 17:55:18 UTC
Created attachment 198808 [details]
the attachment 198659 [details] with double line spacing

Seems like there is something funny going on with line spacing - if I change it to double, the last border line shows up a lot lower in Writer master than in my Word 26.
Comment 14 Gabor Kelemen (allotropia) 2025-01-28 17:57:06 UTC
Created attachment 198809 [details]
Screenshot of the regression

A bit of bibisect shows that this indeed started with

https://git.libreoffice.org/core/+/7b8cec8322b60673e686660caf875bc71117bbd0%5E%21

tdf#162268 sw: ApplyParagraphMarkFormatToEmptyLineAtEndOfParagraph
Comment 15 Gabor Kelemen (allotropia) 2025-01-28 18:10:40 UTC
Let's mark this one fixed (the original problem now looks ok), and track the regression separately as bug 164896

Thanks Justin for finding this!
Comment 16 Gabor Kelemen (allotropia) 2025-02-05 12:06:18 UTC
*** Bug 152841 has been marked as a duplicate of this bug. ***