[Polygon] rect() should call rectangle() with positive width/height

no big deal, but this makes vertex order consistent
This commit is contained in:
jan 2026-03-08 22:42:48 -07:00
commit fb822829ec

View file

@ -321,7 +321,7 @@ class Polygon(Shape):
else: else:
raise PatternError('Two of ymin, yctr, ymax, ly must be None!') raise PatternError('Two of ymin, yctr, ymax, ly must be None!')
poly = Polygon.rectangle(lx, ly, offset=(xctr, yctr), repetition=repetition) poly = Polygon.rectangle(abs(lx), abs(ly), offset=(xctr, yctr), repetition=repetition)
return poly return poly
@staticmethod @staticmethod