Commit 8f14c2c2 authored by Alexander.Trofimov's avatar Alexander.Trofimov

add RemoveClipRect and AddClipRect to match with pdf printer

parent e3ea6a80
......@@ -635,6 +635,14 @@
return this;
};
DrawingContext.prototype.AddClipRect = function (x, y, w, h) {
return this.save().beginPath().rect(x, y, w, h).clip();
};
DrawingContext.prototype.RemoveClipRect = function () {
return this.restore();
};
DrawingContext.prototype.save = function () {
this.ctx.save();
return this;
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment