From a0bc013bb8fd52213b7adf3d905042356fadc11d Mon Sep 17 00:00:00 2001 From: Kaalleen <36401965+kaalleen@users.noreply.github.com> Date: Tue, 9 Jul 2024 17:37:44 +0200 Subject: params: first fill then stroke (#3065) --- lib/extensions/params.py | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) mode change 100644 => 100755 lib/extensions/params.py (limited to 'lib/extensions') diff --git a/lib/extensions/params.py b/lib/extensions/params.py old mode 100644 new mode 100755 index b4efdc1b..8d5a86ec --- a/lib/extensions/params.py +++ b/lib/extensions/params.py @@ -545,8 +545,11 @@ class SettingsPanel(wx.Panel): def render_stitch_plan(self): stitch_groups = [] nodes = [] - - for tab in self.tabs: + # move the stroke tab to the end of the list + tabs = self.tabs + stroke_index = [tabs.index(tab) for tab in tabs if tab.name == _("Stroke")][0] + tabs.append(tabs.pop(stroke_index)) + for tab in tabs: tab.apply() if tab.enabled() and not tab.is_dependent_tab(): nodes.extend(tab.nodes) @@ -558,12 +561,15 @@ class SettingsPanel(wx.Panel): try: wx.CallAfter(self._hide_warning) + last_stitch_group = None for node in nodes: # Making a copy of the embroidery element is an easy # way to drop the cache in the @cache decorators used # for many params in embroider.py. - stitch_groups.extend(copy(node).embroider(None)) + stitch_groups.extend(copy(node).embroider(last_stitch_group)) + if stitch_groups: + last_stitch_group = stitch_groups[-1] check_stop_flag() -- cgit v1.2.3