- Copper Thieving Tool - updated the way plated area is calculated making it a bit more precise but still it is a bit bigger than the actual area
This commit is contained in:
parent
92ea7e83be
commit
9b48db7f54
@ -16,9 +16,10 @@ CAD program, and create G-Code for Isolation routing.
|
||||
- fixed bug in FCSpinner and FCDoubleSpinner GUI elements, that are now the main GUI element in FlatCAM, that made partial selection difficult
|
||||
- updated the Paint Tool in Geometry Editor to use the FCDoublepinbox
|
||||
- added the possibility for suffix presence on the FCSpinner and FCDoubleSpinner GUI Elements
|
||||
- added the '%' symbol for overlap fields; I still need to divide the conntet by 100 to get the original decimal
|
||||
- added the '%' symbol for overlap fields; I still need to divide the content by 100 to get the original (0 ... 1) value
|
||||
- fixed the overlap parameter all over the app to reflect the change to percentage
|
||||
- in Copper Thieving Tool added the display of the patterned plated area (approximative area)
|
||||
- Copper Thieving Tool - updated the way plated area is calculated making it a bit more precise but still it is a bit bigger than the actual area
|
||||
|
||||
3.12.2019
|
||||
|
||||
|
@ -429,7 +429,11 @@ class ToolCopperThieving(FlatCAMTool):
|
||||
self.plated_area_label = QtWidgets.QLabel('%s:' % _("Plated area"))
|
||||
self.plated_area_label.setToolTip(
|
||||
_("The area to be plated by pattern plating.\n"
|
||||
"Basically is made from the openings in the plating mask.")
|
||||
"Basically is made from the openings in the plating mask.\n\n"
|
||||
"<<WARNING>> - the calculated area is actually a bit larger\n"
|
||||
"due of the fact that the soldermask openings are by design\n"
|
||||
"a bit larger than the copper pads, and this area is\n"
|
||||
"calculated from the soldermask openings.")
|
||||
)
|
||||
self.plated_area_entry = FCEntry()
|
||||
self.plated_area_entry.setDisabled(True)
|
||||
@ -1294,6 +1298,17 @@ class ToolCopperThieving(FlatCAMTool):
|
||||
if isinstance(app_obj.sm_object.solid_geometry, MultiPolygon):
|
||||
geo_list = list(app_obj.sm_object.solid_geometry.geoms)
|
||||
|
||||
plated_area = 0.0
|
||||
for geo in geo_list:
|
||||
plated_area += geo.area
|
||||
|
||||
if app_obj.new_solid_geometry:
|
||||
for geo in app_obj.new_solid_geometry:
|
||||
plated_area += geo.area
|
||||
if app_obj.robber_geo:
|
||||
plated_area += app_obj.robber_geo.area
|
||||
self.plated_area_entry.set_value(plated_area)
|
||||
|
||||
# if we have copper thieving geometry, add it
|
||||
if app_obj.new_solid_geometry:
|
||||
if '0' not in app_obj.sm_object.apertures:
|
||||
@ -1357,11 +1372,6 @@ class ToolCopperThieving(FlatCAMTool):
|
||||
|
||||
geo_list.append(app_obj.robber_geo.buffer(ppm_clearance))
|
||||
|
||||
plated_area = 0.0
|
||||
for geo in geo_list:
|
||||
plated_area += geo.area
|
||||
self.plated_area_entry.set_value(plated_area)
|
||||
|
||||
app_obj.sm_object.solid_geometry = MultiPolygon(geo_list).buffer(0.0000001).buffer(-0.0000001)
|
||||
|
||||
app_obj.app.proc_container.update_view_text(' %s' % _("Append source file"))
|
||||
|
Loading…
Reference in New Issue
Block a user