From 841e9196ba27176d606d448d30f6c2b6b6bbc739 Mon Sep 17 00:00:00 2001 From: Lex Neva Date: Sun, 30 Oct 2016 22:58:51 -0400 Subject: major refactor Split into classes for Fill, Stroke, and SatinColumn. Renamed params to be the same across XML attributes and OptionParser. Added distinct stitch length params for satin underlay. Renamed "satin underlay" to "contour underlay" and split out "center walk underlay" and "zigzag underlay". The code is ten times more readable, parameters make more sense, and everything is specified by the user in millimeters. Basically, everything is way better. --- PyEmb.py | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'PyEmb.py') diff --git a/PyEmb.py b/PyEmb.py index 585cbaf7..cc572185 100644 --- a/PyEmb.py +++ b/PyEmb.py @@ -60,6 +60,11 @@ class Point: def __cmp__(self, other): return cmp(self.as_tuple(), other.as_tuple()) + def __getitem__(self, item): + return self.as_tuple()[item] + + def __len__(self): + return 2 class Stitch(Point): -- cgit v1.2.3