Small fixes in ApertureMacro and updated docs.

This commit is contained in:
Juan Pablo Caram 2014-03-12 23:30:19 -04:00
parent 04b9a0ecd7
commit 21da78d654
19 changed files with 1273 additions and 117 deletions

View File

@ -19,7 +19,7 @@ import simplejson as json
from matplotlib.figure import Figure
from numpy import arange, sin, pi
from matplotlib.backends.backend_gtk3agg import FigureCanvasGTK3Agg as FigureCanvas
from mpl_toolkits.axes_grid.anchored_artists import AnchoredText
#from mpl_toolkits.axes_grid.anchored_artists import AnchoredText
from camlib import *
import sys
@ -218,7 +218,7 @@ class FlatCAMObj:
:param obj_dict: Dictionary representing a FlatCAMObj
:type obj_dict: dict
:return None
:return: None
"""
return
@ -310,8 +310,8 @@ class FlatCAMGerber(FlatCAMObj, Gerber):
geometry = self.solid_geometry
else:
geometry = self.buffered_paths + \
[poly['polygon'] for poly in self.regions] + \
self.flash_geometry
[poly['polygon'] for poly in self.regions] + \
self.flash_geometry
if self.options["multicolored"]:
linespec = '-'
@ -418,7 +418,8 @@ class FlatCAMExcellon(FlatCAMObj, Excellon):
x, y = ints.coords.xy
self.axes.plot(x, y, 'g-')
self.app.plotcanvas.auto_adjust_axes()
#self.app.plotcanvas.auto_adjust_axes()
GLib.idle_add(self.app.plotcanvas.auto_adjust_axes)
def show_tool_chooser(self):
win = Gtk.Window()
@ -435,9 +436,9 @@ class FlatCAMExcellon(FlatCAMObj, Excellon):
def on_accept(widget):
win.destroy()
tool_list = []
for tool in self.tool_cbs:
if self.tool_cbs[tool].get_active():
tool_list.append(tool)
for toolx in self.tool_cbs:
if self.tool_cbs[toolx].get_active():
tool_list.append(toolx)
self.options["toolselection"] = ", ".join(tool_list)
self.to_form()
@ -758,10 +759,10 @@ class App:
t1.start()
#### For debugging only ###
def someThreadFunc(app_obj):
def somethreadfunc(app_obj):
print "Hello World!"
t = threading.Thread(target=someThreadFunc, args=(self,))
t = threading.Thread(target=somethreadfunc, args=(self,))
t.daemon = True
t.start()
@ -1060,7 +1061,9 @@ class App:
# Plot
# TODO: (Thread-safe?)
obj.plot()
self.on_zoom_fit(None)
# TODO: Threading dissaster!
GLib.idle_add(lambda: self.on_zoom_fit(None))
return obj
@ -1420,19 +1423,26 @@ class App:
def on_create_mirror(self, widget):
"""
Creates a mirror image of a Gerber object to be used as a bottom
copper layer.
Creates a mirror image of an object to be used as a bottom layer.
:param widget: Ignored.
:return: None
"""
# TODO: Move (some of) this to camlib!
# Layer to mirror
gerb_name = self.builder.get_object("comboboxtext_bottomlayer").get_active_text()
gerb = self.stuff[gerb_name]
# Object to mirror
try:
obj_name = self.builder.get_object("comboboxtext_bottomlayer").get_active_text()
fcobj = self.stuff[obj_name]
except KeyError:
self.info("WARNING: Cannot mirror that object.")
return
# For now, lets limit to Gerbers.
assert isinstance(gerb, FlatCAMGerber)
# For now, lets limit to Gerbers and Excellons.
# assert isinstance(gerb, FlatCAMGerber)
if not isinstance(fcobj, FlatCAMGerber) and not isinstance(fcobj, FlatCAMExcellon):
self.info("ERROR: Only Gerber and Excellon objects can be mirrored.")
return
# Mirror axis "X" or "Y
axis = self.get_radio_value({"rb_mirror_x": "X",
@ -1450,13 +1460,17 @@ class App:
py = 0.5*(ymin+ymax)
# Do the mirroring
xscale, yscale = {"X": (1.0, -1.0), "Y": (-1.0, 1.0)}[axis]
mirrored = affinity.scale(gerb.solid_geometry, xscale, yscale, origin=(px, py))
# xscale, yscale = {"X": (1.0, -1.0), "Y": (-1.0, 1.0)}[axis]
# mirrored = affinity.scale(fcobj.solid_geometry, xscale, yscale, origin=(px, py))
#
# def obj_init(obj_inst, app_inst):
# obj_inst.solid_geometry = mirrored
#
# self.new_object("gerber", fcobj.options["name"] + "_mirror", obj_init)
def obj_init(obj_inst, app_inst):
obj_inst.solid_geometry = mirrored
self.new_object("gerber", gerb.options["name"] + "_mirror", obj_init)
fcobj.mirror(axis, [px, py])
fcobj.plot()
#self.on_update_plot(None)
def on_create_aligndrill(self, widget):
"""
@ -1484,7 +1498,8 @@ class App:
xscale, yscale = {"X": (1.0, -1.0), "Y": (-1.0, 1.0)}[axis]
# Tools
tools = {"1": self.get_eval("entry_dblsided_alignholediam")}
dia = self.get_eval("entry_dblsided_alignholediam")
tools = {"1": {"C": dia}}
# Parse hole list
# TODO: Better parsing
@ -1967,7 +1982,7 @@ class App:
Callback for button on form for all kinds of objects.
Re-plots the current object only.
:param widget: The widget from which this was called.
:param widget: The widget from which this was called. Ignored.
:return: None
"""

112
camlib.py
View File

@ -237,7 +237,7 @@ class ApertureMacro:
val = re.sub(r'\$[0-9a-zA-Z](?![0-9a-zA-Z])', "0", val)
# Change x with *
val = re.sub(r'x', "\*", val)
val = re.sub(r'[xX]', "*", val)
# Eval() and store.
self.locvars[var] = eval(val)
@ -258,7 +258,7 @@ class ApertureMacro:
part = re.sub(r'\$[0-9a-zA-Z](?![0-9a-zA-Z])', "0", part)
# Change x with *
part = re.sub(r'x', "\*", part)
part = re.sub(r'[xX]', "*", part)
## Store
elements = part.split(",")
@ -391,7 +391,7 @@ class ApertureMacro:
pol, nverts, x, y, dia, angle = ApertureMacro.default2zero(6, mods)
points = [(0, 0)]*nverts
for i in nverts:
for i in range(nverts):
points[i] = (x + 0.5 * dia * cos(2*pi * i/nverts),
y + 0.5 * dia * sin(2*pi * i/nverts))
@ -483,8 +483,8 @@ class ApertureMacro:
modifiers = modifiers or []
modifiers = [float(m) for m in modifiers]
self.locvars = {}
for i in range(1, len(modifiers)+1):
self.locvars[str(i)] = modifiers[i]
for i in range(0, len(modifiers)):
self.locvars[str(i+1)] = modifiers[i]
## Parse
self.primitives = [] # Cleanup
@ -543,7 +543,7 @@ class Gerber (Geometry):
+------------+------------------------------------------------+
| Key | Value |
+============+================================================+
| loc | (list) [x (float), y (float)] coordinates. |
| loc | (Point) Shapely Point indicating location. |
+------------+------------------------------------------------+
| aperture | (str) The key for an aperture in apertures. |
+------------+------------------------------------------------+
@ -560,6 +560,11 @@ class Gerber (Geometry):
| aperture | (str) The key for an aperture in apertures. |
+------------+-----------------------------------------------------+
* ``aperture_macros`` (dictionary): Are predefined geometrical structures
that can be instanciated with different parameters in an aperture
definition. See ``apertures`` above. The key is the name of the macro,
and the macro itself, the value, is a ``Aperture_Macro`` object.
* ``flash_geometry`` (list): List of (Shapely) geometric object resulting
from ``flashes``. These are generated from ``flashes`` in ``do_flashes()``.
@ -574,7 +579,6 @@ class Gerber (Geometry):
g.create_geometry()
do_something(s.solid_geometry)
"""
def __init__(self):
@ -738,9 +742,7 @@ class Gerber (Geometry):
## Flashes
for fl in self.flashes:
# TODO: Shouldn't 'loc' be a numpy.array()?
fl['loc'][0] *= factor
fl['loc'][1] *= factor
fl['loc'] = affinity.scale(fl['loc'], factor, factor, origin=(0, 0))
## Regions
for reg in self.regions:
@ -776,9 +778,7 @@ class Gerber (Geometry):
## Flashes
for fl in self.flashes:
# TODO: Shouldn't 'loc' be a numpy.array()?
fl['loc'][0] += dx
fl['loc'][1] += dy
fl['loc'] = affinity.translate(fl['loc'], xoff=dx, yoff=dy)
## Regions
for reg in self.regions:
@ -788,6 +788,36 @@ class Gerber (Geometry):
# Now buffered_paths, flash_geometry and solid_geometry
self.create_geometry()
def mirror(self, axis, point):
"""
:param axis: "X" or "Y" indicates around which axis to mirror.
:type axis: str
:param point: [x, y] point belonging to the mirror axis.
:type point: list
:return: None
"""
px, py = point
xscale, yscale = {"X": (1.0, -1.0), "Y": (-1.0, 1.0)}[axis]
## Paths
for path in self.paths:
path['linestring'] = affinity.scale(path['linestring'], xscale, yscale,
origin=(px, py))
## Flashes
for fl in self.flashes:
fl['loc'] = affinity.scale(fl['loc'], xscale, yscale, origin=(px, py))
## Regions
for reg in self.regions:
reg['polygon'] = affinity.scale(reg['polygon'], xscale, yscale,
origin=(px, py))
# Now buffered_paths, flash_geometry and solid_geometry
self.create_geometry()
def fix_regions(self):
"""
Overwrites the region polygons with fixed
@ -1005,7 +1035,7 @@ class Gerber (Geometry):
# Flash
elif current_operation_code == 3:
self.flashes.append({"loc": [current_x, current_y],
self.flashes.append({"loc": Point([current_x, current_y]),
"aperture": current_aperture})
continue
@ -1202,12 +1232,13 @@ class Gerber (Geometry):
continue
if aperture['type'] == 'C': # Circles
circle = Point(flash['loc']).buffer(aperture['size']/2)
#circle = Point(flash['loc']).buffer(aperture['size']/2)
circle = flash['loc'].buffer(aperture['size']/2)
self.flash_geometry.append(circle)
continue
if aperture['type'] == 'R': # Rectangles
loc = flash['loc']
loc = flash['loc'].coords[0]
width = aperture['width']
height = aperture['height']
minx = loc[0] - width/2
@ -1219,7 +1250,7 @@ class Gerber (Geometry):
continue
if aperture['type'] == 'O': # Obround
loc = flash['loc']
loc = flash['loc'].coords[0]
width = aperture['width']
height = aperture['height']
if width > height:
@ -1237,7 +1268,7 @@ class Gerber (Geometry):
continue
if aperture['type'] == 'P': # Regular polygon
loc = flash['loc']
loc = flash['loc'].coords[0]
diam = aperture['diam']
n_vertices = aperture['nVertices']
points = []
@ -1252,7 +1283,7 @@ class Gerber (Geometry):
continue
if aperture['type'] == 'AM': # Aperture Macro
loc = flash['loc']
loc = flash['loc'].coords[0]
flash_geo = aperture['macro'].make_geometry(aperture['modifiers'])
flash_geo_final = affinity.translate(flash_geo, xoff=loc[0], yoff=loc[1])
self.flash_geometry.append(flash_geo_final)
@ -1307,7 +1338,14 @@ class Excellon(Geometry):
*ATTRIBUTES*
* ``tools`` (dict): The key is the tool name and the value is
the size (diameter).
a dictionary specifying the tool:
================ ====================================
Key Value
================ ====================================
C Diameter of the tool
Others Not supported (Ignored).
================ ====================================
* ``drills`` (list): Each is a dictionary:
@ -1524,14 +1562,20 @@ class Excellon(Geometry):
print "WARNING: Line ignored:", eline
def create_geometry(self):
"""
Creates circles of the tool diameter at every point
specified in ``self.drills``.
:return: None
"""
self.solid_geometry = []
for drill in self.drills:
poly = Point(drill['point']).buffer(self.tools[drill['tool']]["C"]/2.0)
#poly = drill['point'].buffer(self.tools[drill['tool']]["C"]/2.0)
tooldia = self.tools[drill['tool']]['C']
poly = drill['point'].buffer(tooldia/2.0)
self.solid_geometry.append(poly)
#self.solid_geometry = cascaded_union(self.solid_geometry)
def scale(self, factor):
"""
Scales geometry on the XY plane in the object by a given factor.
@ -1564,6 +1608,27 @@ class Excellon(Geometry):
for drill in self.drills:
drill['point'] = affinity.translate(drill['point'], xoff=dx, yoff=dy)
# Recreate geometry
self.create_geometry()
def mirror(self, axis, point):
"""
:param axis: "X" or "Y" indicates around which axis to mirror.
:type axis: str
:param point: [x, y] point belonging to the mirror axis.
:type point: list
:return: None
"""
px, py = point
xscale, yscale = {"X": (1.0, -1.0), "Y": (-1.0, 1.0)}[axis]
# Modify data
for drill in self.drills:
drill['point'] = affinity.scale(drill['point'], xscale, yscale, origin=(px, py))
# Recreate geometry
self.create_geometry()
def convert_units(self, units):
@ -2258,6 +2323,7 @@ def plotg(geo):
print "Cannot plot:", str(type(g))
continue
def parse_gerber_number(strnumber, frac_digits):
"""
Parse a single number of Gerber coordinates.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -3,14 +3,32 @@ Camlib
.. automodule:: camlib
Geometry
~~~~~~~~
.. autoclass:: Geometry
:members:
Gerber
~~~~~~
.. autoclass:: Gerber(Geometry)
:members:
.. autoclass:: Excellon
ApertureMacro
~~~~~~~~~~~~~
.. autoclass:: ApertureMacro
:members:
.. autoclass:: CNCjob
Excellon
~~~~~~~~
.. autoclass:: Excellon(Geometry)
:members:
CNCJob
~~~~~~
.. autoclass:: CNCjob(Geometry)
:members:

View File

@ -16,6 +16,7 @@ Contents:
camlib
flatcamobj
app
devman

403
doc/build/camlib.html vendored
View File

@ -81,11 +81,29 @@
<ul class="current">
<li class="toctree-l1 current"><a class="current reference internal" href="">Camlib</a></li>
<li class="toctree-l1"><a class="reference internal" href="flatcamobj.html">FlatCAM Objects</a></li>
<li class="toctree-l1 current"><a class="current reference internal" href="">Camlib</a><ul>
<li class="toctree-l2"><a class="reference internal" href="#geometry">Geometry</a></li>
<li class="toctree-l2"><a class="reference internal" href="#gerber">Gerber</a></li>
<li class="toctree-l2"><a class="reference internal" href="#aperturemacro">ApertureMacro</a></li>
<li class="toctree-l2"><a class="reference internal" href="#excellon">Excellon</a></li>
<li class="toctree-l2"><a class="reference internal" href="#cncjob">CNCJob</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="flatcamobj.html">FlatCAM Objects</a><ul>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamobj">FlatCAMObj</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamgerber">FlatCAMGerber</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamexcellon">FlatCAMExcellon</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamcncjob">FlatCAMCNCjob</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamgeometry">FlatCAMGeometry</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="app.html">FlatCAM Application</a><ul>
<li class="toctree-l2"><a class="reference internal" href="app.html#options">Options</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#module-FlatCAM">API</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#app">App</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#plotcanvas">PlotCanvas</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="devman.html">FlatCAM Developer Manual</a><ul>
<li class="toctree-l2"><a class="reference internal" href="devman.html#options">Options</a></li>
</ul>
</li>
</ul>
@ -124,6 +142,8 @@
<div class="section" id="module-camlib">
<span id="camlib"></span><h1>Camlib<a class="headerlink" href="#module-camlib" title="Permalink to this headline"></a></h1>
<div class="section" id="geometry">
<h2>Geometry<a class="headerlink" href="#geometry" title="Permalink to this headline"></a></h2>
<dl class="class">
<dt id="camlib.Geometry">
<em class="property">class </em><tt class="descclassname">camlib.</tt><tt class="descname">Geometry</tt><a class="headerlink" href="#camlib.Geometry" title="Permalink to this definition"></a></dt>
@ -262,6 +282,9 @@ Attributes to include are listed in <tt class="docutils literal"><span class="pr
</dd></dl>
</div>
<div class="section" id="gerber">
<h2>Gerber<a class="headerlink" href="#gerber" title="Permalink to this headline"></a></h2>
<dl class="class">
<dt id="camlib.Gerber">
<em class="property">class </em><tt class="descclassname">camlib.</tt><tt class="descname">Gerber</tt><big>(</big><em>Geometry</em><big>)</big><a class="headerlink" href="#camlib.Gerber" title="Permalink to this definition"></a></dt>
@ -283,7 +306,7 @@ type key is always present and the rest depend on the key:</li>
</thead>
<tbody valign="top">
<tr class="row-even"><td>type</td>
<td>(str) &#8220;C&#8221;, &#8220;R&#8221;, or &#8220;O&#8221;</td>
<td>(str) &#8220;C&#8221;, &#8220;R&#8221;, &#8220;O&#8221;, &#8220;P&#8221;, or &#8220;AP&#8221;</td>
</tr>
<tr class="row-odd"><td>others</td>
<td>Depend on <tt class="docutils literal"><span class="pre">type</span></tt></td>
@ -329,7 +352,7 @@ is a dictionary:</li>
</thead>
<tbody valign="top">
<tr class="row-even"><td>loc</td>
<td>(list) [x (float), y (float)] coordinates.</td>
<td>(Point) Shapely Point indicating location.</td>
</tr>
<tr class="row-odd"><td>aperture</td>
<td>(str) The key for an aperture in apertures.</td>
@ -361,6 +384,10 @@ associated with a region. Each is a dictionary:</li>
</tbody>
</table>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">aperture_macros</span></tt> (dictionary): Are predefined geometrical structures
that can be instanciated with different parameters in an aperture
definition. See <tt class="docutils literal"><span class="pre">apertures</span></tt> above. The key is the name of the macro,
and the macro itself, the value, is a <tt class="docutils literal"><span class="pre">Aperture_Macro</span></tt> object.</li>
<li><tt class="docutils literal"><span class="pre">flash_geometry</span></tt> (list): List of (Shapely) geometric object resulting
from <tt class="docutils literal"><span class="pre">flashes</span></tt>. These are generated from <tt class="docutils literal"><span class="pre">flashes</span></tt> in <tt class="docutils literal"><span class="pre">do_flashes()</span></tt>.</li>
<li><tt class="docutils literal"><span class="pre">buffered_paths</span></tt> (list): List of (Shapely) polygons resulting from
@ -376,23 +403,32 @@ generated from <tt class="docutils literal"><span class="pre">paths</span></tt>
</div>
<dl class="method">
<dt id="camlib.Gerber.aperture_parse">
<tt class="descname">aperture_parse</tt><big>(</big><em>gline</em><big>)</big><a class="headerlink" href="#camlib.Gerber.aperture_parse" title="Permalink to this definition"></a></dt>
<tt class="descname">aperture_parse</tt><big>(</big><em>apertureId</em>, <em>apertureType</em>, <em>apParameters</em><big>)</big><a class="headerlink" href="#camlib.Gerber.aperture_parse" title="Permalink to this definition"></a></dt>
<dd><p>Parse gerber aperture definition into dictionary of apertures.
The following kinds and their attributes are supported:</p>
<ul class="simple">
<li><em>Circular (C)</em>: size (float)</li>
<li><em>Rectangle (R)</em>: width (float), height (float)</li>
<li><em>Obround (O)</em>: width (float), height (float).</li>
<li><em>Polygon (P)</em>: diameter(float), vertices(int), [rotation(float)]</li>
<li><em>Aperture Macro (AM)</em>: macro (ApertureMacro), modifiers (list)</li>
</ul>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>gline</strong> (<em>str</em>) &#8211; Line of Gerber code known to have an aperture definition.</td>
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
<li><strong>apertureId</strong> (<em>str</em>) &#8211; Id of the aperture being defined.</li>
<li><strong>apertureType</strong> (<em>str</em>) &#8211; Type of the aperture.</li>
<li><strong>apParameters</strong> (<em>str</em>) &#8211; Parameters of the aperture.</li>
</ul>
</td>
</tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">Identifier of the aperture.</td>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">Identifier of the aperture.</p>
</td>
</tr>
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body">str</td>
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body"><p class="first last">str</p>
</td>
</tr>
</tbody>
</table>
@ -402,8 +438,15 @@ The following kinds and their attributes are supported:</p>
<dt id="camlib.Gerber.buffer_paths">
<tt class="descname">buffer_paths</tt><big>(</big><big>)</big><a class="headerlink" href="#camlib.Gerber.buffer_paths" title="Permalink to this definition"></a></dt>
<dd><p>This is part of the parsing process. &#8220;Thickens&#8221; the paths
by their appertures. This will only work for circular appertures.
:return: None</p>
by their appertures. This will only work for circular appertures.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">None</td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="method">
@ -428,6 +471,14 @@ and regions naturally do as well.</p>
<tt class="descname">fix_regions</tt><big>(</big><big>)</big><a class="headerlink" href="#camlib.Gerber.fix_regions" title="Permalink to this definition"></a></dt>
<dd><p>Overwrites the region polygons with fixed
versions if found to be invalid (according to Shapely).</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">None</td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="attribute">
@ -469,6 +520,26 @@ box in both positive and negative, x and y axes.</li>
<dd><p>Number of integer digits in Gerber numbers. Used during parsing.</p>
</dd></dl>
<dl class="method">
<dt id="camlib.Gerber.mirror">
<tt class="descname">mirror</tt><big>(</big><em>axis</em>, <em>point</em><big>)</big><a class="headerlink" href="#camlib.Gerber.mirror" title="Permalink to this definition"></a></dt>
<dd><table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
<li><strong>axis</strong> (<em>str</em>) &#8211; &#8220;X&#8221; or &#8220;Y&#8221; indicates around which axis to mirror.</li>
<li><strong>point</strong> (<em>list</em>) &#8211; [x, y] point belonging to the mirror axis.</li>
</ul>
</td>
</tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">None</p>
</td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="method">
<dt id="camlib.Gerber.offset">
<tt class="descname">offset</tt><big>(</big><em>vect</em><big>)</big><a class="headerlink" href="#camlib.Gerber.offset" title="Permalink to this definition"></a></dt>
@ -480,10 +551,17 @@ These are:</p>
<li><tt class="docutils literal"><span class="pre">flashes</span></tt></li>
</ul>
<p>Then <tt class="docutils literal"><span class="pre">buffered_paths</span></tt>, <tt class="docutils literal"><span class="pre">flash_geometry</span></tt> and <tt class="docutils literal"><span class="pre">solid_geometry</span></tt>
are re-created with <tt class="docutils literal"><span class="pre">self.create_geometry()</span></tt>.
:param vect: (x, y) offset vector.
:type vect: tuple
:return: None</p>
are re-created with <tt class="docutils literal"><span class="pre">self.create_geometry()</span></tt>.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>vect</strong> (<em>tuple</em>) &#8211; (x, y) offset vector.</td>
</tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="method">
@ -491,6 +569,16 @@ are re-created with <tt class="docutils literal"><span class="pre">self.create_g
<tt class="descname">parse_file</tt><big>(</big><em>filename</em><big>)</big><a class="headerlink" href="#camlib.Gerber.parse_file" title="Permalink to this definition"></a></dt>
<dd><p>Calls Gerber.parse_lines() with array of lines
read from the given file.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>filename</strong> (<em>str</em>) &#8211; Gerber file to parse.</td>
</tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="method">
@ -533,13 +621,251 @@ are re-created with <tt class="docutils literal"><span class="pre">self.create_g
</dd></dl>
</div>
<div class="section" id="aperturemacro">
<h2>ApertureMacro<a class="headerlink" href="#aperturemacro" title="Permalink to this headline"></a></h2>
<dl class="class">
<dt id="camlib.ApertureMacro">
<em class="property">class </em><tt class="descclassname">camlib.</tt><tt class="descname">ApertureMacro</tt><big>(</big><em>name=None</em><big>)</big><a class="headerlink" href="#camlib.ApertureMacro" title="Permalink to this definition"></a></dt>
<dd><dl class="method">
<dt id="camlib.ApertureMacro.append">
<tt class="descname">append</tt><big>(</big><em>data</em><big>)</big><a class="headerlink" href="#camlib.ApertureMacro.append" title="Permalink to this definition"></a></dt>
<dd><p>Appends a string to the raw macro.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>data</strong> (<em>str</em>) &#8211; Part of the macro.</td>
</tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="staticmethod">
<dt id="camlib.ApertureMacro.default2zero">
<em class="property">static </em><tt class="descname">default2zero</tt><big>(</big><em>n</em>, <em>mods</em><big>)</big><a class="headerlink" href="#camlib.ApertureMacro.default2zero" title="Permalink to this definition"></a></dt>
<dd><p>Pads the <tt class="docutils literal"><span class="pre">mods</span></tt> list with zeros resulting in an
list of length n.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
<li><strong>n</strong> (<em>int</em>) &#8211; Length of the resulting list.</li>
<li><strong>mods</strong> (<em>list</em>) &#8211; List to be padded.</li>
</ul>
</td>
</tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">Zero-padded list.</p>
</td>
</tr>
<tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body"><p class="first last">list</p>
</td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="staticmethod">
<dt id="camlib.ApertureMacro.make_centerline">
<em class="property">static </em><tt class="descname">make_centerline</tt><big>(</big><em>mods</em><big>)</big><a class="headerlink" href="#camlib.ApertureMacro.make_centerline" title="Permalink to this definition"></a></dt>
<dd><table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>mods</strong> &#8211; (Exposure 0/1, width &gt;=0, height &gt;=0, x-center, y-center,
rotation angle around origin in degrees)</td>
</tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"></td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="staticmethod">
<dt id="camlib.ApertureMacro.make_circle">
<em class="property">static </em><tt class="descname">make_circle</tt><big>(</big><em>mods</em><big>)</big><a class="headerlink" href="#camlib.ApertureMacro.make_circle" title="Permalink to this definition"></a></dt>
<dd><table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>mods</strong> &#8211; (Exposure 0/1, Diameter &gt;=0, X-coord, Y-coord)</td>
</tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"></td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="method">
<dt id="camlib.ApertureMacro.make_geometry">
<tt class="descname">make_geometry</tt><big>(</big><em>modifiers</em><big>)</big><a class="headerlink" href="#camlib.ApertureMacro.make_geometry" title="Permalink to this definition"></a></dt>
<dd><p>Runs the macro for the given modifiers and generates
the corresponding geometry.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>modifiers</strong> (<em>list</em>) &#8211; Modifiers (parameters) for this macro</td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="staticmethod">
<dt id="camlib.ApertureMacro.make_lowerleftline">
<em class="property">static </em><tt class="descname">make_lowerleftline</tt><big>(</big><em>mods</em><big>)</big><a class="headerlink" href="#camlib.ApertureMacro.make_lowerleftline" title="Permalink to this definition"></a></dt>
<dd><table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>mods</strong> &#8211; (exposure 0/1, width &gt;=0, height &gt;=0, x-lowerleft, y-lowerleft,
rotation angle around origin in degrees)</td>
</tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"></td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="staticmethod">
<dt id="camlib.ApertureMacro.make_moire">
<em class="property">static </em><tt class="descname">make_moire</tt><big>(</big><em>mods</em><big>)</big><a class="headerlink" href="#camlib.ApertureMacro.make_moire" title="Permalink to this definition"></a></dt>
<dd><p>Note: Specs indicate that rotation is only allowed if the center
(x, y) == (0, 0). I will tolerate breaking this rule.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>mods</strong> &#8211; (x-center, y-center, outer_dia_outer_ring, ring thickness,
gap, max_rings, crosshair_thickness, crosshair_len, rotation
angle around origin in degrees)</td>
</tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"></td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="staticmethod">
<dt id="camlib.ApertureMacro.make_outline">
<em class="property">static </em><tt class="descname">make_outline</tt><big>(</big><em>mods</em><big>)</big><a class="headerlink" href="#camlib.ApertureMacro.make_outline" title="Permalink to this definition"></a></dt>
<dd><table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>mods</strong> &#8211; </td>
</tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"></td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="staticmethod">
<dt id="camlib.ApertureMacro.make_polygon">
<em class="property">static </em><tt class="descname">make_polygon</tt><big>(</big><em>mods</em><big>)</big><a class="headerlink" href="#camlib.ApertureMacro.make_polygon" title="Permalink to this definition"></a></dt>
<dd><p>Note: Specs indicate that rotation is only allowed if the center
(x, y) == (0, 0). I will tolerate breaking this rule.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>mods</strong> &#8211; (exposure 0/1, n_verts 3&lt;=n&lt;=12, x-center, y-center,
diameter of circumscribed circle &gt;=0, rotation angle around origin)</td>
</tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"></td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="staticmethod">
<dt id="camlib.ApertureMacro.make_thermal">
<em class="property">static </em><tt class="descname">make_thermal</tt><big>(</big><em>mods</em><big>)</big><a class="headerlink" href="#camlib.ApertureMacro.make_thermal" title="Permalink to this definition"></a></dt>
<dd><p>Note: Specs indicate that rotation is only allowed if the center
(x, y) == (0, 0). I will tolerate breaking this rule.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>mods</strong> &#8211; [x-center, y-center, diameter-outside, diameter-inside,
gap-thickness, rotation angle around origin]</td>
</tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"></td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="staticmethod">
<dt id="camlib.ApertureMacro.make_vectorline">
<em class="property">static </em><tt class="descname">make_vectorline</tt><big>(</big><em>mods</em><big>)</big><a class="headerlink" href="#camlib.ApertureMacro.make_vectorline" title="Permalink to this definition"></a></dt>
<dd><table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>mods</strong> &#8211; (Exposure 0/1, Line width &gt;= 0, X-start, Y-start, X-end, Y-end,
rotation angle around origin in degrees)</td>
</tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"></td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="method">
<dt id="camlib.ApertureMacro.parse_content">
<tt class="descname">parse_content</tt><big>(</big><big>)</big><a class="headerlink" href="#camlib.ApertureMacro.parse_content" title="Permalink to this definition"></a></dt>
<dd><p>Creates numerical lists for all primitives in the aperture
macro (in <tt class="docutils literal"><span class="pre">self.raw</span></tt>) by replacing all variables by their
values iteratively and evaluating expressions. Results
are stored in <tt class="docutils literal"><span class="pre">self.primitives</span></tt>.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">None</td>
</tr>
</tbody>
</table>
</dd></dl>
</dd></dl>
</div>
<div class="section" id="excellon">
<h2>Excellon<a class="headerlink" href="#excellon" title="Permalink to this headline"></a></h2>
<dl class="class">
<dt id="camlib.Excellon">
<em class="property">class </em><tt class="descclassname">camlib.</tt><tt class="descname">Excellon</tt><a class="headerlink" href="#camlib.Excellon" title="Permalink to this definition"></a></dt>
<em class="property">class </em><tt class="descclassname">camlib.</tt><tt class="descname">Excellon</tt><big>(</big><em>Geometry</em><big>)</big><a class="headerlink" href="#camlib.Excellon" title="Permalink to this definition"></a></dt>
<dd><p><em>ATTRIBUTES</em></p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">tools</span></tt> (dict): The key is the tool name and the value is
the size (diameter).</li>
a dictionary specifying the tool:</li>
</ul>
<table border="1" class="docutils">
<colgroup>
<col width="31%" />
<col width="69%" />
</colgroup>
<thead valign="bottom">
<tr class="row-odd"><th class="head">Key</th>
<th class="head">Value</th>
</tr>
</thead>
<tbody valign="top">
<tr class="row-even"><td>C</td>
<td>Diameter of the tool</td>
</tr>
<tr class="row-odd"><td>Others</td>
<td>Not supported (Ignored).</td>
</tr>
</tbody>
</table>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">drills</span></tt> (list): Each is a dictionary:</li>
</ul>
<table border="1" class="docutils">
@ -561,6 +887,41 @@ the size (diameter).</li>
</tr>
</tbody>
</table>
<dl class="method">
<dt id="camlib.Excellon.create_geometry">
<tt class="descname">create_geometry</tt><big>(</big><big>)</big><a class="headerlink" href="#camlib.Excellon.create_geometry" title="Permalink to this definition"></a></dt>
<dd><p>Creates circles of the tool diameter at every point
specified in <tt class="docutils literal"><span class="pre">self.drills</span></tt>.</p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">None</td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="method">
<dt id="camlib.Excellon.mirror">
<tt class="descname">mirror</tt><big>(</big><em>axis</em>, <em>point</em><big>)</big><a class="headerlink" href="#camlib.Excellon.mirror" title="Permalink to this definition"></a></dt>
<dd><table class="docutils field-list" frame="void" rules="none">
<col class="field-name" />
<col class="field-body" />
<tbody valign="top">
<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
<li><strong>axis</strong> (<em>str</em>) &#8211; &#8220;X&#8221; or &#8220;Y&#8221; indicates around which axis to mirror.</li>
<li><strong>point</strong> (<em>list</em>) &#8211; [x, y] point belonging to the mirror axis.</li>
</ul>
</td>
</tr>
<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">None</p>
</td>
</tr>
</tbody>
</table>
</dd></dl>
<dl class="method">
<dt id="camlib.Excellon.offset">
<tt class="descname">offset</tt><big>(</big><em>vect</em><big>)</big><a class="headerlink" href="#camlib.Excellon.offset" title="Permalink to this definition"></a></dt>
@ -631,9 +992,12 @@ Tool sizes, feedrates an Z-plane dimensions are untouched.</p>
</dd></dl>
</div>
<div class="section" id="cncjob">
<h2>CNCJob<a class="headerlink" href="#cncjob" title="Permalink to this headline"></a></h2>
<dl class="class">
<dt id="camlib.CNCjob">
<em class="property">class </em><tt class="descclassname">camlib.</tt><tt class="descname">CNCjob</tt><big>(</big><em>units='in'</em>, <em>kind='generic'</em>, <em>z_move=0.1</em>, <em>feedrate=3.0</em>, <em>z_cut=-0.002</em>, <em>tooldia=0.0</em><big>)</big><a class="headerlink" href="#camlib.CNCjob" title="Permalink to this definition"></a></dt>
<em class="property">class </em><tt class="descclassname">camlib.</tt><tt class="descname">CNCjob</tt><big>(</big><em>Geometry</em><big>)</big><a class="headerlink" href="#camlib.CNCjob" title="Permalink to this definition"></a></dt>
<dd><p>Represents work to be done by a CNC machine.</p>
<p><em>ATTRIBUTES</em></p>
<ul class="simple">
@ -865,6 +1229,7 @@ not altered.</p>
</dd></dl>
</div>
</div>

View File

@ -80,11 +80,29 @@
<ul>
<li class="toctree-l1"><a class="reference internal" href="camlib.html">Camlib</a></li>
<li class="toctree-l1"><a class="reference internal" href="flatcamobj.html">FlatCAM Objects</a></li>
<li class="toctree-l1"><a class="reference internal" href="camlib.html">Camlib</a><ul>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#geometry">Geometry</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#gerber">Gerber</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#aperturemacro">ApertureMacro</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#excellon">Excellon</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#cncjob">CNCJob</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="flatcamobj.html">FlatCAM Objects</a><ul>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamobj">FlatCAMObj</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamgerber">FlatCAMGerber</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamexcellon">FlatCAMExcellon</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamcncjob">FlatCAMCNCjob</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamgeometry">FlatCAMGeometry</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="app.html">FlatCAM Application</a><ul>
<li class="toctree-l2"><a class="reference internal" href="app.html#options">Options</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#api">API</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#app">App</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#plotcanvas">PlotCanvas</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="devman.html">FlatCAM Developer Manual</a><ul>
<li class="toctree-l2"><a class="reference internal" href="devman.html#options">Options</a></li>
</ul>
</li>
</ul>
@ -132,19 +150,46 @@
| <a href="#G"><strong>G</strong></a>
| <a href="#I"><strong>I</strong></a>
| <a href="#L"><strong>L</strong></a>
| <a href="#M"><strong>M</strong></a>
| <a href="#N"><strong>N</strong></a>
| <a href="#O"><strong>O</strong></a>
| <a href="#P"><strong>P</strong></a>
| <a href="#R"><strong>R</strong></a>
| <a href="#S"><strong>S</strong></a>
| <a href="#T"><strong>T</strong></a>
| <a href="#V"><strong>V</strong></a>
| <a href="#Z"><strong>Z</strong></a>
</div>
<h2 id="A">A</h2>
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="app.html#FlatCAM.PlotCanvas.adjust_axes">adjust_axes() (FlatCAM.PlotCanvas method)</a>
</dt>
<dt><a href="camlib.html#camlib.Gerber.aperture_parse">aperture_parse() (camlib.Gerber method)</a>
</dt>
<dt><a href="camlib.html#camlib.ApertureMacro">ApertureMacro (class in camlib)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="app.html#FlatCAM.App">App (class in FlatCAM)</a>
</dt>
<dt><a href="camlib.html#camlib.ApertureMacro.append">append() (camlib.ApertureMacro method)</a>
</dt>
<dt><a href="app.html#FlatCAM.PlotCanvas.auto_adjust_axes">auto_adjust_axes() (FlatCAM.PlotCanvas method)</a>
</dt>
</dl></td>
</tr></table>
@ -155,10 +200,18 @@
<dt><a href="camlib.html#camlib.Geometry.bounds">bounds() (camlib.Geometry method)</a>
</dt>
<dt><a href="camlib.html#camlib.Gerber.buffer_paths">buffer_paths() (camlib.Gerber method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="camlib.html#camlib.Gerber.buffer_paths">buffer_paths() (camlib.Gerber method)</a>
<dt><a href="app.html#FlatCAM.App.build_list">build_list() (FlatCAM.App method)</a>
</dt>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMObj.build_ui">build_ui() (FlatCAM.FlatCAMObj method)</a>
</dt>
</dl></td>
@ -172,6 +225,10 @@
</dt>
<dt><a href="app.html#FlatCAM.PlotCanvas.clear">clear() (FlatCAM.PlotCanvas method)</a>
</dt>
<dt><a href="camlib.html#camlib.Geometry.clear_polygon">clear_polygon() (camlib.Geometry method)</a>
</dt>
@ -182,13 +239,29 @@
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="camlib.html#camlib.Geometry.convert_units">convert_units() (camlib.Geometry method)</a>
<dt><a href="app.html#FlatCAM.PlotCanvas.connect">connect() (FlatCAM.PlotCanvas method)</a>
</dt>
<dt><a href="camlib.html#camlib.Gerber.create_geometry">create_geometry() (camlib.Gerber method)</a>
<dt><a href="camlib.html#camlib.Geometry.convert_units">convert_units() (camlib.Geometry method)</a>
</dt>
<dd><dl>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMGerber.convert_units">(FlatCAM.FlatCAMGerber method)</a>
</dt>
</dl></dd>
<dt><a href="camlib.html#camlib.Excellon.create_geometry">create_geometry() (camlib.Excellon method)</a>
</dt>
<dd><dl>
<dt><a href="camlib.html#camlib.Gerber.create_geometry">(camlib.Gerber method)</a>
</dt>
</dl></dd>
</dl></td>
</tr></table>
@ -196,6 +269,16 @@
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="camlib.html#camlib.ApertureMacro.default2zero">default2zero() (camlib.ApertureMacro static method)</a>
</dt>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMObj.deserialize">deserialize() (FlatCAM.FlatCAMObj method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="camlib.html#camlib.Gerber.do_flashes">do_flashes() (camlib.Gerber method)</a>
</dt>
@ -216,15 +299,47 @@
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="app.html#FlatCAM.App.file_chooser_action">file_chooser_action() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.file_chooser_save_action">file_chooser_save_action() (FlatCAM.App method)</a>
</dt>
<dt><a href="camlib.html#camlib.Gerber.fix_regions">fix_regions() (camlib.Gerber method)</a>
</dt>
<dt><a href="app.html#module-FlatCAM">FlatCAM (module)</a>, <a href="flatcamobj.html#module-FlatCAM">[1]</a>
</dt>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMCNCjob">FlatCAMCNCjob (class in FlatCAM)</a>
</dt>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMExcellon">FlatCAMExcellon (class in FlatCAM)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMGeometry">FlatCAMGeometry (class in FlatCAM)</a>
</dt>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMGerber">FlatCAMGerber (class in FlatCAM)</a>
</dt>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMObj">FlatCAMObj (class in FlatCAM)</a>
</dt>
<dt><a href="camlib.html#camlib.Gerber.frac_digits">frac_digits (camlib.Gerber attribute)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="camlib.html#camlib.Geometry.from_dict">from_dict() (camlib.Geometry method)</a>
</dt>
@ -251,8 +366,6 @@
<dt><a href="camlib.html#camlib.CNCjob.generate_from_geometry">generate_from_geometry() (camlib.CNCjob method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="camlib.html#camlib.Geometry">Geometry (class in camlib)</a>
</dt>
@ -261,14 +374,28 @@
<dt><a href="camlib.html#camlib.Gerber">Gerber (class in camlib)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="camlib.html#camlib.Gerber.get_bounding_box">get_bounding_box() (camlib.Gerber method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.get_current">get_current() (FlatCAM.App method)</a>
</dt>
<dt><a href="camlib.html#camlib.Geometry.get_empty_area">get_empty_area() (camlib.Geometry method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.get_eval">get_eval() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.get_radio_value">get_radio_value() (FlatCAM.App method)</a>
</dt>
</dl></td>
</tr></table>
@ -276,6 +403,10 @@
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="app.html#FlatCAM.App.info">info() (FlatCAM.App method)</a>
</dt>
<dt><a href="camlib.html#camlib.Gerber.int_digits">int_digits (camlib.Gerber attribute)</a>
</dt>
@ -295,6 +426,86 @@
<dt><a href="camlib.html#camlib.CNCjob.linear2gcode">linear2gcode() (camlib.CNCjob method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="app.html#FlatCAM.App.load_defaults">load_defaults() (FlatCAM.App method)</a>
</dt>
</dl></td>
</tr></table>
<h2 id="M">M</h2>
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="camlib.html#camlib.ApertureMacro.make_centerline">make_centerline() (camlib.ApertureMacro static method)</a>
</dt>
<dt><a href="camlib.html#camlib.ApertureMacro.make_circle">make_circle() (camlib.ApertureMacro static method)</a>
</dt>
<dt><a href="camlib.html#camlib.ApertureMacro.make_geometry">make_geometry() (camlib.ApertureMacro method)</a>
</dt>
<dt><a href="camlib.html#camlib.ApertureMacro.make_lowerleftline">make_lowerleftline() (camlib.ApertureMacro static method)</a>
</dt>
<dt><a href="camlib.html#camlib.ApertureMacro.make_moire">make_moire() (camlib.ApertureMacro static method)</a>
</dt>
<dt><a href="camlib.html#camlib.ApertureMacro.make_outline">make_outline() (camlib.ApertureMacro static method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="camlib.html#camlib.ApertureMacro.make_polygon">make_polygon() (camlib.ApertureMacro static method)</a>
</dt>
<dt><a href="camlib.html#camlib.ApertureMacro.make_thermal">make_thermal() (camlib.ApertureMacro static method)</a>
</dt>
<dt><a href="camlib.html#camlib.ApertureMacro.make_vectorline">make_vectorline() (camlib.ApertureMacro static method)</a>
</dt>
<dt><a href="camlib.html#camlib.Excellon.mirror">mirror() (camlib.Excellon method)</a>
</dt>
<dd><dl>
<dt><a href="camlib.html#camlib.Gerber.mirror">(camlib.Gerber method)</a>
</dt>
</dl></dd>
<dt><a href="app.html#FlatCAM.PlotCanvas.mpl_connect">mpl_connect() (FlatCAM.PlotCanvas method)</a>
</dt>
</dl></td>
</tr></table>
<h2 id="N">N</h2>
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="app.html#FlatCAM.PlotCanvas.new_axes">new_axes() (FlatCAM.PlotCanvas method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="app.html#FlatCAM.App.new_object">new_object() (FlatCAM.App method)</a>
</dt>
</dl></td>
</tr></table>
@ -307,6 +518,10 @@
<dd><dl>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMGeometry.offset">(FlatCAM.FlatCAMGeometry method)</a>
</dt>
<dt><a href="camlib.html#camlib.Excellon.offset">(camlib.Excellon method)</a>
</dt>
@ -319,6 +534,236 @@
</dt>
</dl></dd>
<dt><a href="app.html#FlatCAM.App.on_about">on_about() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_activate_name">on_activate_name() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_canvas_configure">on_canvas_configure() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_cb_plot_toggled">on_cb_plot_toggled() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_clear_plots">on_clear_plots() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_click_over_plot">on_click_over_plot() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_closewindow">on_closewindow() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_cncjob_exportgcode">on_cncjob_exportgcode() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_create_aligndrill">on_create_aligndrill() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_create_mirror">on_create_mirror() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_delete">on_delete() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_entry_eval_activate">on_entry_eval_activate() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_eval_update">on_eval_update() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_excellon_tool_choose">on_excellon_tool_choose() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_file_new">on_file_new() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_file_openproject">on_file_openproject() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_file_savedefaults">on_file_savedefaults() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_file_saveproject">on_file_saveproject() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_file_saveprojectas">on_file_saveprojectas() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_file_saveprojectcopy">on_file_saveprojectcopy() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_fileopenexcellon">on_fileopenexcellon() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_fileopengcode">on_fileopengcode() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_fileopengerber">on_fileopengerber() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_filequit">on_filequit() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_generate_cncjob">on_generate_cncjob() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_generate_excellon_cncjob">on_generate_excellon_cncjob() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_generate_gerber_bounding_box">on_generate_gerber_bounding_box() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_generate_isolation">on_generate_isolation() (FlatCAM.App method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="app.html#FlatCAM.App.on_generate_paintarea">on_generate_paintarea() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_gerber_generate_cutout">on_gerber_generate_cutout() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_gerber_generate_noncopper">on_gerber_generate_noncopper() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_key_over_plot">on_key_over_plot() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.PlotCanvas.on_mouse_move">on_mouse_move() (FlatCAM.PlotCanvas method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_mouse_move_over_plot">on_mouse_move_over_plot() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_offset_object">on_offset_object() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_options_app2object">on_options_app2object() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_options_app2project">on_options_app2project() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_options_combo_change">on_options_combo_change() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_options_object2app">on_options_object2app() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_options_object2project">on_options_object2project() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_options_project2app">on_options_project2app() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_options_project2object">on_options_project2object() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_options_update">on_options_update() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_row_activated">on_row_activated() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_scale_object">on_scale_object() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.PlotCanvas.on_scroll">on_scroll() (FlatCAM.PlotCanvas method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_toggle_pointbox">on_toggle_pointbox() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_toggle_units">on_toggle_units() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_toolbar_replot">on_toolbar_replot() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_tools_doublesided">on_tools_doublesided() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_tree_selection_changed">on_tree_selection_changed() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_update_plot">on_update_plot() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_zoom_fit">on_zoom_fit() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_zoom_in">on_zoom_in() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.on_zoom_out">on_zoom_out() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.open_project">open_project() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.options2form">options2form() (FlatCAM.App method)</a>
</dt>
</dl></td>
</tr></table>
@ -326,6 +771,10 @@
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="camlib.html#camlib.ApertureMacro.parse_content">parse_content() (camlib.ApertureMacro method)</a>
</dt>
<dt><a href="camlib.html#camlib.Excellon.parse_file">parse_file() (camlib.Excellon method)</a>
</dt>
@ -346,31 +795,89 @@
</dl></dd>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMGeometry.plot">plot() (FlatCAM.FlatCAMGeometry method)</a>
</dt>
<dd><dl>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMObj.plot">(FlatCAM.FlatCAMObj method)</a>
</dt>
</dl></dd>
<dt><a href="camlib.html#camlib.CNCjob.plot2">plot2() (camlib.CNCjob method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="app.html#FlatCAM.App.plot_all">plot_all() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.PlotCanvas">PlotCanvas (class in FlatCAM)</a>
</dt>
<dt><a href="camlib.html#camlib.CNCjob.polygon2gcode">polygon2gcode() (camlib.CNCjob method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.populate_objects_combo">populate_objects_combo() (FlatCAM.App method)</a>
</dt>
<dt><a href="camlib.html#camlib.CNCjob.pre_parse">pre_parse() (camlib.CNCjob method)</a>
</dt>
</dl></td>
</tr></table>
<h2 id="R">R</h2>
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="app.html#FlatCAM.App.read_form">read_form() (FlatCAM.App method)</a>
</dt>
<dd><dl>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMObj.read_form">(FlatCAM.FlatCAMObj method)</a>
</dt>
</dl></dd>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="app.html#FlatCAM.App.read_form_item">read_form_item() (FlatCAM.App method)</a>
</dt>
<dd><dl>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMObj.read_form_item">(FlatCAM.FlatCAMObj method)</a>
</dt>
</dl></dd>
</dl></td>
</tr></table>
<h2 id="S">S</h2>
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="app.html#FlatCAM.App.save_project">save_project() (FlatCAM.App method)</a>
</dt>
<dt><a href="camlib.html#camlib.CNCjob.scale">scale() (camlib.CNCjob method)</a>
</dt>
<dd><dl>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMGeometry.scale">(FlatCAM.FlatCAMGeometry method)</a>
</dt>
<dt><a href="camlib.html#camlib.Excellon.scale">(camlib.Excellon method)</a>
</dt>
@ -383,9 +890,47 @@
</dt>
</dl></dd>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMObj.serialize">serialize() (FlatCAM.FlatCAMObj method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.set_form_item">set_form_item() (FlatCAM.App method)</a>
</dt>
<dd><dl>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMObj.set_form_item">(FlatCAM.FlatCAMObj method)</a>
</dt>
</dl></dd>
<dt><a href="app.html#FlatCAM.App.set_list_selection">set_list_selection() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.set_progress_bar">set_progress_bar() (FlatCAM.App method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMObj.setup_axes">setup_axes() (FlatCAM.FlatCAMObj method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.setup_component_editor">setup_component_editor() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.setup_obj_classes">setup_obj_classes() (FlatCAM.App method)</a>
</dt>
<dt><a href="app.html#FlatCAM.App.setup_project_list">setup_project_list() (FlatCAM.App method)</a>
</dt>
<dt><a href="camlib.html#camlib.Geometry.size">size() (camlib.Geometry method)</a>
</dt>
@ -399,6 +944,32 @@
<dt><a href="camlib.html#camlib.Geometry.to_dict">to_dict() (camlib.Geometry method)</a>
</dt>
</dl></td>
<td style="width: 33%" valign="top"><dl>
<dt><a href="flatcamobj.html#FlatCAM.FlatCAMObj.to_form">to_form() (FlatCAM.FlatCAMObj method)</a>
</dt>
</dl></td>
</tr></table>
<h2 id="V">V</h2>
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="app.html#FlatCAM.App.versionCheck">versionCheck() (FlatCAM.App method)</a>
</dt>
</dl></td>
</tr></table>
<h2 id="Z">Z</h2>
<table style="width: 100%" class="indextable genindextable"><tr>
<td style="width: 33%" valign="top"><dl>
<dt><a href="app.html#FlatCAM.PlotCanvas.zoom">zoom() (FlatCAM.PlotCanvas method)</a>
</dt>
</dl></td>
</tr></table>

52
doc/build/index.html vendored
View File

@ -80,11 +80,29 @@
<ul>
<li class="toctree-l1"><a class="reference internal" href="camlib.html">Camlib</a></li>
<li class="toctree-l1"><a class="reference internal" href="flatcamobj.html">FlatCAM Objects</a></li>
<li class="toctree-l1"><a class="reference internal" href="camlib.html">Camlib</a><ul>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#geometry">Geometry</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#gerber">Gerber</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#aperturemacro">ApertureMacro</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#excellon">Excellon</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#cncjob">CNCJob</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="flatcamobj.html">FlatCAM Objects</a><ul>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamobj">FlatCAMObj</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamgerber">FlatCAMGerber</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamexcellon">FlatCAMExcellon</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamcncjob">FlatCAMCNCjob</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamgeometry">FlatCAMGeometry</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="app.html">FlatCAM Application</a><ul>
<li class="toctree-l2"><a class="reference internal" href="app.html#options">Options</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#api">API</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#app">App</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#plotcanvas">PlotCanvas</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="devman.html">FlatCAM Developer Manual</a><ul>
<li class="toctree-l2"><a class="reference internal" href="devman.html#options">Options</a></li>
</ul>
</li>
</ul>
@ -126,11 +144,29 @@
<p>Contents:</p>
<div class="toctree-wrapper compound">
<ul>
<li class="toctree-l1"><a class="reference internal" href="camlib.html">Camlib</a></li>
<li class="toctree-l1"><a class="reference internal" href="flatcamobj.html">FlatCAM Objects</a></li>
<li class="toctree-l1"><a class="reference internal" href="camlib.html">Camlib</a><ul>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#geometry">Geometry</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#gerber">Gerber</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#aperturemacro">ApertureMacro</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#excellon">Excellon</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#cncjob">CNCJob</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="flatcamobj.html">FlatCAM Objects</a><ul>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamobj">FlatCAMObj</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamgerber">FlatCAMGerber</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamexcellon">FlatCAMExcellon</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamcncjob">FlatCAMCNCjob</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamgeometry">FlatCAMGeometry</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="app.html">FlatCAM Application</a><ul>
<li class="toctree-l2"><a class="reference internal" href="app.html#options">Options</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#api">API</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#app">App</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#plotcanvas">PlotCanvas</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="devman.html">FlatCAM Developer Manual</a><ul>
<li class="toctree-l2"><a class="reference internal" href="devman.html#options">Options</a></li>
</ul>
</li>
</ul>

BIN
doc/build/objects.inv vendored

Binary file not shown.

View File

@ -86,11 +86,29 @@
<ul>
<li class="toctree-l1"><a class="reference internal" href="camlib.html">Camlib</a></li>
<li class="toctree-l1"><a class="reference internal" href="flatcamobj.html">FlatCAM Objects</a></li>
<li class="toctree-l1"><a class="reference internal" href="camlib.html">Camlib</a><ul>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#geometry">Geometry</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#gerber">Gerber</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#aperturemacro">ApertureMacro</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#excellon">Excellon</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#cncjob">CNCJob</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="flatcamobj.html">FlatCAM Objects</a><ul>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamobj">FlatCAMObj</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamgerber">FlatCAMGerber</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamexcellon">FlatCAMExcellon</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamcncjob">FlatCAMCNCjob</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamgeometry">FlatCAMGeometry</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="app.html">FlatCAM Application</a><ul>
<li class="toctree-l2"><a class="reference internal" href="app.html#options">Options</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#api">API</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#app">App</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#plotcanvas">PlotCanvas</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="devman.html">FlatCAM Developer Manual</a><ul>
<li class="toctree-l2"><a class="reference internal" href="devman.html#options">Options</a></li>
</ul>
</li>
</ul>
@ -129,7 +147,8 @@
<h1>Python Module Index</h1>
<div class="modindex-jumpbox">
<a href="#cap-c"><strong>c</strong></a>
<a href="#cap-c"><strong>c</strong></a> |
<a href="#cap-f"><strong>f</strong></a>
</div>
<table class="indextable modindextable" cellspacing="0" cellpadding="2">
@ -141,6 +160,14 @@
<td>
<a href="camlib.html#module-camlib"><tt class="xref">camlib</tt></a></td><td>
<em></em></td></tr>
<tr class="pcap"><td></td><td>&nbsp;</td><td></td></tr>
<tr class="cap" id="cap-f"><td></td><td>
<strong>f</strong></td><td></td></tr>
<tr>
<td></td>
<td>
<a href="flatcamobj.html#module-FlatCAM"><tt class="xref">FlatCAM</tt></a></td><td>
<em></em></td></tr>
</table>

26
doc/build/search.html vendored
View File

@ -87,11 +87,29 @@
<ul>
<li class="toctree-l1"><a class="reference internal" href="camlib.html">Camlib</a></li>
<li class="toctree-l1"><a class="reference internal" href="flatcamobj.html">FlatCAM Objects</a></li>
<li class="toctree-l1"><a class="reference internal" href="camlib.html">Camlib</a><ul>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#geometry">Geometry</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#gerber">Gerber</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#aperturemacro">ApertureMacro</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#excellon">Excellon</a></li>
<li class="toctree-l2"><a class="reference internal" href="camlib.html#cncjob">CNCJob</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="flatcamobj.html">FlatCAM Objects</a><ul>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamobj">FlatCAMObj</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamgerber">FlatCAMGerber</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamexcellon">FlatCAMExcellon</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamcncjob">FlatCAMCNCjob</a></li>
<li class="toctree-l2"><a class="reference internal" href="flatcamobj.html#flatcamgeometry">FlatCAMGeometry</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="app.html">FlatCAM Application</a><ul>
<li class="toctree-l2"><a class="reference internal" href="app.html#options">Options</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#api">API</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#app">App</a></li>
<li class="toctree-l2"><a class="reference internal" href="app.html#plotcanvas">PlotCanvas</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference internal" href="devman.html">FlatCAM Developer Manual</a><ul>
<li class="toctree-l2"><a class="reference internal" href="devman.html#options">Options</a></li>
</ul>
</li>
</ul>

File diff suppressed because one or more lines are too long

View File

@ -1,26 +1,16 @@
FlatCAM Application
===================
Options
~~~~~~~
There are **Application Defaults**, **Project Options** and **Object Options** in FlatCAM.
**Application Defaults** are stored in ``app.defaults``. This gets populated (updated) from the ``defaults.json`` file upon startup. These can be edited from the Options tab, where each widget calls ``app.on_options_update()`` if a change is detected. This function iterates over the keys of ``app.defaults`` and reads the GUI elements whose name is ``type + "_app_" key``. Therefore, for an option to be recognized, it must be added to ``defaults.json`` in the first place. When saving, done in ``app.on_file_savedefaults()``, the file is updated, not overwritten.
**Project Options** inherit all options from Application Defaults upon startup. They can be changed thereafter from the UI or by opening a project, which contain previously saved Project Options. These are store in ``app.options`` and can be written and read from the Options tab in the same way as with Application defaults.
**Object Options** for each object are inherited from Project Options upon creation of each new object. They can be modified independently from the Project's options thereafter through the UI, where the widget containing the option is identified by name: ``type + kind + "_" + option``. They are stored in ``object.options``. They are saved along the Project options when saving the project.
The syntax of UI widget names contain a ``type``, which identifies what *type of widget* it is and how its value is supposed to be fetched, and a ``kind``, which refer to what *kind of FlatCAM Object* it is for.
API
~~~
.. automodule:: FlatCAM
App
~~~
.. autoclass:: App
:members:
PlotCanvas
~~~~~~~~~~
.. autoclass:: PlotCanvas
:members:

View File

@ -3,14 +3,32 @@ Camlib
.. automodule:: camlib
Geometry
~~~~~~~~
.. autoclass:: Geometry
:members:
Gerber
~~~~~~
.. autoclass:: Gerber(Geometry)
:members:
.. autoclass:: Excellon
ApertureMacro
~~~~~~~~~~~~~
.. autoclass:: ApertureMacro
:members:
.. autoclass:: CNCjob
Excellon
~~~~~~~~
.. autoclass:: Excellon(Geometry)
:members:
CNCJob
~~~~~~
.. autoclass:: CNCjob(Geometry)
:members:

15
doc/source/devman.rst Normal file
View File

@ -0,0 +1,15 @@
FlatCAM Developer Manual
========================
Options
~~~~~~~
There are **Application Defaults**, **Project Options** and **Object Options** in FlatCAM.
**Application Defaults** are stored in ``app.defaults``. This gets populated (updated) from the ``defaults.json`` file upon startup. These can be edited from the Options tab, where each widget calls ``app.on_options_update()`` if a change is detected. This function iterates over the keys of ``app.defaults`` and reads the GUI elements whose name is ``type + "_app_" key``. Therefore, for an option to be recognized, it must be added to ``defaults.json`` in the first place. When saving, done in ``app.on_file_savedefaults()``, the file is updated, not overwritten.
**Project Options** inherit all options from Application Defaults upon startup. They can be changed thereafter from the UI or by opening a project, which contain previously saved Project Options. These are store in ``app.options`` and can be written and read from the Options tab in the same way as with Application defaults.
**Object Options** for each object are inherited from Project Options upon creation of each new object. They can be modified independently from the Project's options thereafter through the UI, where the widget containing the option is identified by name: ``type + kind + "_" + option``. They are stored in ``object.options``. They are saved along the Project options when saving the project.
The syntax of UI widget names contain a ``type``, which identifies what *type of widget* it is and how its value is supposed to be fetched, and a ``kind``, which refer to what *kind of FlatCAM Object* it is for.

View File

@ -3,17 +3,32 @@ FlatCAM Objects
.. automodule:: FlatCAM
FlatCAMObj
~~~~~~~~~~
.. autoclass:: FlatCAMObj
:members:
FlatCAMGerber
~~~~~~~~~~~~~
.. autoclass:: FlatCAMGerber
:members:
FlatCAMExcellon
~~~~~~~~~~~~~~~
.. autoclass:: FlatCAMExcellon
:members:
FlatCAMCNCjob
~~~~~~~~~~~~~
.. autoclass:: FlatCAMCNCjob
:members:
FlatCAMGeometry
~~~~~~~~~~~~~~~
.. autoclass:: FlatCAMGeometry
:members:

View File

@ -16,6 +16,7 @@ Contents:
camlib
flatcamobj
app
devman