aboutsummaryrefslogtreecommitdiffstats
path: root/src/group.js
diff options
context:
space:
mode:
authorwout <wout@impinc.co.uk>2014-07-19 08:38:59 +0200
committerwout <wout@impinc.co.uk>2014-07-19 08:38:59 +0200
commit4b4e45cc5f2f3d28e100be523ec053a4a53c965f (patch)
tree46b26973e2ebf0ed5e753b506a3ad5364725b6ef /src/group.js
parentf8a9faa0296d11b6557bd03183055382819e35be (diff)
downloadsvg.js-4b4e45cc5f2f3d28e100be523ec053a4a53c965f.tar.gz
svg.js-4b4e45cc5f2f3d28e100be523ec053a4a53c965f.zip
Fixes a but in absolute positioning of groups
Diffstat (limited to 'src/group.js')
-rwxr-xr-xsrc/group.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/group.js b/src/group.js
index 1808b3f..326f50b 100755
--- a/src/group.js
+++ b/src/group.js
@@ -9,11 +9,11 @@ SVG.G = SVG.invent({
, extend: {
// Move over x-axis
x: function(x) {
- return x == null ? this.transform('x') : this.transform({ x: x })
+ return x == null ? this.transform('x') : this.transform({ x: -this.x() + x })
}
// Move over y-axis
, y: function(y) {
- return y == null ? this.transform('y') : this.transform({ y: y })
+ return y == null ? this.transform('y') : this.transform({ y: -this.y() + y })
}
// Move by center over x-axis
, cx: function(x) {