From 529656c2878eaae96e61027ab8ece74e4aca0d2e Mon Sep 17 00:00:00 2001 From: Grant Skinner Date: Fri, 22 Jan 2021 11:15:17 -0700 Subject: [PATCH] Add warning for non-center strokes on shapes Issue #90 --- src/core/nodes/shape.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/core/nodes/shape.js b/src/core/nodes/shape.js index 6231b5a..66d88b4 100644 --- a/src/core/nodes/shape.js +++ b/src/core/nodes/shape.js @@ -168,6 +168,11 @@ function _serializeSvgNode(xdNode, ctx) { if (hasImageFill) { ctx.log.warn('Image fills are not supported on shapes.', o); } + if (o.strokePosition !== xd.GraphicNode.CENTER_STROKE) { + ctx.log.warn('Only center strokes are supported on shapes.', o); + } + + let imagePath = hasImageFill ? getImagePath(o) : ""; let imageWidth = $.fix(hasImageFill ? o.fill.naturalWidth : 0); let imageHeight = $.fix(hasImageFill ? o.fill.naturalHeight : 0);