gerbonara/docs/utilities.rst

24 wiersze
870 B
ReStructuredText

2022-02-01 21:08:54 +00:00
Utilities
=========
2022-02-03 18:57:16 +00:00
Physical units
~~~~~~~~~~~~~~
Gerbonara tracks length units using the :py:class:`.LengthUnit` class. :py:class:`.LengthUnit` contains a number of
conventient conversion functions. Everywhere where Gerbonara accepts units as a method argument, it automatically
converts a string ``'mm'`` or ``'inch'`` to the corresponding :py:class:`.LengthUnit`.
2022-02-02 09:53:19 +00:00
.. autoclass:: gerbonara.utils.LengthUnit
:members:
2022-02-03 18:57:16 +00:00
Format settings
~~~~~~~~~~~~~~~
When reading or writing Gerber or Excellon, Gerbonara stores information about file format options such as zero
suppression or number of decimal places in a :py:class:`.FileSettings` instance. When you are writing a Gerber file,
Gerbonara picks reasonable defaults, but allows you to specify your own :py:class:`.FileSettings` to override these
defaults.
2022-02-02 09:53:19 +00:00
.. autoclass:: gerbonara.cam.FileSettings
:members: