Bug 154855

Summary: FILESAVE DOCX "Layout in table cell" setting lost with "in front of text" shape
Product: LibreOffice Reporter: Gabor Kelemen (allotropia) <kelemeng>
Component: WriterAssignee: Miklos Vajna <vmiklos>
Status: RESOLVED FIXED    
Severity: normal CC: aron.budea, vmiklos
Priority: medium Keywords: bibisected, bisected, regression
Version: 7.4.0.3 release   
Hardware: All   
OS: All   
See Also: https://bugs.documentfoundation.org/show_bug.cgi?id=94238
https://bugs.documentfoundation.org/show_bug.cgi?id=157707
Whiteboard: target:7.6.0 target:7.5.4
Crash report or crash signature: Regression By:
Bug Depends on:    
Bug Blocks: 104442    
Attachments: The example file saved to DOCX with current master
The original file in Word 2013 and its exported version in 2016

Description Gabor Kelemen (allotropia) 2023-04-17 09:57:24 UTC
Created attachment 186714 [details]
The example file saved to DOCX with current master

attachment 118734 [details] from bug 94238 is a compatibiltiymode 14 docx, with some drawing shapes in a table.
When this is saved as docx, then reopened in Word, all shapes are placed in the first cell of the column.

1. Open attachment 118734 [details] 
2. Save as docx, open it in Word

-> All shapes are in the first cells of the columns on top of each other.

This is because now the "Layout in table cell" box is unchecked. Checking it places the shapes back to the correct location.

Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: fc6806c4be8585ce0d35a6b581bf8b3dbf858500
CPU threads: 14; OS: Windows 10.0 Build 19045; UI render: Skia/Raster; VCL: win
Locale: en-US (hu_HU); UI: en-US
Calc: threaded

This was good in 7.3, broke in 7.4 with:

author	Miklos Vajna <vmiklos@collabora.com>	Mon Jan 24 12:53:25 2022 +0100
committer	Miklos Vajna <vmiklos@collabora.com>	Mon Jan 24 15:10:24 2022 +0100

DOCX import: fix <wp:anchor layoutInCell="1"> with <wp:wrapNone>

Adding CC to: Miklos Vajna
Comment 1 Gabor Kelemen (allotropia) 2023-04-17 09:58:41 UTC
Created attachment 186715 [details]
The original file in Word 2013 and its exported version in 2016
Comment 2 Commit Notification 2023-04-26 06:03:47 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/8d0acd88214180f93cd09730baa1ed9a8169e987

tdf#154855 DOCX export: fix <wp:anchor layoutInCell="1"> with <wp:wrapNone>

It will be available in 7.6.0.

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 3 Commit Notification 2023-05-03 08:05:51 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "libreoffice-7-5":

https://git.libreoffice.org/core/commit/d9c62a8b3213fb18869ec9a0236f838debee18ed

tdf#154855 DOCX export: fix <wp:anchor layoutInCell="1"> with <wp:wrapNone>

It will be available in 7.5.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.