summaryrefslogtreecommitdiff
path: root/lib/extensions/input.py
diff options
context:
space:
mode:
authorLex Neva <github.com@lexneva.name>2018-08-25 11:47:48 -0400
committerLex Neva <github.com@lexneva.name>2018-08-25 11:47:48 -0400
commit11d3cea80caeb9738a2eb02473801487c2acba3b (patch)
tree13510f23e5041628ef96997f14d852482ff04000 /lib/extensions/input.py
parentc5bd1878846c17309c99ad7554d4645088de9629 (diff)
parent6a16e90081e619eac5921bd8614c0c46dc83f852 (diff)
Merge remote-tracking branch 'origin/master' into simulator-timeline
Diffstat (limited to 'lib/extensions/input.py')
-rw-r--r--lib/extensions/input.py17
1 files changed, 6 insertions, 11 deletions
diff --git a/lib/extensions/input.py b/lib/extensions/input.py
index cb5ac452..975ba838 100644
--- a/lib/extensions/input.py
+++ b/lib/extensions/input.py
@@ -1,15 +1,11 @@
import os
-from os.path import realpath, dirname, join as path_join
-import sys
from inkex import etree
import inkex
import pyembroidery
from ..svg import PIXELS_PER_MM, render_stitch_plan
from ..svg.tags import INKSCAPE_LABEL
-from ..i18n import _
-from ..stitch_plan import StitchPlan, ColorBlock
-from ..utils.io import save_stdout
+from ..stitch_plan import StitchPlan
class Input(object):
@@ -28,12 +24,11 @@ class Input(object):
trim=(command == pyembroidery.TRIM))
extents = stitch_plan.extents
- svg = etree.Element("svg", nsmap=inkex.NSS, attrib=
- {
- "width": str(extents[0] * 2),
- "height": str(extents[1] * 2),
- "viewBox": "0 0 %s %s" % (extents[0] * 2, extents[1] * 2),
- })
+ svg = etree.Element("svg", nsmap=inkex.NSS, attrib={
+ "width": str(extents[0] * 2),
+ "height": str(extents[1] * 2),
+ "viewBox": "0 0 %s %s" % (extents[0] * 2, extents[1] * 2),
+ })
render_stitch_plan(svg, stitch_plan)
# rename the Stitch Plan layer so that it doesn't get overwritten by Embroider