blob: de9d10bab4d273177847b1ded0b356b6288ae8f4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
# Authors: see git history
#
# Copyright (c) 2010 Authors
# Licensed under the GNU GPL version 3.0 or later. See the file LICENSE for details.
import inkex
from ..i18n import _
from .element import EmbroideryElement
from .validation import ObjectTypeWarning
class MarkerWarning(ObjectTypeWarning):
name = _("Marker Element")
description = _("This element will not be embroidered. "
"It will be applied to objects in the same group. Objects in sub-groups will be ignored.")
steps_to_solve = [
_("Turn back to normal embroidery element mode, remove the marker:"),
_('* Open the Fill and Stroke panel (Objects > Fill and Stroke)'),
_('* Go to the Stroke style tab'),
_('* Under "Markers" choose the first (empty) option in the first dropdown list.')
]
class MarkerObject(EmbroideryElement):
name = "Marker"
def validation_warnings(self):
repr_point = next(inkex.Path(self.parse_path()).end_points)
yield MarkerWarning(repr_point)
def to_stitch_groups(self, last_stitch_group, next_element=None):
return []
def first_stitch(self):
return None
|