mirror of
https://github.com/Hopiu/fabric.js.git
synced 2026-04-19 21:50:58 +00:00
Update path.class.js
This commit is contained in:
parent
5346e1fd32
commit
cf3bd70479
1 changed files with 4 additions and 2 deletions
|
|
@ -101,8 +101,10 @@
|
|||
this.minY = calcDim.top;
|
||||
this.width = calcDim.width;
|
||||
this.height = calcDim.height;
|
||||
this.top = this.top || this.minY;
|
||||
this.left = this.left || this.minX;
|
||||
calcDim.left += this.originX === 'center' ? this.width / 2 : this.originX === 'right' ? this.width : 0;
|
||||
calcDim.top += this.originY === 'center' ? this.height / 2 : this.originY === 'bottom' ? this.height : 0;
|
||||
this.top = this.top || calcDim.top;
|
||||
this.left = this.left || calcDim.left;
|
||||
this.pathOffset = this.pathOffset || {
|
||||
x: this.minX + this.width / 2,
|
||||
y: this.minY + this.height / 2
|
||||
|
|
|
|||
Loading…
Reference in a new issue