summaryrefslogtreecommitdiff
path: root/gerbonara/gerber/primitives.py
diff options
context:
space:
mode:
authorjaseg <git@jaseg.de>2021-12-28 21:40:22 +0100
committerjaseg <git@jaseg.de>2021-12-28 21:40:22 +0100
commit63e1eae8d81cb7940d3547511488f8ec4acd4d1c (patch)
treec0d2ddf93d8637d0df600a320cbf9d1387860163 /gerbonara/gerber/primitives.py
parent25dd65fac05a43ef75fe75049d5b79a73a207fc0 (diff)
downloadgerbonara-63e1eae8d81cb7940d3547511488f8ec4acd4d1c.tar.gz
gerbonara-63e1eae8d81cb7940d3547511488f8ec4acd4d1c.tar.bz2
gerbonara-63e1eae8d81cb7940d3547511488f8ec4acd4d1c.zip
WIP
Diffstat (limited to 'gerbonara/gerber/primitives.py')
-rw-r--r--gerbonara/gerber/primitives.py16
1 files changed, 12 insertions, 4 deletions
diff --git a/gerbonara/gerber/primitives.py b/gerbonara/gerber/primitives.py
index 25f8e06..d505ddb 100644
--- a/gerbonara/gerber/primitives.py
+++ b/gerbonara/gerber/primitives.py
@@ -38,7 +38,7 @@ class Primitive:
class Line(Primitive):
- def __init__(self, start, end, aperture, polarity_dark=True, rotation=0, **meta):
+ def __init__(self, start, end, aperture=None, polarity_dark=True, rotation=0, **meta):
super().__init__(polarity_dark, rotation, **meta)
self.start = start
self.end = end
@@ -240,9 +240,6 @@ class Arc(Primitive):
class Circle(Primitive):
- """
- """
-
def __init__(self, position, diameter, polarity_dark=True):
super(Circle, self).__init__(**kwargs)
validate_coordinates(position)
@@ -922,3 +919,14 @@ class TestRecord(Primitive):
self.net_name = net_name
self.layer = layer
self._to_convert = ['position']
+
+class RegionGroup:
+ def __init__(self):
+ self.outline = []
+
+ def __bool__(self):
+ return bool(self.outline)
+
+ def append(self, primitive):
+ self.outline.append(primitive)
+