Apache OpenOffice (AOO) Bugzilla – Issue 121371
shape is lost on import of pptx
Last modified: 2022-10-28 12:54:36 UTC
Created attachment 79927 [details] File with two rectangles and a straight connector between them Open attached document. It contains two rectangles with a straight connector line between them. When you open it, the rectangles are missing. If you use the Navigator, you see, that the rectangles are still there, but you cannot see them. If you save the file to odp-format and unzip it, you can see, that the path of the objects is missing. If you open the file in AOO3.4.1 the shapes are there. [The connector is imported as simple line, but that is another issue.]
The import is OK in version r1389055 and fails in version r1391405. I work on WinXP.
ALG: Looks as if the render command in SdrObjCustomShape::GetSdrObjectFromCustomShape() is not able to produce geometry, needs to be checked.
Created attachment 79964 [details] Proposed solution ALG: Reason is that the 'Type' setting at the CustomShapeGeometryItem is overwritten in CustomShapeProperties::pushToPropSet when maShapePresetType.getLength() is true. This happens due to creating a completely new PropertySet and setting this as CustomShapeGeometry at the xShape, but without copying the 'type' which was already set from the XEnhancedCustomShapeDefaulter. Attached is a proposed patch which sets the properties at the existing CustomShapeGeometry PropertySet. I think this is correct, but may someone take a look, please?
"alg" committed SVN revision 1415118 into trunk: #121371# Do set values as planned, but do not override complete CustomShapeGe...
ALG: Okay, found a safer solution; now values to be set are added to the sequence of properties and that seq gets set when values were added and not only changed. Kept the other value changers untouched, only adapted those who were set hard (and overwriting) before.