summaryrefslogtreecommitdiff
path: root/lib/stitches
diff options
context:
space:
mode:
authorKaalleen <36401965+kaalleen@users.noreply.github.com>2025-08-27 18:00:45 +0200
committerGitHub <noreply@github.com>2025-08-27 18:00:45 +0200
commit2a49dadfa32c23d3d5b3359b064118bd18be1030 (patch)
tree5139e9f6b496675c20cabd5ec1356f0c5bc86b3f /lib/stitches
parentbf29b6c7bdffb86bf0265a143a0196bf2a8e5980 (diff)
fill: tag last stitch in a row correctly (#3940)
Diffstat (limited to 'lib/stitches')
-rw-r--r--lib/stitches/fill.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/stitches/fill.py b/lib/stitches/fill.py
index e05ee8c1..ad082b2d 100644
--- a/lib/stitches/fill.py
+++ b/lib/stitches/fill.py
@@ -59,7 +59,7 @@ def stitch_row(stitches, beg, end, angle, row_spacing, max_stitch_length, stagge
return
beg = Stitch(*beg, tags=('fill_row_start',))
- end = Stitch(*end, tags=('fill_row_start',))
+ end = Stitch(*end, tags=('fill_row_end',))
stitches.append(beg)
if enable_random_stitch_length:
@@ -104,6 +104,8 @@ def stitch_row(stitches, beg, end, angle, row_spacing, max_stitch_length, stagge
if (end - stitches[-1]).length() > 0.1 * PIXELS_PER_MM and not skip_last:
stitches.append(end)
+ else:
+ stitches[-1].add_tag('fill_row_end')
def intersect_region_with_grating(shape, angle, row_spacing, end_row_spacing=None, flip=False):