Bug 119617 - FILEOPEN PPTX Text box setting "Resize shape to fit text" not imported correctly ( steps in comment 8 )
Summary: FILEOPEN PPTX Text box setting "Resize shape to fit text" not imported correc...
Status: RESOLVED DUPLICATE of bug 157285
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Impress (show other bugs)
Version:
(earliest affected)
6.1.0.0.alpha0+
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: target:6.2.0 target:6.1.4
Keywords: filter:pptx
Depends on:
Blocks: PPTX-Textbox
  Show dependency treegraph
 
Reported: 2018-08-31 08:04 UTC by Gabor Kelemen (allotropia)
Modified: 2024-04-02 16:53 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
Example file from Powerpoint (30.83 KB, application/vnd.openxmlformats-officedocument.presentationml.presentation)
2018-08-31 08:04 UTC, Gabor Kelemen (allotropia)
Details
Screenshot of the file in PP and LO side by side (95.79 KB, image/png)
2018-08-31 08:04 UTC, Gabor Kelemen (allotropia)
Details
Screenshot MSO LO before and after (129.65 KB, image/png)
2019-10-04 07:55 UTC, Timur
Details
How the original file and its Impress saved version looks in PP 2013 (69.65 KB, image/png)
2021-01-28 10:37 UTC, NISZ LibreOffice Team
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Gabor Kelemen (allotropia) 2018-08-31 08:04:09 UTC
Created attachment 144568 [details]
Example file from Powerpoint

Attached PPTX file has a text box with a long text, and is set to "Resize shape to fit text".

In Impress this opens with the top of the text disappearing and the Fit height to text setting enabled.

It would be nice to have the "Resize shape to fit text" setting working for such text boxes.
Comment 1 Gabor Kelemen (allotropia) 2018-08-31 08:04:51 UTC
Created attachment 144569 [details]
Screenshot of the file in PP and LO side by side

Version: 6.2.0.0.alpha0+
Build ID: af579ed7d1482df5cfa7e12e8af2603917d40602
CPU threads: 4; OS: Windows 6.3; UI render: default; 
Locale: hu-HU (hu_HU); Calc: CL
Comment 2 Roman Kuznetsov 2018-08-31 11:14:50 UTC Comment hidden (obsolete)
Comment 3 Gabor Kelemen (allotropia) 2018-08-31 11:37:14 UTC
(In reply to Roman Kuznetsov from comment #2)
> hm, in 
> 
> Version: 6.1.1.1
> Build ID: 2718b4a18dfcc6a54ebe5f7b801ee7a47fa81e0c
> CPU threads: 4; OS: Windows 6.1; UI render: default; 
> Locale: ru-RU (ru_RU); Calc: group threaded
> 
> I can't select textbox or text on slide

Yes, that may be another problem, we noticed it too.

Try the Navigator in the Sidebar, then click the Alcím 2 object.
Comment 4 Commit Notification 2018-09-11 07:56:07 UTC
Balazs Varga committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=86b14cc8bd910651cef422a0f7408adc0fc51a17

tdf#119617 Fix export of Autofit property of shapes to PPTX

It will be available in 6.2.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 5 Timur 2018-09-14 08:16:40 UTC
Sorry for not following, but this bug is fileopen. From what I see, text in the box was shown on fileopen up to 6.0.6 and it's not from 6.1. So this looks like a regression to me. Or please explain what is to be fixed here. 

As for "Fix export of Autofit property", there's bug 90407 but it doesn't seem fixed with this commit.
Comment 6 Balázs Varga 2018-09-14 09:06:13 UTC
Yes, of course. There are three option in the OOXML standerd which is used in PowerPoint. The "noAutoFit" ; "normAutofit" ; spAutofit. The normAutofit property was exported, but the other two was not.
In PowerPoint these three shape options are in the Shape formatting-->textbox property. In Impress I did not find a GUI setting for the normAutofit property (even so this property is imported and exported too). But the spAutofit/noAutofit can be set in the shape's textbox. (insert a shape-->click on the inserted shape-->Format-->Object and Shape-->Text). So I think with this patch will be exported the other two option. I thought that the "Resize shape to fit text" setting problem is an export problem (because it is imported fine) just like was here: https://cgit.freedesktop.org/libreoffice/core/commit/?id=7626dc2d81dc5eb647d6f8937cc1d220a8b8ef4b
Comment 7 Balázs Varga 2018-09-14 09:36:08 UTC
Ohh, I see, I tested with another shape (Insert-->Shape-->Basic-->Rectangle), not the same as in the report. Nonetheless, this patch fix the export of the shape's autoFit property, but not the import. Sorry for that. I'll see what can be done there.
Comment 8 Balázs Varga 2018-09-18 07:42:08 UTC
The simplest way to reproduce this BUG from zero.

1. Create a new Impress file. (no need to save).
2. Right click on the second textbox ("Click to add text") of the first Slide and choose the "Text..." option.
3. Checkout the "Fit height to text" property and click OK.
4. Reduce the textbox height. (optional: about half of the original size).
5. Go back to the "Fit height to text" property check the checkbox and click OK.

The textbox height will be returned to the original size.
Comment 9 Commit Notification 2018-10-31 09:29:40 UTC
Balazs Varga committed a patch related to this issue.
It has been pushed to "libreoffice-6-1":

https://git.libreoffice.org/core/+/4c52fbe77bee70c770f964fa3506ad6cdd43a312%5E%21

tdf#119617 Fix export of Autofit property of shapes to PPTX

It will be available in 6.1.4.

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 10 Roman Kuznetsov 2019-01-08 19:04:02 UTC
Gabor, please retest this bug in LO 6.2.0.1. May be need close it as "Resolved Fixed" because Balazs Varga already made a patch
Comment 11 Xisco Faulí 2019-09-17 11:37:37 UTC
it seems fix to me

Version: 6.4.0.0.alpha0+
Build ID: c56bf1479cc71d1a2b0639f6383e90c1f7e3655b
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: ca-ES (ca_ES.UTF-8); UI-Language: en-US
Calc: threaded

Closing as VERIFIED FIXED
Comment 12 Timur 2019-10-04 07:55:43 UTC
Created attachment 154747 [details]
Screenshot MSO LO before and after

I see text inside is shown properly. 
Still, some shapes are not resized as they should.
Comment 13 Timur 2020-11-02 12:32:02 UTC
I reopen for a comment on Comment 12. 
Normally when a time passes we don't reopen but open a new bug, but this is the same issue of this bug and I made a comment after the fix. 
I should have reopened it immediately. 
In 7.1+ same as after the fix, see the box size. 
When Xisco verified, I don't know if it was by the look or by box size. 
Please review.
Comment 14 NISZ LibreOffice Team 2021-01-28 10:37:10 UTC
Created attachment 169222 [details]
How the original file and its Impress saved version looks in PP 2013

It goes from "Resize shapes to text" to "No automatic resize" in:

Version: 7.2.0.0.alpha0+ (x64) / LibreOffice Community
Build ID: 7eb289c49cc7245ef3001a39be0c15d06bbe875b
CPU threads: 4; OS: Windows 6.3 Build 9600; UI render: Skia/Raster; VCL: win
Locale: en-US (hu_HU); UI: en-US
Calc: CL
Comment 15 Gabor Kelemen (allotropia) 2024-04-02 16:36:28 UTC
The fileopen issue as seen on the attachment 144569 [details] is now fixed with

https://git.libreoffice.org/core/commit/40d3d510fca99b555381deb74b9915c91c924de5

tdf#157285 PPTX import: fix placeholder height

Now the textbox is resized automatically on open, which makes this one a duplicate.

Saving to PPTX is still not really good, as mentioned in the last comment.
Earlier patches solved this issue for a different kind of drawing object ("Custom Shape") vs "Drawing Object" when you go to Format - Text box and Shape - Text attributes.

*** This bug has been marked as a duplicate of bug 157285 ***