diff options
author | Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de> | 2022-06-13 08:53:22 +0200 |
---|---|---|
committer | Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de> | 2022-06-16 15:44:53 +0200 |
commit | c4cf2e82e8d0aaef9b1daedc033d6edf647e5284 (patch) | |
tree | 86baca7fce89d0527d8177a7c4bb9a0e804cfc64 /oox/source/drawingml | |
parent | 3d2e26d8b7a99d0a622741ef4327e8cbc93bbe02 (diff) |
tdf#128150 Add OOXML import/export for "use background fill"
and allow editing this fill property in area dlg
Change-Id: Ic63ba11e9d499d4a0fb22f6739587e3e25140b8f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/134406
Tested-by: Jenkins
Reviewed-by: Samuel Mehrbrodt <samuel.mehrbrodt@allotropia.de>
Diffstat (limited to 'oox/source/drawingml')
-rw-r--r-- | oox/source/drawingml/fillproperties.cxx | 4 | ||||
-rw-r--r-- | oox/source/drawingml/shape.cxx | 3 | ||||
-rw-r--r-- | oox/source/drawingml/shapepropertymap.cxx | 1 |
3 files changed, 6 insertions, 2 deletions
diff --git a/oox/source/drawingml/fillproperties.cxx b/oox/source/drawingml/fillproperties.cxx index 7d6c41a81fc6..93fea51194ef 100644 --- a/oox/source/drawingml/fillproperties.cxx +++ b/oox/source/drawingml/fillproperties.cxx @@ -348,6 +348,7 @@ void FillProperties::assignUsed( const FillProperties& rSourceProps ) { moFillType.assignIfUsed( rSourceProps.moFillType ); maFillColor.assignIfUsed( rSourceProps.maFillColor ); + moUseBgFill.assignIfUsed( rSourceProps.moUseBgFill ); maGradientProps.assignUsed( rSourceProps.maGradientProps ); maPatternProps.assignUsed( rSourceProps.maPatternProps ); maBlipProps.assignUsed( rSourceProps.maBlipProps ); @@ -390,7 +391,10 @@ void FillProperties::pushToPropMap( ShapePropertyMap& rPropMap, switch( moFillType.get() ) { case XML_noFill: + { eFillStyle = FillStyle_NONE; + rPropMap.setProperty(ShapeProperty::FillUseSlideBackground, moUseBgFill.get(false)); + } break; case XML_solidFill: diff --git a/oox/source/drawingml/shape.cxx b/oox/source/drawingml/shape.cxx index 8ef86298fd8b..cff9a5018c6a 100644 --- a/oox/source/drawingml/shape.cxx +++ b/oox/source/drawingml/shape.cxx @@ -191,7 +191,6 @@ Shape::Shape( const ShapePtr& pSourceShape ) , mnZOrderOff(pSourceShape->mnZOrderOff) , mnDataNodeType(pSourceShape->mnDataNodeType) , mfAspectRatio(pSourceShape->mfAspectRatio) -, mbUseBgFill(pSourceShape->mbUseBgFill) , mpDiagramHelper( nullptr ) , msDiagramDataModelID(pSourceShape->msDiagramDataModelID) {} @@ -1197,7 +1196,7 @@ Reference< XShape > const & Shape::createAndInsert( } if( const ShapeStyleRef* pFillRef = getShapeStyleRef( XML_fillRef ) ) { - if (!mbUseBgFill) + if (!getFillProperties().moUseBgFill.get(false)) { nFillPhClr = pFillRef->maPhClr.getColor(rGraphicHelper); nFillPhClrTheme = pFillRef->maPhClr.getSchemeColorIndex(); diff --git a/oox/source/drawingml/shapepropertymap.cxx b/oox/source/drawingml/shapepropertymap.cxx index 59413ba1dc98..57014b4780a6 100644 --- a/oox/source/drawingml/shapepropertymap.cxx +++ b/oox/source/drawingml/shapepropertymap.cxx @@ -47,6 +47,7 @@ const ShapePropertyIds spnDefaultShapeIds = PROP_FillBitmapPositionOffsetX, PROP_FillBitmapPositionOffsetY, PROP_FillBitmapRectanglePoint, PROP_FillHatch, PROP_FillBackground, + PROP_FillUseSlideBackground, PROP_FillBitmapName, PROP_ShadowXDistance, PROP_ShadowSizeX, |