diff options
author | Tibor Nagy <nagy.tibor2@nisz.hu> | 2023-08-27 18:39:17 +0200 |
---|---|---|
committer | Xisco Fauli <xiscofauli@libreoffice.org> | 2023-09-01 13:32:39 +0200 |
commit | d13505b8ef7459d97e9f90ee099ca54354d99922 (patch) | |
tree | d43999d749aff279b08a55984e2187e12df32911 /oox | |
parent | b04120235e25854734d5608902eeffd563e2c28f (diff) |
tdf#156829 PPTX import: fix connector regression at missing glue points
Glue points weren't imported if the custom shape type is
"non-primitive", resulting broken line connectors, moreover
broken graphic design, as attached to the original bug report.
~Regression from commit cbf66ec3e60d07efb7c3cceed9b4f0fb4f0510c8
"tdf#89449 PPTX import: fix line connectors".
Change-Id: I9908a23f8e6997bc1384aaeb3e8ba43c08d20d42
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156171
Tested-by: László Németh <nemeth@numbertext.org>
Reviewed-by: László Németh <nemeth@numbertext.org>
(cherry picked from commit a126f499bd4bef203f26b251d85ee30ce5dc4f91)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156222
Tested-by: Jenkins
Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
Diffstat (limited to 'oox')
-rw-r--r-- | oox/source/drawingml/customshapeproperties.cxx | 16 | ||||
-rw-r--r-- | oox/source/token/properties.txt | 1 |
2 files changed, 17 insertions, 0 deletions
diff --git a/oox/source/drawingml/customshapeproperties.cxx b/oox/source/drawingml/customshapeproperties.cxx index 9cdbb4ee8801..3483969f716d 100644 --- a/oox/source/drawingml/customshapeproperties.cxx +++ b/oox/source/drawingml/customshapeproperties.cxx @@ -228,6 +228,22 @@ void CustomShapeProperties::pushToPropSet( aPath.setProperty( PROP_TextFrames, aTextFrames); } + if (!maConnectionSiteList.empty()) + { + css::uno::Sequence<EnhancedCustomShapeParameterPair> seqGluePoints; + seqGluePoints.realloc(maConnectionSiteList.size()); + sal_Int32 nId = 0; + for (auto& rGluePoint : asNonConstRange(seqGluePoints)) + { + rGluePoint.First.Value = maConnectionSiteList[nId].pos.First.Value; + rGluePoint.First.Type = maConnectionSiteList[nId].pos.First.Type; + rGluePoint.Second.Value = maConnectionSiteList[nId].pos.Second.Value; + rGluePoint.Second.Type = maConnectionSiteList[nId].pos.Second.Type; + nId++; + } + aPath.setProperty(PROP_GluePoints, seqGluePoints); + } + sal_uInt32 nParameterPairs = 0; for ( auto const & i: maPath2DList ) nParameterPairs += i.parameter.size(); diff --git a/oox/source/token/properties.txt b/oox/source/token/properties.txt index a6de5458b663..b5a3478f45b0 100644 --- a/oox/source/token/properties.txt +++ b/oox/source/token/properties.txt @@ -224,6 +224,7 @@ GenerateVbaEvents Geometry3D GlowEffect GlowEffectRadius +GluePoints GradientName HatchName Graphic |