Bug 148137 - [DOCX] Shape with image fill not being imported
Summary: [DOCX] Shape with image fill not being imported
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
7.3.1.3 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: bibisected, bisected, regression
Depends on:
Blocks: OOXML-Shapes DOCX-Images
  Show dependency treegraph
 
Reported: 2022-03-22 12:54 UTC by Rafael Lima
Modified: 2024-02-02 12:51 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments
Sample DOCX file (429.68 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2022-03-22 12:54 UTC, Rafael Lima
Details
Screenshot from MS Word (84.04 KB, image/png)
2022-03-22 12:55 UTC, Rafael Lima
Details
Screenshot from LO Writer (41.24 KB, image/png)
2022-03-22 12:56 UTC, Rafael Lima
Details
Minimal example file with two crop-to-shape images and one image filled shape (257.94 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2022-11-29 21:59 UTC, Gabor Kelemen (allotropia)
Details
The minimal example in Word 2016 and 7.5 master (293.05 KB, image/png)
2022-11-29 21:59 UTC, Gabor Kelemen (allotropia)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Rafael Lima 2022-03-22 12:54:33 UTC
Created attachment 179030 [details]
Sample DOCX file

See the attached DOCX file. It has a triangular shape at the top right of the page with an image as the fill.

Opening it in MS Word shows the triangular shape and its image fill. Importing it into LO Writer will cause the image fill to disappear. For some reason it is not being imported.

Below I'll attach screenshots of what I see in Word and Writer.

System info:
Version: 7.3.1.3 (x64) / LibreOffice Community
Build ID: a69ca51ded25f3eefd52d7bf9a5fad8c90b87951
CPU threads: 1; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL: win
Locale: pt-BR (pt_BR); UI: pt-BR
Calc: threaded
Comment 1 Rafael Lima 2022-03-22 12:55:40 UTC
Created attachment 179031 [details]
Screenshot from MS Word

This is how the document is rendered in MS Word.
Comment 2 Rafael Lima 2022-03-22 12:56:30 UTC
Created attachment 179032 [details]
Screenshot from LO Writer

This is how the document is rendered in LO Writer.
Comment 3 Sarah johnson 2022-03-22 15:28:49 UTC Comment hidden (spam)
Comment 4 Dieter 2022-04-05 07:15:28 UTC
I confirm it with

Version: 7.3.2.2 (x64) / LibreOffice Community
Build ID: 49f2b1bff42cfccbd8f788c8dc32c1c309559be0
CPU threads: 4; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL: win
Locale: zh-CN (de_DE); UI: en-GB
Calc: CL
Comment 5 Gabor Kelemen (allotropia) 2022-11-29 21:58:18 UTC
This was made with the Picture - Crop - Crop to shape tool in Word. Which is apparently not exactly the same as an image filled shape, because those look good.

Looked good in 7.0, blue fill in 7.1+ since 

https://git.libreoffice.org/core/+/9fe881410909c5273cef517433411bc4eceee294

author	Gülşah Köse <gulsah.kose@collabora.com>	Sun Aug 23 22:32:53 2020 +0300
committer	Gülşah Köse <gulsah.kose@collabora.com>	Mon Aug 24 16:20:37 2020 +0200

tdf#134174 Fix the rotation of bitmap filled custom shapes.

Adding CC to: Gülşah Köse
Comment 6 Gabor Kelemen (allotropia) 2022-11-29 21:59:18 UTC
Created attachment 183895 [details]
Minimal example file with two crop-to-shape images and one image filled shape
Comment 7 Gabor Kelemen (allotropia) 2022-11-29 21:59:59 UTC
Created attachment 183896 [details]
The minimal example in Word 2016 and 7.5 master
Comment 8 Justin L 2023-06-03 21:34:32 UTC
repro 7.6+
Comment 9 Justin L 2024-02-01 16:42:35 UTC
backport fixed in 7.6.x with
24.2 commit 6d8c6e8d60956fd36094035a526c1a29a902204b
Author: Noel Grandin on Wed Aug 30 21:47:41 2023 +0200
    fix ImpGraphic::operator==
    
    This was broken in
        6.1 commit 7b355669c6ddeab2e6cec692d6afdff41c61d0fb
Comment 10 Rafael Lima 2024-02-02 12:51:46 UTC
Thanks for the info. This was backported to 7.6 as well.

Verified with

Version: 7.6.4.1 (X86_64) / LibreOffice Community
Build ID: 60(Build:1)
CPU threads: 16; OS: Linux 6.5; UI render: default; VCL: kf5 (cairo+xcb)
Locale: pt-BR (pt_BR.UTF-8); UI: en-US
Ubuntu package version: 4:7.6.4-0ubuntu0.23.10.1
Calc: threaded