summaryrefslogtreecommitdiff
path: root/gerber/gerber_statements.py
diff options
context:
space:
mode:
authorHamilton Kibbe <hamilton.kibbe@gmail.com>2015-02-15 02:20:02 -0500
committerHamilton Kibbe <hamilton.kibbe@gmail.com>2015-02-15 02:20:02 -0500
commit5cf1fa74b42eb8feaab23078bef6f31f6d647c33 (patch)
tree5758024d03d41fb9c8010314bbdb4f8f597db333 /gerber/gerber_statements.py
parent5e23d07bcb5103b4607c6ad591a2a547c97ee1f6 (diff)
downloadgerbonara-5cf1fa74b42eb8feaab23078bef6f31f6d647c33.tar.gz
gerbonara-5cf1fa74b42eb8feaab23078bef6f31f6d647c33.tar.bz2
gerbonara-5cf1fa74b42eb8feaab23078bef6f31f6d647c33.zip
Tests and bugfixes
Diffstat (limited to 'gerber/gerber_statements.py')
-rw-r--r--gerber/gerber_statements.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/gerber/gerber_statements.py b/gerber/gerber_statements.py
index 1401345..a6feef6 100644
--- a/gerber/gerber_statements.py
+++ b/gerber/gerber_statements.py
@@ -802,13 +802,13 @@ class CoordStmt(Statement):
if self.function:
coord_str += 'Fn: %s ' % self.function
if self.x is not None:
- coord_str += 'X: %f ' % self.x
+ coord_str += 'X: %g ' % self.x
if self.y is not None:
- coord_str += 'Y: %f ' % self.y
+ coord_str += 'Y: %g ' % self.y
if self.i is not None:
- coord_str += 'I: %f ' % self.i
+ coord_str += 'I: %g ' % self.i
if self.j is not None:
- coord_str += 'J: %f ' % self.j
+ coord_str += 'J: %g ' % self.j
if self.op:
if self.op == 'D01':
op = 'Lights On'
@@ -829,7 +829,7 @@ class ApertureStmt(Statement):
def __init__(self, d, deprecated=None):
Statement.__init__(self, "APERTURE")
self.d = int(d)
- self.deprecated = True if deprecated is not None else False
+ self.deprecated = True if deprecated is not None and deprecated is not False else False
def to_gerber(self, settings=None):
if self.deprecated: