Description: Both in LO and MSO we can specify a background color for pattern area fill, but it seems PPTX export and also import does not handle the background color. Steps to Reproduce: 1. Open attached ODP file 2. Save it as PPTX 3. Open the save file in LO or MSO Actual Results: Pattern background color is not saved in PPTX files. Expected Results: Pattern background color should be save. MSO supports this feature. Reproducible: Always User Profile Reset: No Additional Info: User-Agent: Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/60.0.3112.90 Safari/537.36
Sorry, I mean hatch background color. In MSO there is only pattern and no hatch, but in LO this is called hatch fill.
Created attachment 135531 [details] Document containing hatch fill with background
Confirmed in Version: 6.0.0.0.alpha0+ Build ID: ef2e6260fad38e26c8591ea88ded348db618270d CPU threads: 4; OS: Linux 4.10; UI render: default; VCL: gtk3; Locale: ca-ES (ca_ES.UTF-8); Calc: group and Version: 4.3.0.0.alpha1+ Build ID: c15927f20d4727c3b8de68497b6949e72f9e6e9e
Let's turn it into a easy hack. The code is here: oox/source/export/drawingml.cxx Check DrawingML::WriteFill(...) method
Tamas, could you provide a bit more detailed code pointers for this easyHack?
(In reply to Shinnok from comment #5) > Tamas, could you provide a bit more detailed code pointers for this easyHack? Of course. The documentation of the fill API properties is here: com/sun/star/drawing/FillProperties.idl Where you see a xPropSet->getPropertyValue( "FillStyle" ) call, this means the code get an API property of the shape. It's also a good idea to check how the Area dialog sets the fill properties for hatch (context menu -> Area -> Hatch tab): cui/source/tabpages/tphatch.cxx You can check what properties are set when a background is specified for a hatch fill (use some debugging for this). This code uses the internal items to set fill properties not the API. The internal items are mapped to API properties here: include/svx/unoshprp.hxx, check the block starting with "#define FILL_PROPERTIES". For example XATTR_FILLHATCH is the ID of the internally used item which defines the hatch type and this is mapped to "FillHatch" API property.
> The documentation of the fill API properties is here: > com/sun/star/drawing/FillProperties.idl offapi/com/sun/star/drawing/FillProperties.idl
PPTX specification: https://msdn.microsoft.com/en-us/library/office/documentformat.openxml.drawing.patternfill.aspx
geri1245 committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=54dfb9ff07a41d9249302ac2ed0a005d0a8114d4 tdf#111785 Save hatch background color in pptx format. It will be available in 6.1.0. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Xisco Fauli committed a patch related to this issue. It has been pushed to "master": https://git.libreoffice.org/core/commit/94df9426f557e49c8241fb2f5351a8d4ee801af6 tdf#111785: sd_export_tests-ooxml2: Add unittest It will be available in 7.3.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.