summaryrefslogtreecommitdiff
path: root/lib/stitch_plan
diff options
context:
space:
mode:
authorLex Neva <lexelby@users.noreply.github.com>2019-07-27 15:48:50 -0400
committerGitHub <noreply@github.com>2019-07-27 15:48:50 -0400
commit833a8a971d8a73fbc42468a89d083e37a0bd6d8d (patch)
tree4c38fd49d7cf813a2df1d07dbd32160d0e36373f /lib/stitch_plan
parent03af8b37276870efd97f7049ced006f6e01ef935 (diff)
parent7ce4387ff6f8d4302ff374921d0b93b7b491b9a5 (diff)
Merge pull request #487 from inkstitch/no_import_jumps
remove additional jump stitches on import
Diffstat (limited to 'lib/stitch_plan')
-rw-r--r--lib/stitch_plan/stitch_plan.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/stitch_plan/stitch_plan.py b/lib/stitch_plan/stitch_plan.py
index 8e84db4d..b621ef07 100644
--- a/lib/stitch_plan/stitch_plan.py
+++ b/lib/stitch_plan/stitch_plan.py
@@ -70,6 +70,14 @@ class StitchPlan(object):
self.color_blocks.append(color_block)
return color_block
+ def delete_empty_color_blocks(self):
+ color_blocks = []
+ for color_block in self.color_blocks:
+ if len(color_block) > 0:
+ color_blocks.append(color_block)
+
+ self.color_blocks = color_blocks
+
def add_color_block(self, color_block):
self.color_blocks.append(color_block)