summaryrefslogtreecommitdiff
path: root/gerber/cam.py
diff options
context:
space:
mode:
authorHamilton Kibbe <hamilton.kibbe@gmail.com>2015-06-11 11:20:56 -0400
committerHamilton Kibbe <hamilton.kibbe@gmail.com>2015-06-11 11:20:56 -0400
commit94f3976915d64a77135a1fdc8983085ee8d2e1f9 (patch)
tree353b06b7b26e5bcb6da6a08a39de24d800d73d09 /gerber/cam.py
parent1a70064e1097b90215e9f58b36cb31520d650eee (diff)
downloadgerbonara-94f3976915d64a77135a1fdc8983085ee8d2e1f9.tar.gz
gerbonara-94f3976915d64a77135a1fdc8983085ee8d2e1f9.tar.bz2
gerbonara-94f3976915d64a77135a1fdc8983085ee8d2e1f9.zip
Add keys to statements for linking to primitives. Add some API features to ExcellonFile, such as getting a tool path length and changing tool parameters. Excellonfiles write method generates statements based on the drill hits in the hits member, so drill hits in a generated file can be re-ordered by re-ordering the drill hits in ExcellonFile.hits. see #30
Diffstat (limited to 'gerber/cam.py')
-rw-r--r--gerber/cam.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/gerber/cam.py b/gerber/cam.py
index 31b6d2f..23d8214 100644
--- a/gerber/cam.py
+++ b/gerber/cam.py
@@ -220,7 +220,8 @@ class CamFile(object):
self.zeros = 'leading'
self.format = (2, 5)
self.statements = statements if statements is not None else []
- self.primitives = primitives
+ if primitives is not None:
+ self.primitives = primitives
self.filename = filename
self.layer_name = layer_name