diff --git a/src/item/Group.js b/src/item/Group.js index 9df3b6f7..5feb83b5 100644 --- a/src/item/Group.js +++ b/src/item/Group.js @@ -169,7 +169,7 @@ var Group = this.Group = Item.extend(/** @lends Group# */{ if (clipItem) { param.clip = true; Item.draw(clipItem, ctx, param); - delete param.clip; + param.clip = false; } for (var i = 0, l = this._children.length; i < l; i++) { var item = this._children[i]; diff --git a/src/path/CompoundPath.js b/src/path/CompoundPath.js index 04555f7b..90c4ea9b 100644 --- a/src/path/CompoundPath.js +++ b/src/path/CompoundPath.js @@ -197,7 +197,7 @@ var CompoundPath = this.CompoundPath = PathItem.extend(/** @lends CompoundPath# var children = this._children, style = this._style; // Return early if the compound path doesn't have any children: - if (children.length == 0) + if (children.length === 0) return; ctx.beginPath(); param.compound = true; diff --git a/src/project/Project.js b/src/project/Project.js index 1444236e..ebe8b4e2 100644 --- a/src/project/Project.js +++ b/src/project/Project.js @@ -296,6 +296,8 @@ var Project = this.Project = PaperScopeItem.extend(/** @lends Project# */{ matrix.applyToContext(ctx); var param = { offset: new Point(0, 0), + // A stack of concatenated matrices, to keep track of the current + // global matrix, since Canvas is not able tell us (yet). transforms: [matrix] }; for (var i = 0, l = this.layers.length; i < l; i++)