Bug 73022 - FILEOPEN: shapes of DOCX missing colors (better if ungrouped in MSO but not good)
Summary: FILEOPEN: shapes of DOCX missing colors (better if ungrouped in MSO but not g...
Status: RESOLVED DUPLICATE of bug 66039
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
4.2.0.1 rc
Hardware: Other All
: medium normal
Assignee: Attila Bakos (NISZ)
URL:
Whiteboard:
Keywords: filter:docx, implementationError
Depends on:
Blocks: DOCX-Grouped-Shapes
  Show dependency treegraph
 
Reported: 2013-12-25 02:25 UTC by David Delma
Modified: 2022-02-03 12:01 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
docx file with flowchart not well rendering in writer (58.28 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2013-12-25 02:25 UTC, David Delma
Details
docx file with flowchart not well rendering in writer (58.28 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2013-12-25 02:28 UTC, David Delma
Details
PDF export using 4.3.2.2 (79.89 KB, application/pdf)
2014-10-08 10:14 UTC, Buovjaga
Details
PDF export using 4.4.0.0 alpha from Oct 8 (79.19 KB, application/pdf)
2014-10-08 10:15 UTC, Buovjaga
Details
DOCX compared in MSO and LO 6.3+ (110.27 KB, image/jpeg)
2019-04-30 11:03 UTC, Timur
Details
Minimized test document in docx format (21.29 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2020-09-09 09:51 UTC, NISZ LibreOffice Team
Details
The minimized example file in Word and Writer (59.76 KB, image/png)
2020-09-09 09:52 UTC, NISZ LibreOffice Team
Details
How it looks in LibreOffice 7.2 master (41.00 KB, image/png)
2021-04-07 19:18 UTC, Xisco Faulí
Details
How it looks after 2a70cfb09c (19.42 KB, image/png)
2021-05-06 15:03 UTC, Xisco Faulí
Details
Example file with paragraph shading in grouped shapes (17.68 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2021-05-17 06:47 UTC, NISZ LibreOffice Team
Details
attachment 172074 in Word and Writer side by side (72.18 KB, image/png)
2021-05-17 06:50 UTC, NISZ LibreOffice Team
Details
The test file in the Master after pressing down key (327.34 KB, image/jpeg)
2022-01-10 12:07 UTC, Attila Bakos (NISZ)
Details
docx compared in MSO and LO 7.3 and 7.4+ (125.10 KB, image/png)
2022-01-10 12:16 UTC, Timur
Details

Note You need to log in before you can comment on or make changes to this bug.
Description David Delma 2013-12-25 02:25:45 UTC
Created attachment 91179 [details]
docx file with flowchart not well rendering in writer

The background colors of the flowchart are lost and some objects missplaced.
Comment 1 David Delma 2013-12-25 02:28:28 UTC
Created attachment 91180 [details]
docx file with flowchart not well rendering in writer
Comment 2 Buovjaga 2014-10-08 10:14:58 UTC
Created attachment 107548 [details]
PDF export using 4.3.2.2

Looking mighty borked.
Comment 3 Buovjaga 2014-10-08 10:15:55 UTC
Created attachment 107549 [details]
PDF export using 4.4.0.0 alpha from Oct 8

Bork bork, but different.
Comment 4 Xisco Faulí 2015-09-09 14:27:36 UTC
This issue is still present in

Version: 5.0.1.2
Build ID: 81898c9f5c0d43f3473ba111d7b351050be20261
Locale: es-ES (es_ES)

on Windows 7 (64-bit)
Comment 5 QA Administrators 2016-09-20 10:28:29 UTC Comment hidden (obsolete)
Comment 6 David Delma 2016-11-18 17:13:12 UTC Comment hidden (obsolete)
Comment 7 QA Administrators 2017-12-11 08:55:06 UTC Comment hidden (obsolete)
Comment 8 Timur 2019-04-30 11:03:12 UTC
Created attachment 151089 [details]
DOCX compared in MSO and LO 6.3+
Comment 9 NISZ LibreOffice Team 2020-09-08 15:04:00 UTC
Grouped shape.
Comment 10 NISZ LibreOffice Team 2020-09-09 09:51:01 UTC
Created attachment 165307 [details]
Minimized test document in docx format
Comment 11 NISZ LibreOffice Team 2020-09-09 09:52:42 UTC
Created attachment 165308 [details]
The minimized example file in Word and Writer

This part of the document.xml is suspicious:

														<a:ext uri="{AF507438-7753-43E0-B8FC-AC1667EBCBE1}">
															<a14:hiddenEffects xmlns:a14="http://schemas.microsoft.com/office/drawing/2010/main">
																<a:effectLst>
																	<a:outerShdw dist="35921" dir="2700000" algn="ctr" rotWithShape="0">
																		<a:srgbClr val="808080"/>
																	</a:outerShdw>
																</a:effectLst>
															</a14:hiddenEffects>
														</a:ext>
Comment 12 Xisco Faulí 2021-04-07 19:18:02 UTC
Created attachment 171018 [details]
How it looks in LibreOffice 7.2 master
Comment 13 Regina Henschel 2021-04-22 20:40:24 UTC
The erroneous skew of the first group shape in "docx file with..." is fixed with commit https://cgit.freedesktop.org/libreoffice/core/commit/?id=2a70cfb09c4d89154d229b6a95cf076e8bd76798

The colors are still missing.
Comment 14 Xisco Faulí 2021-05-06 15:03:58 UTC
Created attachment 171704 [details]
How it looks after 2a70cfb09c
Comment 15 NISZ LibreOffice Team 2021-05-17 06:47:25 UTC
Created attachment 172074 [details]
Example file with paragraph shading in grouped shapes

The colors in the original document are set with paragraph shading.

This is not yet supported with the editeng shapes that grouped shapes are converted to. See bug 100074 about changing that to Writer textboxes.
Comment 16 NISZ LibreOffice Team 2021-05-17 06:50:52 UTC
Created attachment 172076 [details]
attachment 172074 [details] in Word and Writer side by side

Version: 7.2.0.0.alpha1+ (x64) / LibreOffice Community
Build ID: 91330c503b7eb91d777978018b66890af87cf8f5
CPU threads: 4; OS: Windows 10.0 Build 18363; UI render: default; VCL: win
Locale: hu-HU (hu_HU); UI: en-US
Calc: CL
Comment 17 László Németh 2022-01-06 09:41:57 UTC

*** This bug has been marked as a duplicate of bug 66039 ***
Comment 18 Timur 2022-01-10 11:30:10 UTC Comment hidden (obsolete)
Comment 19 Attila Bakos (NISZ) 2022-01-10 12:00:22 UTC
(In reply to Timur from comment #18)
> Original DOCX attachment 91180 [details] is not good for 3 reasons: 
> 1. missing colors as in the bug title - so why was this closed as a
> duplicate?
> 2. fileopen regressed in LO 7.3 - I'll report separately or See Also 
> 3. even before regression, Windows opened 1 page and Linux 2 - but that's
> likely an existing bug with Microsoft fonts.
> 
> Until this is clarified, I set Reopen.

Sorry I tested it with the minimized version, and that worked, and this also works, but there is a regression only with the Z-order of the textbox and shape pairs. To make sure of that, select the group object and press a down button. Everything will be fine about the colors. Z-order will be fixed soon, sorry for regressing that. (Initial synchronizing missing) :) (If you wish this can be stay in Reopened state, but i think the colors are fixed.)
Comment 20 Attila Bakos (NISZ) 2022-01-10 12:07:26 UTC
Created attachment 177427 [details]
The test file in the Master after pressing down key
Comment 21 Timur 2022-01-10 12:16:15 UTC
Created attachment 177428 [details]
docx compared in MSO and LO 7.3 and 7.4+

Let this stay open until we see a change. 

Here is original DOCX attachment 91180 [details] compared in MSO and LO which shows: 
1. missing colors as in the bug title - seen only after Down key
2. text missing - regression from LO 7.4, seen after Down key
3. wrong position, elements split - regression from LO 7.3
(4. even before regression, Windows opened 1 page and Linux 2 - but that's likely an existing bug with Microsoft fonts).
Comment 22 Attila Bakos (NISZ) 2022-01-10 12:25:11 UTC
(In reply to Timur from comment #21)
> Created attachment 177428 [details]
> docx compared in MSO and LO 7.3 and 7.4+
> 
> Let this stay open until we see a change. 
> 
> Here is original DOCX attachment 91180 [details] compared in MSO and LO
> which shows: 
> 1. missing colors as in the bug title - seen only after Down key
> 2. text missing - regression from LO 7.4, seen after Down key
> 3. wrong position, elements split - regression from LO 7.3
> (4. even before regression, Windows opened 1 page and Linux 2 - but that's
> likely an existing bug with Microsoft fonts).

Okey, I make a quick fix for the Z-orders because this is not implemented well for  group shapes. After that i fixed we can check it again. (problems what you noticed 1-2)
My patch about group shapes so the 3rd one of the problem not connected to directly to that fix. (not supposed to) See the 7.3 version where they have color so they are ungrouped.
If i finish with the patch with Z-orders i will mention this bug in the commit message if you wish.
Comment 23 Timur 2022-01-10 12:40:48 UTC
Opening of original and MSO-saved DOCX is different. What I wrote is for original, MSO-saved DOCX is better. I reported 7.3 regression of original DOCX as bug 146681.
Comment 24 Attila Bakos (NISZ) 2022-01-11 11:21:01 UTC
Fix soon: https://gerrit.libreoffice.org/c/core/+/128279 After merge this is fixed too as the 11th duplicate of the #66039 :)
Comment 25 Timur 2022-01-12 10:33:11 UTC
Thanks Attila for working on this. 
I see you asked about test, surely if you can make it, great.
Comment 26 Timur 2022-02-02 11:05:00 UTC
This fix seems forgotten, it just needs a review IIUC.
Comment 27 Attila Bakos (NISZ) 2022-02-02 13:24:32 UTC
(In reply to Timur from comment #26)
> This fix seems forgotten, it just needs a review IIUC.

done. :)
Comment 28 Attila Bakos (NISZ) 2022-02-02 13:46:29 UTC

*** This bug has been marked as a duplicate of bug 66039 ***
Comment 29 Timur 2022-02-03 12:01:03 UTC
Text and colors are back now, tested in Windows. 
Original 2007 DOCX somewhat cuts text so DIRIGEANTS and ASSISTANTS have no bottom. 
Not a problem with MSO saved DOCX.