Bug 106814 - FILEOPEN: DOC: Incorrect cell's height break page layout (since Harbuzz change)
Summary: FILEOPEN: DOC: Incorrect cell's height break page layout (since Harbuzz change)
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
5.2.0.4 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: bibisected, bisected, filter:doc, regression
Depends on:
Blocks: DOC-Tables
  Show dependency treegraph
 
Reported: 2017-03-28 09:46 UTC by Xisco Faulí
Modified: 2023-11-01 14:21 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
comparison MSO 2010 and LibreOffice 5.4 (210.03 KB, image/png)
2017-03-28 09:46 UTC, Xisco Faulí
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Xisco Faulí 2017-03-28 09:46:11 UTC
Created attachment 132208 [details]
comparison MSO 2010 and LibreOffice 5.4

Steps to reproduce:
1. Open attachment 52268 [details] from bug 41728
2. Check cells' height in 'Your Personal Details' table

Reproduced in

Version: 5.4.0.0.alpha0+
Build ID: 4ba483beccc99d336d0e0bec47b5fd6823b16c16
CPU threads: 4; OS: Linux 4.8; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); Calc: group
Comment 1 Xisco Faulí 2017-03-28 09:47:53 UTC
Regression introduced by:

author	Caolán McNamara <caolanm@redhat.com>	2015-04-07 13:57:39 (GMT)
committer	Caolán McNamara <caolanm@redhat.com>	2015-04-07 20:09:05 (GMT)
commit b7fff04ad728369a09a5e1a5cfbe494cf388317b (patch)
tree 9c3314d5c0a991f0a7e19a31a96800c256b70b88
parent 5ba54aacd5318fbf9b9f0589a090f717c53833c7 (diff)
Resolves: tdf#90504 0x7 chars in .doc are not always cell/row ends
fdo65094-2.doc shows that a 0x7 isn't always a row/cell end

only a 0x7 that is right at the end of the paragraph range is
a real row/cell end

this I believe will remove the last crashtester .doc crash

Bisected with bibisect-50max

Adding Cc: to Caolán McNamara
Comment 2 QA Administrators 2018-03-29 02:33:52 UTC Comment hidden (obsolete)
Comment 3 Timur 2019-11-29 20:09:48 UTC
Reproduced 6.5+ but also 4.4 and 3.5. Cells looked better on fileopen in LO 3.3 but fields couldn't be filled. Test Windows.
MSO also opens that DOC as read-only and fields can be filled only after Edit.
Xisco, this was marked by you as a regression from 5.0. Please check bibisect.
Comment 4 Justin L 2021-08-23 06:19:25 UTC
(In reply to Timur from comment #3)
>  Please check bibisect.
The problem here is that the content cannot fit in the available space (designed to hold a single number), so it has to expand down. The problem in 5.0 was that some content doubled up in the same cell. But that is different from the problem today, so comment 1's bibisect is not correct.

The problem started in 5.2 with
bibisect-linux-64-5.2 commit 6caad8eefd49e5ec5721f8ac8cf78cd01a32b44d
source commit 975c833943bab627eb461457ab1df35744b291cd
Author: Akash Jain on Thu Apr 21 20:42:23 2016 +0530
   Upgrade harfbuzz version from 0.9.40 to 1.2.6

I expect that the size of U+2002 (EN space) must have increased (since that is the placeholder used in these cells).
Comment 5 Justin L 2023-05-13 17:37:42 UTC
repro 7.6+
Comment 6 Caolán McNamara 2023-09-12 08:20:12 UTC
caolanm->jluth: do you think both writer and word are using the same placeholders and writer is getting a wider result than word? Or is it more complicated than that?
Comment 7 Justin L 2023-09-12 11:59:37 UTC
(In reply to Caolán McNamara from comment #6)
> caolanm->jluth: do you think both writer and word are using the same
> placeholders and writer is getting a wider result than word? 
My comment was based on pure speculation - simply based on hearing the word "harfbuzz". I have zero insight into any real details.
Comment 8 ⁨خالد حسني⁩ 2023-09-12 16:24:43 UTC
If EN space is missing from the font, HarfBuzz will synthesize it (use space glyph but with adjusted width). Older LibreOffice/MS Office didn’t do that and would fallback to a different font.

The version of Arial Narrow that comes with macOS does not indeed have EN space.

$ hb-shape /System/Library/Fonts/Supplemental/Arial\ Narrow.ttf -u 2002,0031,0032
[space=0+1024|one=1+934|two=2+934]

So indeed the synthesized En-space is slightly larger than the width of the digits.
Comment 9 ⁨خالد حسني⁩ 2023-09-12 16:30:10 UTC
EN space is an odd choice, though, if the purpose is to have space that is equal to digits (figures), since there is already U+2007 FIGURE SPACE for that, and HarfBuzz’s synthesized glyph uses the width of the digits:

$ hb-shape /System/Library/Fonts/Supplemental/Arial\ Narrow.ttf -u 2007,0031,0032
[space=0+934|one=1+934|two=2+934]