Download it now!
Bug 112313 - FILESAVE Text below image moves up next to it when file saved as DOCX
Summary: FILESAVE Text below image moves up next to it when file saved as DOCX
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
4.2.0.4 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: bibisected, bisected, filter:docx, regression
Depends on:
Blocks: DOCX DOCX-Anchor-and-Text-Wrap
  Show dependency treegraph
 
Reported: 2017-09-10 23:04 UTC by Aron Budea
Modified: 2021-01-20 07:51 UTC (History)
6 users (show)

See Also:
Crash report or crash signature:


Attachments
Sample ODT, save as DOCX (10.04 KB, application/vnd.oasis.opendocument.text)
2017-09-10 23:04 UTC, Aron Budea
Details
text-image_8f8b31abd02876c3601e343b8b3274754f8a61b6.pdf: what completely broken means (7.01 KB, application/pdf)
2017-11-06 15:25 UTC, Justin L
Details
text-image_word2003.pdf: how it looks in MS Office 2003 (2.82 KB, application/pdf)
2017-11-06 17:37 UTC, Justin L
Details
Original ODT saved as PDF from MSO 2013 (15.67 KB, application/pdf)
2017-11-11 13:11 UTC, Buovjaga
Details
DOCX from LibreOffice saved as PDF from MSO2013 (15.66 KB, application/pdf)
2017-11-11 13:12 UTC, Buovjaga
Details
The example file after manually changing the wrapping to None (10.38 KB, application/vnd.oasis.opendocument.text)
2020-12-16 15:25 UTC, NISZ LibreOffice Team
Details
The changed example file saved to DOCX with current Writer (6.13 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2020-12-16 15:25 UTC, NISZ LibreOffice Team
Details
The modified docx side by side in Word and Writer (170.65 KB, image/png)
2020-12-16 15:28 UTC, NISZ LibreOffice Team
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Aron Budea 2017-09-10 23:04:03 UTC
Created attachment 136159 [details]
Sample ODT, save as DOCX

Open the attached ODT, containing an inserted image, and text above and below.
Save it as DOCX.
Reopen the DOCX.

=> The bottom text is repositioned next to the image.

Observed using LO 5.4.1.2 & 4.2.0.4 / Windows 7.
Not reproduced using LO 4.1.0.4.
=> regression
Comment 2 Buovjaga 2017-09-11 06:55:31 UTC
Repro.

Arch Linux 64-bit, KDE Plasma 5
Version: 6.0.0.0.alpha0+
Build ID: 09122a537318f7ada075820f3b1ef83a64e56751
CPU threads: 8; OS: Linux 4.12; UI render: default; VCL: kde4; 
Locale: fi-FI (fi_FI.UTF-8); Calc: group
Built on September 10th 2017
Comment 3 Justin L 2017-11-06 15:25:21 UTC
Created attachment 137576 [details]
text-image_8f8b31abd02876c3601e343b8b3274754f8a61b6.pdf: what completely broken means

First broken completely in 4.2 by commit 8f8b31abd02876c3601e343b8b3274754f8a61b6 Author: Luboš Luňák  CommitDate: Tue Aug 6 17:17:53 2013 +0200
  compatibility setting for MS Word wrapping text in less space (bnc#822908)
Comment 4 Justin L 2017-11-06 17:37:23 UTC
Created attachment 137579 [details]
text-image_word2003.pdf: how it looks in MS Office 2003

I'd probably flag this as notabug. The document is DESIGNED to have the text flow optimally, which implies that if there is room, the text should go beside. Microsoft Office wraps the text around too - thus it makes sense that LO should do the same. If there is any bug here, it is the difference in how the wrapping is taking place. This should be checked with Word 2013 as well, for recent confirmation (and also see how Word handles the original .odt).
Comment 5 Buovjaga 2017-11-11 13:11:58 UTC
Created attachment 137680 [details]
Original ODT saved as PDF from MSO 2013
Comment 6 Buovjaga 2017-11-11 13:12:49 UTC
Created attachment 137681 [details]
DOCX from LibreOffice saved as PDF from MSO2013
Comment 7 Kevin Suo 2017-12-21 04:01:25 UTC Comment hidden (obsolete)
Comment 8 QA Administrators 2019-10-11 02:37:58 UTC Comment hidden (obsolete, spam)
Comment 9 NISZ LibreOffice Team 2020-12-16 15:24:18 UTC
This image is horizontally positioned as "Center" to "Paragraph area" and with optimal wrap.
This is similar to the example file in bug #124059 - the image of the shopping cart has the same settings.

Now to reproduce the original layout in docx you need to set it as No wrap (Writer) / Below&above (in Word). 

Setting "No Wrap" does not change the layout in Writer, but retains it after saving to docx when it is then reopened in Word (tested with my 2013) and Writer.
Comment 10 NISZ LibreOffice Team 2020-12-16 15:25:19 UTC
Created attachment 168231 [details]
The example file after manually changing the wrapping to None
Comment 11 NISZ LibreOffice Team 2020-12-16 15:25:59 UTC
Created attachment 168232 [details]
The changed example file saved to DOCX with current Writer

Version: 7.2.0.0.alpha0+ (x64)
Build ID: 59301a1cadd87a63276650975252d14e8477e632
CPU threads: 4; OS: Windows 6.3 Build 9600; UI render: Skia/Raster; VCL: win
Locale: hu-HU (hu_HU); UI: en-US
Calc: CL
Comment 12 NISZ LibreOffice Team 2020-12-16 15:28:52 UTC
Created attachment 168233 [details]
The modified docx side by side in Word and Writer
Comment 13 NISZ LibreOffice Team 2020-12-17 09:02:15 UTC
Just checked the images in bug #117611 - those are also centered to paragraph, with optimal wrap. 
Setting no wrap in docx restores the intended layout for those too.

There is however a bit more spacing between the image and the text in that mode, as seen on the previous attachment #168233 [details] . 
That causes some layout difference with the example in bug #124059, making paragraphs at the bottom of the first page wrap to the next page.