From a20c0b1430fb97ff203a9afd6ba6945cf18e58d1 Mon Sep 17 00:00:00 2001 From: wout Date: Fri, 28 Dec 2012 23:20:22 +0100 Subject: Added skew method to the sugar module --- src/sugar.js | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/sugar.js') diff --git a/src/sugar.js b/src/sugar.js index bd8454d..10a8716 100644 --- a/src/sugar.js +++ b/src/sugar.js @@ -41,6 +41,14 @@ SVG.extend(SVG.Element, { cx: x == null ? b.cx : x, cy: y == null ? b.cx : y }); + }, + + // skew + skew: function(x, y) { + return this.transform({ + skewX: x || 0, + skewY: y || 0 + }); } }); -- cgit v1.2.3