summaryrefslogtreecommitdiff
path: root/docs/object-api.rst
diff options
context:
space:
mode:
authorjaseg <git@jaseg.de>2022-02-01 22:08:54 +0100
committerjaseg <git@jaseg.de>2022-02-01 22:08:54 +0100
commit7473e471dc69d09a35bb0762549cc4f3ab8b04b3 (patch)
treedcd162f56a5dbeac6ee669fc85d582813fd48eea /docs/object-api.rst
parentc3ca4f95bd59f69d45e582a4149327f57a360760 (diff)
downloadgerbonara-7473e471dc69d09a35bb0762549cc4f3ab8b04b3.tar.gz
gerbonara-7473e471dc69d09a35bb0762549cc4f3ab8b04b3.tar.bz2
gerbonara-7473e471dc69d09a35bb0762549cc4f3ab8b04b3.zip
Add some documentation
Diffstat (limited to 'docs/object-api.rst')
-rw-r--r--docs/object-api.rst30
1 files changed, 30 insertions, 0 deletions
diff --git a/docs/object-api.rst b/docs/object-api.rst
new file mode 100644
index 0000000..f6345b9
--- /dev/null
+++ b/docs/object-api.rst
@@ -0,0 +1,30 @@
+Graphic Objects
+===============
+
+Graphic objects are the lego blocks a gerbonara :py:class:`gerbonara.rs274x.GerberFile` or
+:py:class:`gerbonara.excellon.ExcellonFile` is built from. They are stored in the file's
+:py:attr:`gerbonara.rs274x.GerberFile.objects` list. You can directly manipulate that list from code.
+
+There are four graphic object types: :py:class:`gerbonara.graphic_objects.Flash`,
+:py:class:`gerbonara.graphic_objects.Line`, :py:class:`gerbonara.graphic_objects.Arc`, and
+:py:class:`gerbonara.graphic_objects.Region` . All of them are derived from
+:py:class:`gerbonara.graphic_objects.GraphicObject`.
+
+.. autoclass:: gerbonara.graphic_objects.GraphicObject
+ :members:
+
+.. autoclass:: gerbonara.graphic_objects.Flash
+ :members:
+
+.. autoclass:: gerbonara.graphic_objects.Line
+ :members:
+
+.. autoclass:: gerbonara.graphic_objects.Arc
+ :members:
+
+.. autoclass:: gerbonara.graphic_objects.Region
+ :members:
+
+.. _pcb-tools: https://github.com/opiopan/pcb-tools-extension
+.. _gerbolyze: https://github.com/jaseg/gerbolyze
+.. _svg-flatten: https://github.com/jaseg/gerbolyze/tree/main/svg-flatten