diff options
| author | Kaalleen <36401965+kaalleen@users.noreply.github.com> | 2020-03-19 17:37:47 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2020-03-19 17:37:47 +0100 |
| commit | 6a012b64ee9a4592827aab3f0d8d8596b7e1824c (patch) | |
| tree | f3bbe2f733f67d125611dbebe0f079e6ebd45c43 /lib/elements/element.py | |
| parent | 88a38cce98dfa21af662209dc5a5a6eabf97b985 (diff) | |
add ties checkbox (#619)
Diffstat (limited to 'lib/elements/element.py')
| -rw-r--r-- | lib/elements/element.py | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/lib/elements/element.py b/lib/elements/element.py index dd6c9063..04f15b6e 100644 --- a/lib/elements/element.py +++ b/lib/elements/element.py @@ -1,9 +1,9 @@ -from copy import deepcopy import sys +from copy import deepcopy -from cspsubdiv import cspsubdiv import cubicsuperpath import simplestyle +from cspsubdiv import cspsubdiv from ..commands import find_commands from ..i18n import _ @@ -169,6 +169,17 @@ class EmbroideryElement(object): return width * self.stroke_scale @property + @param('ties', + _('Ties'), + tooltip=_('Add ties. Manual stitch will not add ties.'), + type='boolean', + default=True, + sort_index=4) + @cache + def ties(self): + return self.get_boolean_param("ties", True) + + @property def path(self): # A CSP is a "cubic superpath". # @@ -269,6 +280,10 @@ class EmbroideryElement(object): patches = self.to_patches(last_patch) + if not self.ties: + for patch in patches: + patch.stitch_as_is = True + if patches: patches[-1].trim_after = self.has_command("trim") or self.trim_after patches[-1].stop_after = self.has_command("stop") or self.stop_after |
