Remove polygon offsetting fix which broke some SVG shapes

This commit is contained in:
kangax 2013-02-06 21:04:14 +01:00
parent ed0716718a
commit 776d966bdb
4 changed files with 14 additions and 14 deletions

12
dist/all.js vendored
View file

@ -12270,14 +12270,14 @@ fabric.util.object.extend(fabric.StaticCanvas.prototype, /** @scope fabric.Stati
this.width = (maxX - minX) || 1;
this.height = (maxY - minY) || 1;
var halfWidth = this.width / 2,
halfHeight = this.height / 2;
// var halfWidth = this.width / 2,
// halfHeight = this.height / 2;
// change points to offset polygon into a bounding box
this.points.forEach(function(p) {
p.x -= halfWidth;
p.y -= halfHeight;
}, this);
// this.points.forEach(function(p) {
// p.x -= halfWidth;
// p.y -= halfHeight;
// }, this);
this.minX = minX;
this.minY = minY;

4
dist/all.min.js vendored

File diff suppressed because one or more lines are too long

BIN
dist/all.min.js.gz vendored

Binary file not shown.

View file

@ -56,14 +56,14 @@
this.width = (maxX - minX) || 1;
this.height = (maxY - minY) || 1;
var halfWidth = this.width / 2,
halfHeight = this.height / 2;
// var halfWidth = this.width / 2,
// halfHeight = this.height / 2;
// change points to offset polygon into a bounding box
this.points.forEach(function(p) {
p.x -= halfWidth;
p.y -= halfHeight;
}, this);
// this.points.forEach(function(p) {
// p.x -= halfWidth;
// p.y -= halfHeight;
// }, this);
this.minX = minX;
this.minY = minY;