[Path] simplify conditional
This commit is contained in:
parent
564ff10db3
commit
a467a0baca
1 changed files with 1 additions and 3 deletions
|
|
@ -486,9 +486,7 @@ class Path(Shape):
|
|||
return self
|
||||
|
||||
def _calculate_cap_extensions(self) -> NDArray[numpy.float64]:
|
||||
if self.cap == PathCap.Square:
|
||||
extensions = numpy.full(2, self.width / 2)
|
||||
elif self.cap == PathCap.Circle:
|
||||
if self.cap in (PathCap.Square, PathCap.Circle):
|
||||
extensions = numpy.full(2, self.width / 2)
|
||||
elif self.cap == PathCap.SquareCustom:
|
||||
assert isinstance(self.cap_extensions, numpy.ndarray)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue