From 21614c7c3ae46fbfa229755916aec433faba0c95 Mon Sep 17 00:00:00 2001 From: Kaalleen <36401965+kaalleen@users.noreply.github.com> Date: Sun, 14 Mar 2021 09:38:36 +0100 Subject: add lock stitches select box (#1076) Co-authored-by: Lex Neva --- lib/stitch_plan/ties.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'lib/stitch_plan/ties.py') diff --git a/lib/stitch_plan/ties.py b/lib/stitch_plan/ties.py index 5acf16e6..916f9822 100644 --- a/lib/stitch_plan/ties.py +++ b/lib/stitch_plan/ties.py @@ -31,11 +31,14 @@ def add_tie(stitches, tie_path): def add_tie_off(stitches): - add_tie(stitches, stitches[-1:-3:-1]) + # tie_modus: 0 = both | 1 = before | 2 = after | 3 = neither + if stitches[0].tie_modus not in [1, 3]: + add_tie(stitches, stitches[-1:-3:-1]) def add_tie_in(stitches, upcoming_stitches): - add_tie(stitches, upcoming_stitches) + if stitches[0].tie_modus not in [2, 3]: + add_tie(stitches, upcoming_stitches) def add_ties(stitch_plan): -- cgit v1.2.3