Bug 127989 - FILEOPEN PPTX full transparent hatch background is not set as 'no background'
Summary: FILEOPEN PPTX full transparent hatch background is not set as 'no background'
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Impress (show other bugs)
Version:
(earliest affected)
4.3 all versions
Hardware: All All
: medium normal
Assignee: Tünde Tóth
URL:
Whiteboard: target:7.4.0 target:7.3.0.2
Keywords: bibisected, bisected, filter:pptx
Depends on:
Blocks: OOXML-Shapes
  Show dependency treegraph
 
Reported: 2019-10-06 15:30 UTC by Regina Henschel
Modified: 2021-12-24 08:37 UTC (History)
5 users (show)

See Also:
Crash report or crash signature:


Attachments
HatchNoBackground.odp has a triangle with hatched fill and no background (13.91 KB, application/vnd.oasis.opendocument.presentation)
2019-10-06 15:30 UTC, Regina Henschel
Details
The original document and its PPTX version in Impress (88.42 KB, image/png)
2021-01-21 09:19 UTC, NISZ LibreOffice Team
Details
Screenshot of the original document in Impress and its PPTX version in PP (90.92 KB, image/png)
2021-01-21 09:30 UTC, NISZ LibreOffice Team
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Regina Henschel 2019-10-06 15:30:56 UTC
Created attachment 154782 [details]
HatchNoBackground.odp has a triangle with hatched fill and no background

Open attached document. It has a triangle with hatch filling, where the background of the hatch is set to 'no background'. That is draw:fill-hatch-solid="false" in ODF.

Save the document to pptx format. The saved file has correctly <a:alpha val="0" /> in the <a:bgClr> element. So when opening the file in PowerPoint, then the background of the hatch is transparent.

Now open the pptx file in LibreOffice. Notice the hatch background is red. ODF only allows "false" or "true" and not the continues values of the "alpha" element. But in case the alpha value is 0, which means full transparent, draw:fill-hatch-solid="false" should be used.
Comment 1 Julien Nabet 2019-10-06 19:20:20 UTC
On pc Debian x86-64 with master sources updated today, when I try to reproduce this, the pptx opened in LO indicates a white background.
Wrong too but with another color.
Comment 2 Xisco Faulí 2019-10-07 08:54:22 UTC
Just for the record, the issues started after https://cgit.freedesktop.org/libreoffice/core/commit/?id=f16368777b8b03164e3485143f014486e7cc69e2 < drawingML export: hatching of shapes >, before that, the hatching wasn't exported at all...

@Zolnai Tamás, I thought you might be interested in this issue...
Comment 3 Julien Nabet 2019-10-07 08:59:30 UTC
(In reply to Xisco Faulí from comment #2)
> Just for the record, the issues started after
> https://cgit.freedesktop.org/libreoffice/core/commit/
> ?id=f16368777b8b03164e3485143f014486e7cc69e2 < drawingML export: hatching of
> shapes >, before that, the hatching wasn't exported at all...
> 
> @Zolnai Tamás, I thought you might be interested in this issue...

There are 3 steps:
- initial odp
- export odp -> pptx
- import pptx -> odp
If I don't misunderstand ,the first 2 ones are ok, only the third is ko so not related to Tamás' commit?
Comment 4 Regina Henschel 2019-10-07 11:46:16 UTC
It seems to be in https://opengrok.libreoffice.org/xref/core/oox/source/drawingml/fillproperties.cxx?r=727ca36e#715

There  ShapeProperty::FillBackground is set to 'true' without considering transparency.
Comment 5 NISZ LibreOffice Team 2021-01-21 09:19:47 UTC
Created attachment 169071 [details]
The original document and its PPTX version in Impress

No hatching background color practically means transparency, but it's still replaced with white background on OOXML export in:

Version: 7.2.0.0.alpha0+ (x64) / LibreOffice Community
Build ID: 6ee7a3b2c0565c2871d32d704cb2899445b9f88d
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

This is not PPTX specific, happens with an odt->docx conversion as well.
Comment 6 NISZ LibreOffice Team 2021-01-21 09:30:00 UTC
Created attachment 169072 [details]
Screenshot of the original document in Impress and its PPTX version in PP

Looks good in PP. Only the PPTX reopen in Impress is problematic.
Comment 7 Commit Notification 2021-12-21 15:02:08 UTC
Tünde Tóth committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/001afbed910b7e565f602c1b11b1b4538cd59442

tdf#127989 OOXML: fix import of transparent hatching

It will be available in 7.4.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 8 Commit Notification 2021-12-21 20:24:01 UTC
Tünde Tóth committed a patch related to this issue.
It has been pushed to "libreoffice-7-3":

https://git.libreoffice.org/core/commit/642f85b234d61ed87ee74f94b713321572e6774e

tdf#127989 OOXML: fix import of transparent hatching

It will be available in 7.3.0.2.

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 9 BogdanB 2021-12-24 08:37:18 UTC
No problem in
Version: 7.4.0.0.alpha0+ / LibreOffice Community
Build ID: c13db6e792cc347ffff4585f23866f195651f21f
CPU threads: 4; OS: Linux 5.11; UI render: default; VCL: gtk3
Locale: ro-RO (ro_RO.UTF-8); UI: en-US
Calc: threaded