Bug 115328 - Impress: paragraph margins do not work correctly with AutoFit text boxes
Summary: Impress: paragraph margins do not work correctly with AutoFit text boxes
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Impress (show other bugs)
Version:
(earliest affected)
6.0.0.3 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Autofit
  Show dependency treegraph
 
Reported: 2018-01-31 11:14 UTC by Callegar
Modified: 2023-08-25 17:15 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
Sample case (31.39 KB, application/vnd.oasis.opendocument.presentation)
2023-02-03 11:50 UTC, Callegar
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Callegar 2018-01-31 11:14:38 UTC
Description:
When using autofit text boxes in impress, text is automatically scaled to fit the box.

If some paragraphs have margins set to some width tighter than the box width, they are respected as long as text is not scaled. When text is scaled the margins are wrong.

Steps to Reproduce:
1. Open impress
2. Insert some text in a slide, using the default box that, by default, should have autofit on (if it does not have autofit on, switch it on). Assure that the text has multiple paragraphs. Also, assure that enough text is put in the box that the autofit function can operate, by rescaling the text.
3. Put the text cursor in one paragraph. Now, go the the margins ruler and drag the right margin pointer left. While you do so, a thin vertical line should appear across the slide, indicating the actual place where the text should wrap because of the margin. Choose some point about halfway through the slide text box.


Actual Results:  
Observe that the paragraph is actually been reflowed to a tighter right margin, but not as much as it should. Text does not end at the place where the vertical line appeared during the margin set, but to the right of it. The actual error depends on the scaling that was applied because of autofit. The larger the rescaling, the larger the error. 

Expected Results:
The paragraph should be reflown ending at the place where the vertical line appeared during the margin set.


Reproducible: Always


User Profile Reset: No



Additional Info:
I think that LibO forgets to "internally adjust" the after text indent according to the scaling.


[Information automatically included from LibreOffice]
Locale: en-US
Module: PresentationDocument
[Information guessed from browser]
OS: Linux (All)
OS is 64bit: yes


User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:58.0) Gecko/20100101 Firefox/58.0
Comment 1 Regina Henschel 2018-01-31 14:18:17 UTC
It seems that the right margin is scaled with the same factor as the font size. Font size 32pt, margin right 5cm is scaled down to font size 24pt, margin about 3.8cm for example.
I think, that it is error, because this attribute should only change the displayed font size.
I have tested it in Version: 6.1.0.0.alpha0+ (x64)
Build ID: facfc2951ea9f4745edd4a6fb1cf97697f33f40a
CPU threads: 8; OS: Windows 10.0; UI render: default; 
TinderBox: Win-x86_64@62-TDF, Branch:master, Time: 2018-01-14_00:42:04
Locale: de-DE (de_DE); Calc: CL
Comment 2 QA Administrators 2019-02-01 03:46:00 UTC Comment hidden (obsolete)
Comment 3 Callegar 2019-02-02 17:02:10 UTC
Still an issue as of 6.2.0.3 and 6.1.5.2.
Comment 4 QA Administrators 2021-02-02 03:50:29 UTC Comment hidden (obsolete)
Comment 5 QA Administrators 2023-02-03 03:22:20 UTC Comment hidden (obsolete)
Comment 6 Callegar 2023-02-03 11:50:47 UTC
Created attachment 185082 [details]
Sample case

The issue is still present as of 7.4.5.

Added a sample case to ease testing with the next libo versions.