summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/extensions/convert_to_satin.py6
-rw-r--r--messages.po8
2 files changed, 10 insertions, 4 deletions
diff --git a/lib/extensions/convert_to_satin.py b/lib/extensions/convert_to_satin.py
index 53930935..8ec6ab2e 100644
--- a/lib/extensions/convert_to_satin.py
+++ b/lib/extensions/convert_to_satin.py
@@ -5,6 +5,7 @@ import numpy
from numpy import diff, sign, setdiff1d
from scipy.signal import argrelmin
import math
+from copy import deepcopy
from .base import InkstitchExtension
from ..svg.tags import SVG_PATH_TAG
@@ -40,6 +41,11 @@ class ConvertToSatin(InkstitchExtension):
except ValueError:
inkex.errormsg(_("Cannot convert %s to a satin column because it intersects itself. Try breaking it up into multiple paths.") % element.node.get('id'))
+ # revert any changes we've made
+ self.document = deepcopy(self.original_document)
+
+ return
+
parent.insert(index, self.satin_to_svg_node(rails, rungs, correction_transform))
parent.remove(element.node)
diff --git a/messages.po b/messages.po
index da2748b1..e885ac22 100644
--- a/messages.po
+++ b/messages.po
@@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PROJECT VERSION\n"
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
-"POT-Creation-Date: 2018-07-30 16:03-0400\n"
+"POT-Creation-Date: 2018-07-30 16:40-0400\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -238,17 +238,17 @@ msgstr ""
msgid "Please choose one or more commands to attach."
msgstr ""
-#: lib/extensions/convert_to_satin.py:24
+#: lib/extensions/convert_to_satin.py:25
msgid "Please select at least one line to convert to a satin column."
msgstr ""
#. : Convert To Satin extension, user selected one or more objects that were
#. not lines.
-#: lib/extensions/convert_to_satin.py:29
+#: lib/extensions/convert_to_satin.py:30
msgid "Only simple lines may be converted to satin columns."
msgstr ""
-#: lib/extensions/convert_to_satin.py:41
+#: lib/extensions/convert_to_satin.py:42
#, python-format
msgid ""
"Cannot convert %s to a satin column because it intersects itself. Try "