Start a text document and insert a shape 'Puzzle'. Save it as DOCX and reopen the saved file. The shape has become a rectangle. The error is in ShapeExport::WriteCustomShape(). The condition for using DMLPresetShapeExporter is wrong. At that time it is already known, that the shape needs to be exported as custGeom. But DMLPresetShapeExporter is used anyway. And there msfilter::util::GetOOXMLPresetGeometry("puzzle") is called. That method has no result "fail" but returns type "rect" in case the shape type does not exist. Besides the wrong condition, I think it should be considered to let GetOOXMLPresetGeometry return an empty string in case no preset is found, so that the caller can detect this case and react appropriate.
Already REPRODUCIBLE with Installation of Version: 7.3.0.3 (x64) Build ID a69ca51ded25f3eefd52d7bf9a5fad8c90b87951 CPU threads: 12; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL: win | Locale: de-DE (de_DE); UI: de-DE | Calc: threaded | ElementaryTheme | My normal User Profile Was still ok with Portable Version of 6.4.7.2 (x86) Build-ID 639b8ac485750d5696d7590a72ef1b496725cfb5; CPU-Threads: 12; BS: Windows 10.0; UI-Render: GL; Gebietsschema: de-DE (de_DE); Calc: CL, Special devUserProfile a) Calc not affected, save/reopen xlsx does not destroy puzzle shape b) no obvious DUO found iwth query https://bugs.documentfoundation.org/buglist.cgi?cmdtype=dorem&remaction=run&namedcmd=DUPs148342&sharer_id=19321
Regression introduced by: https://cgit.freedesktop.org/libreoffice/core/commit/?id=63cd67e5e18f01aca303131e148c80398a181a41 author Attila Bakos (NISZ) <bakos.attilakaroly@nisz.hu> 2021-05-14 13:53:32 +0200 committer László Németh <nemeth@numbertext.org> 2021-06-23 12:57:40 +0200 commit 63cd67e5e18f01aca303131e148c80398a181a41 (patch) tree f096ec2a12b32517fa031019aa57e7acf2914998 parent ae31c8503c568171cadc87a0b3de0ca23619afdd (diff) tdf#92525 tdf#142398: fix export of simple custom shapes Bisected with: bibisect-linux64-7.3 Adding Cc: to Attila Bakos
Fixed with commit https://cgit.freedesktop.org/libreoffice/core/commit/?id=9592da0a8e596869a1cd0859619dd28a541d7234 Because of wrong number in subject line the commit notification was sent to bug 148327.
Attila Bakos (NISZ) committed a patch related to this issue. It has been pushed to "libreoffice-7-3": https://git.libreoffice.org/core/commit/e342185c4650ca2678ccbea92770e1ae147d08bc tdf#148342 docx export: fix puzzle shape It will be available in 7.3.3. 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.