Skip to content

Commit

Permalink
fix itext width calculation with caching false (#2943)
Browse files Browse the repository at this point in the history
  • Loading branch information
asturur committed May 5, 2016
1 parent 0410aae commit e5bedf3
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/shapes/itext.class.js
Original file line number Diff line number Diff line change
Expand Up @@ -843,6 +843,7 @@
if (!this.caching || !this._charWidthsCache[cacheProp]) {
width = ctx.measureText(_char).width;
this.caching && (this._charWidthsCache[cacheProp] = width);
return width;
}

return this._charWidthsCache[cacheProp];
Expand Down

0 comments on commit e5bedf3

Please sign in to comment.