summaryrefslogtreecommitdiff
path: root/gerbonara/gerber/cam.py
diff options
context:
space:
mode:
authorjaseg <git@jaseg.de>2021-11-10 21:39:03 +0100
committerjaseg <git@jaseg.de>2021-11-10 21:39:03 +0100
commitd21a2e67ff34d3f29e37a01f926b9e8f72003637 (patch)
tree8218f339a3336283c060aa5657a76a463b8e1982 /gerbonara/gerber/cam.py
parent125eb821b9f5d4c58b17d43e318e9a6829120d03 (diff)
downloadgerbonara-d21a2e67ff34d3f29e37a01f926b9e8f72003637.tar.gz
gerbonara-d21a2e67ff34d3f29e37a01f926b9e8f72003637.tar.bz2
gerbonara-d21a2e67ff34d3f29e37a01f926b9e8f72003637.zip
WIP
Diffstat (limited to 'gerbonara/gerber/cam.py')
-rw-r--r--gerbonara/gerber/cam.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/gerbonara/gerber/cam.py b/gerbonara/gerber/cam.py
index 5da8600..7d68ae2 100644
--- a/gerbonara/gerber/cam.py
+++ b/gerbonara/gerber/cam.py
@@ -24,6 +24,7 @@ class FileSettings:
image_polarity : str = 'positive'
image_rotation: int = 0
mirror_image : tuple = (False, False)
+ offset : tuple = (0, 0)
scale_factor : tuple = (1.0, 1.0) # For deprecated SF statement
notation : str = 'absolute'
units : str = 'inch'
@@ -41,6 +42,8 @@ class FileSettings:
raise ValueError('image_polarity must be either "positive" or "negative"')
elif name == 'mirror_image' and len(value) != 2:
raise ValueError('mirror_image must be 2-tuple of bools: (mirror_a, mirror_b)')
+ elif name == 'offset' and len(value) != 2:
+ raise ValueError('offset must be 2-tuple of floats: (offset_a, offset_b)')
elif name == 'scale_factor' and len(value) != 2:
raise ValueError('scale_factor must be 2-tuple of floats: (scale_a, scale_b)')
elif name == 'notation' and value not in ['inch', 'mm']: