Bug 142858 - FILESAVE Own shadow is not written, if MSO 'reflection' effect exists
Summary: FILESAVE Own shadow is not written, if MSO 'reflection' effect exists
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
7.2.0.0 alpha1+
Hardware: x86-64 (AMD64) Windows (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: filter:docx
Depends on:
Blocks: 142361
  Show dependency treegraph
 
Reported: 2021-06-14 21:13 UTC by Regina Henschel
Modified: 2023-07-12 07:11 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
Document to use as start for reproducing the bug (19.05 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2021-06-14 21:13 UTC, Regina Henschel
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Regina Henschel 2021-06-14 21:13:34 UTC
Created attachment 172877 [details]
Document to use as start for reproducing the bug

Open attached document in Word, to see that it has a shape with effect 'Reflection'. Close.

Open document in LibreOffice Daily.
Select the shape and add a shadow: Direction Top, 0.5" distance, Color Black, 4pt Blur, 60% Transparency. Other shadow settings produce the error too, but so the shadow is good visible.

Save the document as new docx document.
Open the saved document in LibreOffice or Word.

Error: There is not shadow.
Expected: Shadow exists.

The problem is in method DrawingML::WriteShapeEffects in oox/source/export/drawingml.cxx.

If aEffects.hasElements() is true - which is the case here, because it contains the effect 'Reflection', then the flow goes to 'else'. There it starts immediately with a loop over aOuterShdwProps. But that is empty, because the InteropGrabBag does not have a shadow, but shadow was newly set in LibreOffice.

How to export an own shadow can be seen in #4243-#4266.

It is an error in the flow logic.
Comment 1 Xisco Faulí 2021-07-07 10:08:01 UTC
Moving to NEW
Comment 2 Sophie Sipasseuth 2023-06-29 13:57:27 UTC
Hello Regina,

Thank you for reporting the bug.
I cannot see any reflection effect on the moon in Microsoft Word or LibreOffice Writer.
Could you confirm this is a good document to use to reproduce the bug, please?

Best regards
Comment 3 Buovjaga 2023-07-12 07:11:28 UTC
In the chat, Sophie told me she used Word 2007, which is apparently too old to render the reflection. I see the reflection in office.com

I reproduce the disappearing shadow.

Arch Linux 64-bit, X11
Version: 24.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: a389e6bd7aacfa4e1ff1ea3a46199fb381d1131f
CPU threads: 8; OS: Linux 6.4; UI render: default; VCL: kf5 (cairo+xcb)
Locale: fi-FI (fi_FI.UTF-8); UI: en-US
Calc: threaded
Built on 10 July 2023