Created attachment 195402 [details] Hanging question mark Open the attachment using 24.2 or 24.8. The trailing question mark is shown outside of the text body area, "hanging" on the right margin. It is not an expected behavior; there was no proper hanging punctuation support implemented in LO yet, and this only happens at the end of a justified paragraph, not in the middle. It works correctly in 7.6. The file has JustifyLinesWithShrinking compatibility setting. Most likely related to bug 119908. Ref.: https://ask.libreoffice.org/t/disable-hanging-punctuation/108353
Reproducible in LO 24.8.0.1.0+ (75f774ecda25b5d45ac6c19f293cc79b62c6914d) / Linux. This ended up in its current state in two steps. First both lines started hanging (ie. ending outside right margin), with the following commit: https://cgit.freedesktop.org/libreoffice/core/commit/?id=7d08767b890e723cd502b1c61d250924f695eb98 author László Németh <nemeth@numbertext.org> 2023-10-16 19:39:30 +0200 committer László Németh <nemeth@numbertext.org> 2023-10-17 10:37:23 +0200 "tdf#130088 tdf#119908 smart justify: fix DOCX line count + compat opt." Then the first line stopped hanging, and only the ending punctuation in the second line is hanging since the commit below: https://cgit.freedesktop.org/libreoffice/core/commit/?id=17eaebee279772b6062ae3448012133897fc71bb author László Németh <nemeth@numbertext.org> 2023-11-15 23:31:12 +0100 committer László Németh <nemeth@numbertext.org> 2023-11-16 16:21:06 +0100 "tdf#119908 sw smart justify: fix justification by shrinking"
Created attachment 195404 [details] hanging letter
It seems, it is a problem with letters, not only punctuation, too. @Mike, Áron: thanks for the bug report and test document!
*** Bug 162220 has been marked as a duplicate of this bug. ***
There is a work-around for this bug; or, at least for bug 162220, which has been marked as a duplicate of this one. The work-around is as follows. Is it possible to do this as a simple patch? I.e.: to set a minimum character spacing for all fonts. If so, I'll apply the patch to LibreOffice 24 in my Linux distro and other distro maintainers may find it useful as well. Highlight text -> Format -> Character -> Position -> Character spacing -> Set to 0.1 [or any small positive value]
Proposed fix: https://gerrit.libreoffice.org/c/core/+/172228
The problem was the missing shrinking of the last paragraph line. A working workaround is for fixing the bad paragraphs: set the "Last line:" to "Justified" on Alignment pane of paragraph formatting.
László Németh committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/6b857398a59d16308d6185d01e003e401439f060 tdf#162109 sw smart justify: fix overhanging last line 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.
@Mike and all: thanks for the bug report and feedback!
I've built 24.8.0.1 with the patch and have loaded the test file I submitted in the duplicate bug. The issue remains even if one clears direct formatting and then reformats. However, it seems to disappear if one copies the text involved to a new document. So, if it's a useful data point, the patch seems to work for that series.
László Németh committed a patch related to this issue. It has been pushed to "libreoffice-24-8": https://git.libreoffice.org/core/commit/e679e3b194901ebb52738be32f20148e4627d4e9 tdf#162109 sw smart justify: fix overhanging last line It will be available in 24.8.1. 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.
László Németh committed a patch related to this issue. It has been pushed to "libreoffice-24-2": https://git.libreoffice.org/core/commit/82d46a18cd9ec8c5027785b6d8303c4a0ce4e34f tdf#162109 sw smart justify: fix overhanging last line It will be available in 24.2.7. 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.
(In reply to OldCoder from comment #10) > I've built 24.8.0.1 with the patch and have loaded the test file I submitted > in the duplicate bug. The issue remains even if one clears direct formatting > and then reformats. However, it seems to disappear if one copies the text > involved to a new document. So, if it's a useful data point, the patch seems > to work for that series. I've reopened the bug, because it's really not a duplicate. Many thanks for the quick testing and feedback!
László Németh committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/1a87cd290282ea723c5d1a0d80c958b705b9d7ec tdf#162109 tdf#162220 sw smart justify: add unit tests 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.
László Németh committed a patch related to this issue. It has been pushed to "libreoffice-24-8": https://git.libreoffice.org/core/commit/5bf29163c0242b2d113d1d6019ed83f41299c0e4 tdf#162109 tdf#162220 sw smart justify: add unit tests It will be available in 24.8.2. 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.
László Németh committed a patch related to this issue. It has been pushed to "libreoffice-24-2": https://git.libreoffice.org/core/commit/309baeb104310708f771f50b8481654b0ac251ac tdf#162109 tdf#162220 sw smart justify: add unit tests It will be available in 24.2.7. 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.