diff options
author | wout <wout@impinc.co.uk> | 2013-07-01 20:47:33 +0100 |
---|---|---|
committer | wout <wout@impinc.co.uk> | 2013-07-01 20:47:33 +0100 |
commit | 4a6da20fd312d5ea1d3f98f1bcb3b0763a66870a (patch) | |
tree | 5223b6abf4d8da2d4c4811c53e6c2256e702f425 /src/pattern.js | |
parent | b9b4af505a8f6abae7167bdff39d88c484d51aa7 (diff) | |
download | svg.js-4a6da20fd312d5ea1d3f98f1bcb3b0763a66870a.tar.gz svg.js-4a6da20fd312d5ea1d3f98f1bcb3b0763a66870a.zip |
Added SVG.Set adn bumped to v0.24
Diffstat (limited to 'src/pattern.js')
-rw-r--r-- | src/pattern.js | 48 |
1 files changed, 0 insertions, 48 deletions
diff --git a/src/pattern.js b/src/pattern.js deleted file mode 100644 index 4807049..0000000 --- a/src/pattern.js +++ /dev/null @@ -1,48 +0,0 @@ -SVG.Pattern = function(type) { - this.constructor.call(this, SVG.create('pattern')) -} - -// Inherit from SVG.Container -SVG.Pattern.prototype = new SVG.Container - -// -SVG.extend(SVG.Pattern, { - // Return the fill id - fill: function() { - return 'url(#' + this.attr('id') + ')' - } - // Alias string convertion to fill -, toString: function() { - return this.fill() - } - -}) - -// -SVG.extend(SVG.Defs, { - // Define gradient - pattern: function(width, height, block) { - var element = this.put(new SVG.Pattern) - - /* invoke passed block */ - block(element) - - return element.attr({ - x: 0 - , y: 0 - , width: width - , height: height - , patternUnits: 'userSpaceOnUse' - }) - } - -}) - -// -SVG.extend(SVG.Container, { - // Create pattern element in defs - pattern: function(width, height, block) { - return this.defs().pattern(width, height, block) - } - -})
\ No newline at end of file |