Bug 148631 - Shading in some Ribbon shapes from ppt is missing
Summary: Shading in some Ribbon shapes from ppt is missing
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Impress (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: x86-64 (AMD64) All
: medium minor
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: difficultyMedium, easyHack, filter:ppt, skillCpp
Depends on:
Blocks: Shapes-Custom
  Show dependency treegraph
 
Reported: 2022-04-17 00:16 UTC by Regina Henschel
Modified: 2023-08-18 17:32 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
Document with ribbon-shapes (33.50 KB, application/vnd.ms-powerpoint)
2022-04-17 00:16 UTC, Regina Henschel
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Regina Henschel 2022-04-17 00:16:53 UTC
Created attachment 179620 [details]
Document with ribbon-shapes

Open attached document. It contains some shapes and screenshots how these shapes look in PowerPoint 97.
Notice, that some parts should be dark, but they are not.

The error is in the segment list in
https://opengrok.libreoffice.org/xref/core/svx/source/customshapes/EnhancedCustomShapeGeometry.cxx

The affected shapes are mso_sptRibbon, mso_sptElllipseRibbon2 and mso_EllipseRibbon.

The parts which are not dark although they should be dark have erroneously the command "no fill". That is 0xaa00 in the encoding in the segment list.

To investigate whether the "no fill" command is used in the shape, you can examine the property "CustomShapeGeometry", therein "Path", therein "Segments". This has the commands encoded as in
https://api.libreoffice.org/docs/idl/ref/EnhancedCustomShapeSegmentCommand_8idl.html

I think, this can become an easyhack.
Comment 1 Buovjaga 2023-01-06 14:00:00 UTC
Confirmed. Feel free to define as easy hack (I'm not sure about the difficulty level).

Arch Linux 64-bit, X11
Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: d6c54b3d4ee757958f9040a84dfbde0ab25f59bf
CPU threads: 8; OS: Linux 6.1; UI render: default; VCL: kf5 (cairo+xcb)
Locale: fi-FI (fi_FI.UTF-8); UI: en-US
Calc: threaded Jumbo
Built on 6 January 2023
Comment 2 Regina Henschel 2023-01-06 15:23:02 UTC
You need to read some old code, so it is not really for beginners who are in the step of learning the workflow. But I hope the code pointers are enough to make it difficultyMedium. I hope it gets interest because a fix will make a visible improvement.

Some time ago I have started a Wiki page about "Custom Shapes" for developers.
https://wiki.documentfoundation.org/Development/Custom_Shape_Orientation_Guide#struct_mso_CustomShape
It might help too to understand the code.