aboutsummaryrefslogtreecommitdiffstats
path: root/src/symbol.js
diff options
context:
space:
mode:
authorwout <wout@impinc.co.uk>2014-06-17 20:17:01 +0200
committerwout <wout@impinc.co.uk>2014-06-17 20:17:01 +0200
commit1c50b34aba8fe613f4002cc84b41411c0f546308 (patch)
treec4ea746d29e650605eec74c17abca0127f37876f /src/symbol.js
parentadad1d062678522e684bfe5216f63a3f400bd3c9 (diff)
downloadsvg.js-1c50b34aba8fe613f4002cc84b41411c0f546308.tar.gz
svg.js-1c50b34aba8fe613f4002cc84b41411c0f546308.zip
Added marker, symbol and dynamic referencing
Diffstat (limited to 'src/symbol.js')
-rw-r--r--src/symbol.js17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/symbol.js b/src/symbol.js
new file mode 100644
index 0000000..e8907a3
--- /dev/null
+++ b/src/symbol.js
@@ -0,0 +1,17 @@
+
+SVG.Symbol = SVG.invent({
+ // Initialize node
+ create: 'symbol'
+
+ // Inherit from
+, inherit: SVG.Container
+
+ // Add parent method
+, construct: {
+ // Create a new symbol
+ symbol: function() {
+ return this.defs().put(new SVG.Symbol)
+ }
+ }
+
+}) \ No newline at end of file