Keep empty clip mask in SVG export

A path should be exported in SVG if it serves as a clip mask, otherwise all items in the clip group that were hidden by clipping in paper.js become visible in the SVG.
This commit is contained in:
Jan 2016-02-15 15:29:19 +01:00
parent 3d330da4fc
commit b5b1aa57d7

View file

@ -110,7 +110,7 @@ new function() {
var segments = item._segments,
type,
attrs = getTransform(item._matrix);
if (segments.length === 0)
if (segments.length === 0 && !item.isClipMask())
return null;
if (matchShapes && !item.hasHandles()) {
if (segments.length >= 3) {