summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorKaalleen <36401965+kaalleen@users.noreply.github.com>2021-10-09 10:03:41 +0200
committerGitHub <noreply@github.com>2021-10-09 10:03:41 +0200
commitc75b90154b5bf6e40bb6286dc1e42949311fe240 (patch)
tree27db168b5e5fb00a4d827955ca912860931c5502 /lib
parente989a7bd74ba3a4e9c352b5f8381a92ca4a7e1f2 (diff)
Do not render comments (#1363)
Diffstat (limited to 'lib')
-rw-r--r--lib/extensions/base.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/extensions/base.py b/lib/extensions/base.py
index 828e3685..cc2fea53 100644
--- a/lib/extensions/base.py
+++ b/lib/extensions/base.py
@@ -10,6 +10,7 @@ from collections.abc import MutableMapping
import inkex
from lxml import etree
+from lxml.etree import Comment
from stringcase import snakecase
from ..commands import is_command, layer_commands
@@ -129,6 +130,10 @@ class InkstitchExtension(inkex.Effect):
def descendants(self, node, selected=False, troubleshoot=False): # noqa: C901
nodes = []
+
+ if node.tag == Comment:
+ return []
+
element = EmbroideryElement(node)
if element.has_command('ignore_object'):