aboutsummaryrefslogtreecommitdiffstats
path: root/src/group.js
blob: 2236c09b9e13dd56d26bd0bd2c14e273002c9239 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
SVG.Group = function Group() {
  this.constructor.call(this, SVG.create('g'));
};

// inherit from SVG.Element
SVG.Group.prototype = new SVG.Element();

// include the container object
SVG.Utils.merge(SVG.Group, SVG.Container);

// Add group-specific functions
SVG.Utils.merge(SVG.Group, {
  
  // group rotation
  rotate: function(d) {
    this.attr('transform', 'rotate(' + d + ')');
    return this;
  }
  
});