summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKaalleen <reni@allenka.de>2023-05-16 16:26:57 +0200
committerKaalleen <reni@allenka.de>2023-05-16 16:26:57 +0200
commita7e1de5c67c660cf8963b73358e08634ba8b3c39 (patch)
treee0e542c10c5a01df716c5b1b8a702b2d046e03e7
parenta300fa32fc729f6cd7fb15f0dbb0da79ee36417e (diff)
lpe satin: warn about empty d-attribute
-rw-r--r--lib/extensions/stroke_to_lpe_satin.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/extensions/stroke_to_lpe_satin.py b/lib/extensions/stroke_to_lpe_satin.py
index 5aa873e9..b89e471c 100644
--- a/lib/extensions/stroke_to_lpe_satin.py
+++ b/lib/extensions/stroke_to_lpe_satin.py
@@ -5,7 +5,7 @@
import inkex
-from ..elements import SatinColumn, Stroke
+from ..elements import EmptyDObject, SatinColumn, Stroke
from ..i18n import _
from ..svg.tags import ORIGINAL_D, PATH_EFFECT, SODIPODI_NODETYPES
from .base import InkstitchExtension
@@ -35,7 +35,10 @@ class StrokeToLpeSatin(InkstitchExtension):
if not any((isinstance(item, Stroke) or isinstance(item, SatinColumn)) for item in self.elements):
# L10N: Convert To Satin extension, user selected one or more objects that were not lines.
- inkex.errormsg(_("Please select at least one stroke to convert to a satin column."))
+ if any(isinstance(item, EmptyDObject) for item in self.elements):
+ inkex.errormsg(_("This element has lost its path information. Please move the element slightly back and forth before you try again."))
+ else:
+ inkex.errormsg(_("Please select at least one stroke to convert to a satin column."))
return
pattern = self.options.pattern