summaryrefslogtreecommitdiff
path: root/oox
diff options
context:
space:
mode:
Diffstat (limited to 'oox')
-rw-r--r--oox/README4
-rw-r--r--oox/source/export/shapes.cxx16
2 files changed, 10 insertions, 10 deletions
diff --git a/oox/README b/oox/README
index 7f127b617981..6c459f58c92a 100644
--- a/oox/README
+++ b/oox/README
@@ -157,7 +157,7 @@ http://www.microsoft.com/en-us/download/details.aspx?id=30425
== Export ==
Here is how LO's enhanced custom shapes are exported:
* Shape name is ooxml-* - they are imported from ooxml, export as is.
-* Blacklist - ODF presets that has OOXML equivalent.
+* Denylist - ODF presets that has OOXML equivalent.
We convert adjustment values case by case. Microsoft Office
is rather strict about adjustment values, either none of them
are provided so that default values are taken, or the exact set
@@ -165,7 +165,7 @@ Here is how LO's enhanced custom shapes are exported:
from the preset with less handles to the one with more handles
so that default values suitable for the odf one need to be
provided.
-* Whitelist - ODF presets that has OOXML equivalent but looks a bit
+* Allowlist - ODF presets that has OOXML equivalent but looks a bit
different, export them as PolyPolygon.
Check Andras Timar's presentation[1] and ShapeExport::WriteCustomShape()
diff --git a/oox/source/export/shapes.cxx b/oox/source/export/shapes.cxx
index c1982961537b..09c5bc386eac 100644
--- a/oox/source/export/shapes.cxx
+++ b/oox/source/export/shapes.cxx
@@ -518,9 +518,9 @@ ShapeExport& ShapeExport::WriteGroupShape(const uno::Reference<drawing::XShape>&
return *this;
}
-static bool lcl_IsOnBlacklist(OUString const & rShapeType)
+static bool lcl_IsOnDenylist(OUString const & rShapeType)
{
- static const std::initializer_list<OUStringLiteral> vBlacklist = {
+ static const std::initializer_list<OUStringLiteral> vDenylist = {
"block-arc",
"rectangle",
"ellipse",
@@ -582,7 +582,7 @@ static bool lcl_IsOnBlacklist(OUString const & rShapeType)
"flowchart-display"
};
- return std::find(vBlacklist.begin(), vBlacklist.end(), rShapeType) != vBlacklist.end();
+ return std::find(vDenylist.begin(), vDenylist.end(), rShapeType) != vDenylist.end();
}
static bool lcl_IsOnWhitelist(OUString const & rShapeType)
@@ -812,20 +812,20 @@ ShapeExport& ShapeExport::WriteCustomShape( const Reference< XShape >& xShape )
// we export non-primitive shapes to custom geometry
// we also export non-ooxml shapes which have handles/equations to custom geometry, because
// we cannot convert ODF equations to DrawingML equations. TODO: see what binary DOC export filter does.
- // but our WritePolyPolygon()/WriteCustomGeometry() functions are incomplete, therefore we use a blacklist
+ // but our WritePolyPolygon()/WriteCustomGeometry() functions are incomplete, therefore we use a denylist
// we use a whitelist for shapes where mapping to MSO preset shape is not optimal
bool bCustGeom = true;
- bool bOnBlacklist = false;
+ bool bOnDenylist = false;
if( sShapeType == "ooxml-non-primitive" )
bCustGeom = true;
else if( sShapeType.startsWith("ooxml") )
bCustGeom = false;
else if( lcl_IsOnWhitelist(sShapeType) )
bCustGeom = true;
- else if( lcl_IsOnBlacklist(sShapeType) )
+ else if( lcl_IsOnDenylist(sShapeType) )
{
bCustGeom = false;
- bOnBlacklist = true;
+ bOnDenylist = true;
}
else if( bHasHandles )
bCustGeom = true;
@@ -853,7 +853,7 @@ ShapeExport& ShapeExport::WriteCustomShape( const Reference< XShape >& xShape )
if (!bSuccess)
WritePresetShape( sPresetShape );
}
- else if (bOnBlacklist && bHasHandles && nAdjustmentValuesIndex !=-1 && !sShapeType.startsWith("mso-spt"))
+ else if (bOnDenylist && bHasHandles && nAdjustmentValuesIndex !=-1 && !sShapeType.startsWith("mso-spt"))
{
WriteShapeTransformation( xShape, XML_a, bFlipH, bFlipV );
Sequence< EnhancedCustomShapeAdjustmentValue > aAdjustmentSeq;