aboutsummaryrefslogtreecommitdiffstats
path: root/src/circle.js
diff options
context:
space:
mode:
authorwout <wout@impinc.co.uk>2012-12-29 15:20:50 +0100
committerwout <wout@impinc.co.uk>2012-12-29 15:20:50 +0100
commit331068a979be8b735e92f074ce0d2438f5f2127b (patch)
tree25983c08fc3c28ab7bdf5c394a4800b3b095d092 /src/circle.js
parenta20c0b1430fb97ff203a9afd6ba6945cf18e58d1 (diff)
downloadsvg.js-331068a979be8b735e92f074ce0d2438f5f2127b.tar.gz
svg.js-331068a979be8b735e92f074ce0d2438f5f2127b.zip
Added polyline and polygon, removed cicle
Diffstat (limited to 'src/circle.js')
-rw-r--r--src/circle.js35
1 files changed, 0 insertions, 35 deletions
diff --git a/src/circle.js b/src/circle.js
deleted file mode 100644
index 059813e..0000000
--- a/src/circle.js
+++ /dev/null
@@ -1,35 +0,0 @@
-
-SVG.Circle = function Circle() {
- this.constructor.call(this, SVG.create('circle'));
-};
-
-// inherit from SVG.Shape
-SVG.Circle.prototype = new SVG.Shape();
-
-// Add circle-specific functions
-SVG.extend(SVG.Circle, {
-
- // custom move function
- move: function(x, y) {
- this.attrs.x = x;
- this.attrs.y = y;
-
- return this.center();
- },
-
- // custom size function (no height value here!)
- size: function(w) {
- return this.attr('r', w / 2).center();
- },
-
- // position element by its center
- center: function(x, y) {
- var r = this.attrs.r || 0;
-
- return this.attr({
- cx: x || (this.attrs.x || 0) + r,
- cy: y || (this.attrs.y || 0) + r
- });
- }
-
-}); \ No newline at end of file