summaryrefslogtreecommitdiffstats
path: root/src/group.js
diff options
context:
space:
mode:
authorwout <wout@impinc.co.uk>2013-06-09 11:37:26 +0100
committerwout <wout@impinc.co.uk>2013-06-09 11:37:26 +0100
commit8f03d84e43681ecca20ac028071e51a2e2bbc0c8 (patch)
treef5c11dc6c429e8459c20731ba775fa6ca794400f /src/group.js
parentec75128ec31aa055aca2ae7f95ad4f5cf38d12e0 (diff)
downloadsvg.js-8f03d84e43681ecca20ac028071e51a2e2bbc0c8.tar.gz
svg.js-8f03d84e43681ecca20ac028071e51a2e2bbc0c8.zip
Added deep traversing, reorganizd modules
Diffstat (limited to 'src/group.js')
-rw-r--r--src/group.js10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/group.js b/src/group.js
index f960391..1184657 100644
--- a/src/group.js
+++ b/src/group.js
@@ -5,6 +5,7 @@ SVG.G = function() {
// Inherit from SVG.Container
SVG.G.prototype = new SVG.Container
+//
SVG.extend(SVG.G, {
// Move over x-axis
x: function(x) {
@@ -19,4 +20,13 @@ SVG.extend(SVG.G, {
return this.doc().defs()
}
+})
+
+//
+SVG.extend(SVG.Container, {
+ // Create a group element
+ group: function() {
+ return this.put(new SVG.G)
+ }
+
}) \ No newline at end of file