mirror of
https://github.com/gumyr/build123d.git
synced 2025-12-06 02:30:55 -08:00
fix PolarLine with angles that make the length negative
This commit is contained in:
parent
108c1be3f2
commit
29cf8959a5
1 changed files with 2 additions and 2 deletions
|
|
@ -779,9 +779,9 @@ class PolarLine(BaseEdgeObject):
|
|||
if length_mode == LengthMode.DIAGONAL:
|
||||
length_vector = direction_localized * length
|
||||
elif length_mode == LengthMode.HORIZONTAL:
|
||||
length_vector = direction_localized * (length / cos(radians(angle)))
|
||||
length_vector = direction_localized * abs(length / cos(radians(angle)))
|
||||
elif length_mode == LengthMode.VERTICAL:
|
||||
length_vector = direction_localized * (length / sin(radians(angle)))
|
||||
length_vector = direction_localized * abs(length / sin(radians(angle)))
|
||||
|
||||
new_edge = Edge.make_line(start, start + length_vector)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue