- made sure that if using an negative Gerber isolation diameter, the resulting Geometry object will use a tool with positive diameter

- fixed bug that when isolating a Gerber file made out of a single polygon, an Recurrsion Exception was issued together with inability to create tbe isolation
This commit is contained in:
Marius Stanciu
2019-08-05 01:02:19 +03:00
parent 8a17575525
commit afdff59aff
3 changed files with 20 additions and 5 deletions

View File

@@ -841,7 +841,6 @@ class FlatCAMGerber(FlatCAMObj, Gerber):
:param outname: Base name of the output object
:return: None
"""
if dia is None:
dia = float(self.options["isotooldia"])
if passes is None:
@@ -872,7 +871,7 @@ class FlatCAMGerber(FlatCAMObj, Gerber):
try:
geom = self.isolation_geometry(offset, iso_type=envelope_iso_type, follow=follow)
except Exception as e:
log.debug(str(e))
log.debug('FlatCAMGerber.isolate().generate_envelope() --> %s' % str(e))
return 'fail'
if invert:
@@ -890,6 +889,9 @@ class FlatCAMGerber(FlatCAMObj, Gerber):
log.debug("FlatCAMGerber.isolate().generate_envelope() Error --> %s" % str(e))
return geom
if float(self.options["isotooldia"]) < 0:
self.options["isotooldia"] = -self.options["isotooldia"]
if combine:
if self.iso_type == 0:
iso_name = self.options["name"] + "_ext_iso"