- fixed bug in Copper Thieving, Corners and Fiducial Plugins which crashed the app when using Disable Plot menu action on the Project Menu objects
- Etch Compensation Plugin - fixed a number of issue; fixed issue #500
This commit is contained in:
@@ -11,6 +11,8 @@ CHANGELOG for FlatCAM beta
|
|||||||
|
|
||||||
- the GCode generation takes now into consideration the Toolchange X-Y parameter as a starting point
|
- the GCode generation takes now into consideration the Toolchange X-Y parameter as a starting point
|
||||||
- Milling Plugin - work on it; upgraded the form-to-data_storage methods
|
- Milling Plugin - work on it; upgraded the form-to-data_storage methods
|
||||||
|
- fixed bug in Copper Thieving, Corners and Fiducial Plugins which crashed the app when using Disable Plot menu action on the Project Menu objects
|
||||||
|
- Etch Compensation Plugin - fixed a number of issue; fixed issue #500
|
||||||
|
|
||||||
14.03.2021
|
14.03.2021
|
||||||
|
|
||||||
|
|||||||
@@ -14,6 +14,7 @@ from appEditors.AppGeoEditor import FCShapeTool, DrawTool, DrawToolShape, DrawTo
|
|||||||
|
|
||||||
from shapely.geometry import LineString, LinearRing, MultiLineString, Polygon, MultiPolygon, Point
|
from shapely.geometry import LineString, LinearRing, MultiLineString, Polygon, MultiPolygon, Point
|
||||||
import shapely.affinity as affinity
|
import shapely.affinity as affinity
|
||||||
|
from appCommon.Common import LoudDict
|
||||||
|
|
||||||
import numpy as np
|
import numpy as np
|
||||||
|
|
||||||
|
|||||||
@@ -10,6 +10,7 @@ from PyQt5 import QtWidgets, QtCore, QtGui
|
|||||||
from camlib import grace
|
from camlib import grace
|
||||||
from appTool import AppTool
|
from appTool import AppTool
|
||||||
from appGUI.GUIElements import FCDoubleSpinner, RadioSet, FCEntry, FCComboBox, FCLabel, FCCheckBox
|
from appGUI.GUIElements import FCDoubleSpinner, RadioSet, FCEntry, FCComboBox, FCLabel, FCCheckBox
|
||||||
|
from appCommon.Common import LoudDict
|
||||||
|
|
||||||
import shapely.geometry.base as base
|
import shapely.geometry.base as base
|
||||||
from shapely.ops import unary_union
|
from shapely.ops import unary_union
|
||||||
@@ -301,7 +302,7 @@ class ToolCopperThieving(AppTool):
|
|||||||
outname = '%s_%s' % (str(self.grb_object.options['name']), 'robber')
|
outname = '%s_%s' % (str(self.grb_object.options['name']), 'robber')
|
||||||
|
|
||||||
def initialize(grb_obj, app_obj):
|
def initialize(grb_obj, app_obj):
|
||||||
grb_obj.options = {}
|
grb_obj.options = LoudDict()
|
||||||
for opt in self.grb_object.options:
|
for opt in self.grb_object.options:
|
||||||
if opt != 'name':
|
if opt != 'name':
|
||||||
grb_obj.options[opt] = deepcopy(self.grb_object.options[opt])
|
grb_obj.options[opt] = deepcopy(self.grb_object.options[opt])
|
||||||
@@ -902,7 +903,7 @@ class ToolCopperThieving(AppTool):
|
|||||||
outname = '%s_%s' % (str(self.grb_object.options['name']), 'thief')
|
outname = '%s_%s' % (str(self.grb_object.options['name']), 'thief')
|
||||||
|
|
||||||
def initialize(grb_obj, app_obj):
|
def initialize(grb_obj, app_obj):
|
||||||
grb_obj.options = {}
|
grb_obj.options = LoudDict()
|
||||||
for opt in self.grb_object.options:
|
for opt in self.grb_object.options:
|
||||||
if opt != 'name':
|
if opt != 'name':
|
||||||
grb_obj.options[opt] = deepcopy(self.grb_object.options[opt])
|
grb_obj.options[opt] = deepcopy(self.grb_object.options[opt])
|
||||||
@@ -1109,7 +1110,7 @@ class ToolCopperThieving(AppTool):
|
|||||||
new_solid_geometry = MultiPolygon(geo_list).buffer(0.0000001).buffer(-0.0000001)
|
new_solid_geometry = MultiPolygon(geo_list).buffer(0.0000001).buffer(-0.0000001)
|
||||||
|
|
||||||
def obj_init(grb_obj, app_obj):
|
def obj_init(grb_obj, app_obj):
|
||||||
grb_obj.options = {}
|
grb_obj.options = LoudDict()
|
||||||
for opt in self.sm_object.options:
|
for opt in self.sm_object.options:
|
||||||
if opt != 'name':
|
if opt != 'name':
|
||||||
grb_obj.options[opt] = deepcopy(self.sm_object.options[opt])
|
grb_obj.options[opt] = deepcopy(self.sm_object.options[opt])
|
||||||
|
|||||||
@@ -8,8 +8,8 @@
|
|||||||
from PyQt5 import QtWidgets, QtCore, QtGui
|
from PyQt5 import QtWidgets, QtCore, QtGui
|
||||||
|
|
||||||
from appTool import AppTool
|
from appTool import AppTool
|
||||||
|
from appCommon.Common import LoudDict
|
||||||
from appGUI.GUIElements import FCDoubleSpinner, FCCheckBox, FCComboBox, FCButton, RadioSet, FCLabel
|
from appGUI.GUIElements import FCDoubleSpinner, FCCheckBox, FCComboBox, FCButton, RadioSet, FCLabel
|
||||||
|
|
||||||
from shapely.geometry import MultiPolygon, LineString, Point
|
from shapely.geometry import MultiPolygon, LineString, Point
|
||||||
from shapely.ops import unary_union
|
from shapely.ops import unary_union
|
||||||
|
|
||||||
@@ -383,7 +383,7 @@ class ToolCorners(AppTool):
|
|||||||
outname = '%s_%s' % (str(self.grb_object.options['name']), 'corners')
|
outname = '%s_%s' % (str(self.grb_object.options['name']), 'corners')
|
||||||
|
|
||||||
def initialize(grb_obj, app_obj):
|
def initialize(grb_obj, app_obj):
|
||||||
grb_obj.options = {}
|
grb_obj.options = LoudDict()
|
||||||
for opt in g_obj.options:
|
for opt in g_obj.options:
|
||||||
if opt != 'name':
|
if opt != 'name':
|
||||||
grb_obj.options[opt] = deepcopy(g_obj.options[opt])
|
grb_obj.options[opt] = deepcopy(g_obj.options[opt])
|
||||||
|
|||||||
@@ -177,7 +177,11 @@ class ToolEtchCompensation(AppTool):
|
|||||||
return
|
return
|
||||||
|
|
||||||
if ratio_type == 'factor':
|
if ratio_type == 'factor':
|
||||||
etch_factor = 1 / self.ui.factor_entry.get_value()
|
factor_value = self.ui.factor_entry.get_value()
|
||||||
|
if factor_value is None:
|
||||||
|
self.app.inform.emit('[ERROR_NOTCL] %s' % _("Missing parameter value."))
|
||||||
|
return
|
||||||
|
etch_factor = 1 / factor_value
|
||||||
offset = thickness / etch_factor
|
offset = thickness / etch_factor
|
||||||
elif ratio_type == 'etch_list':
|
elif ratio_type == 'etch_list':
|
||||||
etchant = self.ui.etchants_combo.get_value()
|
etchant = self.ui.etchants_combo.get_value()
|
||||||
@@ -187,12 +191,20 @@ class ToolEtchCompensation(AppTool):
|
|||||||
etch_factor = 0.25
|
etch_factor = 0.25
|
||||||
offset = thickness / etch_factor
|
offset = thickness / etch_factor
|
||||||
else:
|
else:
|
||||||
offset = self.ui.offset_entry.get_value() / 1000 # in microns
|
offset_value = self.ui.offset_entry.get_value()
|
||||||
|
if offset_value is None:
|
||||||
|
self.app.inform.emit('[ERROR_NOTCL] %s' % _("Missing parameter value."))
|
||||||
|
return
|
||||||
|
offset = offset_value / 1000 # in microns
|
||||||
|
|
||||||
|
if offset == 0:
|
||||||
|
# no need to do anything for zero value offset isn't it? compensating with zero is the same as the original
|
||||||
|
return
|
||||||
|
|
||||||
try:
|
try:
|
||||||
__ = iter(grb_obj.solid_geometry)
|
__ = iter(grb_obj.solid_geometry)
|
||||||
except TypeError:
|
except TypeError:
|
||||||
grb_obj.solid_geometry = list(grb_obj.solid_geometry)
|
grb_obj.solid_geometry = [grb_obj.solid_geometry]
|
||||||
|
|
||||||
new_solid_geometry = []
|
new_solid_geometry = []
|
||||||
|
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ from PyQt5 import QtWidgets, QtCore, QtGui
|
|||||||
|
|
||||||
from appTool import AppTool
|
from appTool import AppTool
|
||||||
from appGUI.GUIElements import FCDoubleSpinner, RadioSet, EvalEntry, FCTable, FCComboBox, FCButton, FCLabel
|
from appGUI.GUIElements import FCDoubleSpinner, RadioSet, EvalEntry, FCTable, FCComboBox, FCButton, FCLabel
|
||||||
|
from appCommon.Common import LoudDict
|
||||||
|
|
||||||
from shapely.geometry import Point, Polygon, MultiPolygon, LineString
|
from shapely.geometry import Point, Polygon, MultiPolygon, LineString
|
||||||
from shapely.geometry import box as box
|
from shapely.geometry import box as box
|
||||||
@@ -519,7 +520,7 @@ class ToolFiducials(AppTool):
|
|||||||
outname = '%s_%s' % (str(g_obj.options['name']), 'fid')
|
outname = '%s_%s' % (str(g_obj.options['name']), 'fid')
|
||||||
|
|
||||||
def initialize(grb_obj, app_obj):
|
def initialize(grb_obj, app_obj):
|
||||||
grb_obj.options = {}
|
grb_obj.options = LoudDict()
|
||||||
for opt in g_obj.options:
|
for opt in g_obj.options:
|
||||||
if opt != 'name':
|
if opt != 'name':
|
||||||
grb_obj.options[opt] = deepcopy(g_obj.options[opt])
|
grb_obj.options[opt] = deepcopy(g_obj.options[opt])
|
||||||
|
|||||||
Reference in New Issue
Block a user