diff options
author | wout <wout@impinc.co.uk> | 2013-03-12 13:31:09 +0100 |
---|---|---|
committer | wout <wout@impinc.co.uk> | 2013-03-12 13:31:09 +0100 |
commit | 4bd21ec64a0e3c1d4d0acf5685b2230285c7c16b (patch) | |
tree | 0300a47ca1b263ae0cd0fdb5fe76218ceb9aa745 /src/default.js | |
parent | 6c6c82ed59533f44f8754b69d47e3b11cd6dd129 (diff) | |
download | svg.js-4bd21ec64a0e3c1d4d0acf5685b2230285c7c16b.tar.gz svg.js-4bd21ec64a0e3c1d4d0acf5685b2230285c7c16b.zip |
Added x(), y(), cx(), cy() and matrix
Diffstat (limited to 'src/default.js')
-rw-r--r-- | src/default.js | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/src/default.js b/src/default.js new file mode 100644 index 0000000..abcac88 --- /dev/null +++ b/src/default.js @@ -0,0 +1,56 @@ + +SVG.default = { + // Default matrix + matrix: '1,0,0,1,0,0' + + // Default attribute values +, attrs: function() { + return { + /* fill and stroke */ + 'fill-opacity': 1 + , 'stroke-opacity': 1 + , 'stroke-width': 0 + , fill: '#000' + , stroke: '#000' + , opacity: 1 + /* position */ + , x: 0 + , y: 0 + , cx: 0 + , cy: 0 + /* size */ + , width: 0 + , height: 0 + /* radius */ + , r: 0 + , rx: 0 + , ry: 0 + } + } + + // Default transformation values +, trans: function() { + return { + /* translate */ + x: 0 + , y: 0 + /* scale */ + , scaleX: 1 + , scaleY: 1 + /* rotate */ + , rotation: 0 + /* skew */ + , skewX: 0 + , skewY: 0 + /* matrix */ + , matrix: this.matrix + , a: 1 + , b: 0 + , c: 0 + , d: 1 + , e: 0 + , f: 0 + } + } + +}
\ No newline at end of file |