mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-03 19:45:44 -05:00
Fix Path#getStrokeBounds: use Path#getBounds when no strokeColor or strokeWidth are set.
This commit is contained in:
parent
0ab9e38068
commit
b4807b9b7c
1 changed files with 2 additions and 0 deletions
|
@ -1101,6 +1101,8 @@ var Path = this.Path = PathItem.extend({
|
|||
* The bounding rectangle of the item including stroke width.
|
||||
*/
|
||||
getStrokeBounds: function(/* matrix */) {
|
||||
if (!this.style._strokeColor || !this.style._strokeWidth)
|
||||
return this.getBounds();
|
||||
var useCache = arguments.length == 0;
|
||||
if (this._strokeBounds && useCache)
|
||||
return this._strokeBounds;
|
||||
|
|
Loading…
Reference in a new issue