Bug 136231 - FILEOPEN PPTX: Text layout in text boxes is different in Impress than in PP (PPT is almost fine)
Summary: FILEOPEN PPTX: Text layout in text boxes is different in Impress than in PP (...
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Impress (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: filter:pptx
Depends on:
Blocks: PPTX-Textbox
  Show dependency treegraph
 
Reported: 2020-08-28 14:55 UTC by shariqkeen
Modified: 2022-06-23 12:39 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:
Regression By:


Attachments
pptx (176.55 KB, application/vnd.openxmlformats-officedocument.presentationml.presentation)
2020-08-28 14:55 UTC, shariqkeen
Details
comparison gif (305.45 KB, image/gif)
2020-08-28 14:56 UTC, shariqkeen
Details
PDF exported in PowerPoint (240.23 KB, application/pdf)
2021-02-14 06:55 UTC, Aron Budea
Details
PDF exported in LO 7.1.0.3 (w Calibri) (106.70 KB, application/pdf)
2021-02-14 06:56 UTC, Aron Budea
Details
PPT saved in PP (241.50 KB, application/vnd.ms-powerpoint)
2021-02-14 07:08 UTC, Aron Budea
Details
AnotherTest-Bad Render in LibreOffice (568.47 KB, application/zip)
2021-11-27 19:06 UTC, kevinpr
Details

Note You need to log in before you can comment on or make changes to this bug.
Description shariqkeen 2020-08-28 14:55:25 UTC
Created attachment 164812 [details]
pptx

This pptx [originally MSO generated, having Calibri font] has text displayed differently when opened in LO even when substitute fonts [Carlito, since I don't have Calibri] have same metrics. Due to same metrics, it should have been exactly similar, I expected.

See that at the end of one/multiple lines, one/few words either have been pushed to next line or extra words have been included in the line.

I'm uploading this side by side comparison for only few of the slides via gif

Version: 7.0.0.3
Build ID: 8061b3e9204bef6b321a21033174034a5e2ea88e
CPU threads: 4; OS: Linux 5.4; UI render: default; VCL: gtk3
Locale: en-IN (en_IN); UI: en-US
Calc: threaded

more details in discussion at https://ask.libreoffice.org/en/question/261699/powerpoint-compatibility-text-not-displayed-identically-even-when-substitute-fonts-have-same-metrics/
Comment 1 shariqkeen 2020-08-28 14:56:03 UTC
Created attachment 164813 [details]
comparison gif
Comment 2 Aron Budea 2021-02-14 06:55:50 UTC
Created attachment 169719 [details]
PDF exported in PowerPoint

This isn't a matter of substituting font, even on the same system with the same fonts the text layout in text boxes is different.
Comment 3 Aron Budea 2021-02-14 06:56:58 UTC
Created attachment 169720 [details]
PDF exported in LO 7.1.0.3 (w Calibri)
Comment 4 Aron Budea 2021-02-14 07:08:57 UTC
Created attachment 169721 [details]
PPT saved in PP

What's interesting is that the PPT of the same presentation is shown almost perfectly identical, except the title on slide 3 (and a small issue on slide 5).
Comment 5 kevinpr 2021-11-27 19:06:40 UTC
Created attachment 176538 [details]
AnotherTest-Bad Render in LibreOffice
Comment 6 kevinpr 2021-11-27 19:08:03 UTC
Tested and confirmed in LibreOffice 7.2.2 vs MSOffice 2019 too, with the creator example, and with other example, attached, created with MSOffice 2016/2019 and opened later in LibreOffice 7.2.2

It's a problem when has to be alligned with images or icons too
Comment 7 Xisco Faulí 2022-05-02 14:03:47 UTC
A new major release of LibreOffice is available since this bug was reported.
Could you please try to reproduce it with the latest version of LibreOffice
from https://www.libreoffice.org/download/libreoffice-fresh/ ?
I have set the bug's status to 'NEEDINFO'. Please change it back to
'UNCONFIRMED' if the bug is still present in the latest version.
Comment 8 Gabor Kelemen (allotropia) 2022-06-23 11:47:41 UTC
Still not the same in:

Version: 7.4.0.0.beta1+ / LibreOffice Community
Build ID: 6ab56a4fc946f6294513f23a3ea47aa0aa154b7d
CPU threads: 8; OS: Linux 5.4; UI render: default; VCL: gtk3
Locale: hu-HU (hu_HU.UTF-8); UI: en-US
Calc: threaded

Text on the first slide overlaps the image at the bottom.
Comment 9 Regina Henschel 2022-06-23 12:39:00 UTC
The text is too high because the line spacing is wrong. The pptx-file has multiple 0.8 (in the UI of PP), but in LO it is "single". It should be "proportional 80%".

It is the 'lnSpcReduction' attribute of <a:normAutofit> element in <a:bodyPr> element. In this case lnSpcReduction="20000".

The implementation is missing.
https://opengrok.libreoffice.org/xref/core/oox/inc/drawingml/textbodyproperties.hxx?r=e2169886
The 'TextBodyProperties' struct has no member for it.

https://opengrok.libreoffice.org/xref/core/oox/source/drawingml/textbodypropertiescontext.cxx?r=0feeb94f#169
The case 'A_TOKEN( normAutofit ) does not evaluate the attribute.