mirror of
https://github.com/exyte/Macaw.git
synced 2024-09-21 18:09:21 +03:00
Layer size fixed with stroke width
This commit is contained in:
parent
122856b31d
commit
56b4bbcaee
@ -67,6 +67,15 @@ public class Shape: Node {
|
||||
bounds = form.bounds()
|
||||
}
|
||||
|
||||
if let shapeStroke = self.stroke {
|
||||
let r = shapeStroke.width / 2.0
|
||||
bounds = Rect(
|
||||
x: bounds.x - r,
|
||||
y: bounds.y - r,
|
||||
w: bounds.w + r * 2.0,
|
||||
h: bounds.h + r * 2.0)
|
||||
}
|
||||
|
||||
return bounds
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user