- fixing an issue with not building the UI for the generated objects when running a script and then trying to enable/disable the plots
- attempting to add a feature in the text editors to autoselect all words in a document that are the same as the one that was clicked - all the colors set in Preferences now have to be in the 8digits format RGBA (including the alpha channel as a suffix) - it is required to delete the current preferences files
This commit is contained in:
@@ -1219,12 +1219,16 @@ class CNCJobObject(FlatCAMObj, CNCjob):
|
||||
|
||||
self.ui_disconnect()
|
||||
cb_flag = self.ui.plot_cb.isChecked()
|
||||
for row in range(self.ui.cnc_tools_table.rowCount()):
|
||||
table_cb = self.ui.cnc_tools_table.cellWidget(row, 6)
|
||||
if cb_flag:
|
||||
table_cb.setChecked(True)
|
||||
else:
|
||||
table_cb.setChecked(False)
|
||||
try:
|
||||
for row in range(self.ui.cnc_tools_table.rowCount()):
|
||||
table_cb = self.ui.cnc_tools_table.cellWidget(row, 6)
|
||||
if cb_flag:
|
||||
table_cb.setChecked(True)
|
||||
else:
|
||||
table_cb.setChecked(False)
|
||||
except AttributeError:
|
||||
# TODO from Tcl commands - should fix it sometime
|
||||
pass
|
||||
self.ui_connect()
|
||||
|
||||
def on_plot_cb_click_table(self):
|
||||
@@ -1307,13 +1311,14 @@ class CNCJobObject(FlatCAMObj, CNCjob):
|
||||
# we may have a tuple with only one element and a comma
|
||||
dia_plot = [float(el) for el in self.options["tooldia"].split(',') if el != ''][0]
|
||||
else:
|
||||
try:
|
||||
dia_plot = float(self.options["tools_mill_tooldia"])
|
||||
except ValueError:
|
||||
# we may have a tuple with only one element and a comma
|
||||
dia_plot = [
|
||||
float(el) for el in self.options["tools_mill_tooldia"].split(',') if el != ''
|
||||
][0]
|
||||
# try:
|
||||
# dia_plot = float(self.options["tools_mill_tooldia"])
|
||||
# except ValueError:
|
||||
# # we may have a tuple with only one element and a comma
|
||||
# dia_plot = [
|
||||
# float(el) for el in self.options["tools_mill_tooldia"].split(',') if el != ''
|
||||
# ][0]
|
||||
dia_plot = float(self.options["cncjob_tooldia"])
|
||||
|
||||
self.plot2(tooldia=dia_plot, obj=self, visible=visible, kind=kind)
|
||||
else:
|
||||
|
||||
@@ -1584,8 +1584,9 @@ class GeometryObject(FlatCAMObj, Geometry):
|
||||
geo_final.multigeo = True
|
||||
|
||||
try:
|
||||
new_solid_geometry += deepcopy(geo_obj.solid_geometry)
|
||||
new_solid_geometry += deepcopy(geo_obj.solid_geometry.geoms)
|
||||
except Exception as e:
|
||||
new_solid_geometry.append(geo_obj.solid_geometry)
|
||||
log.error("GeometryObject.merge() --> %s" % str(e))
|
||||
|
||||
# find the tool_uid maximum value in the geo_final
|
||||
|
||||
@@ -476,8 +476,8 @@ class ObjectCollection(QtCore.QAbstractItemModel):
|
||||
return index.internalPointer().data(index.column())
|
||||
|
||||
if role == Qt.ItemDataRole.ForegroundRole:
|
||||
color = QColor(self.app.defaults['global_proj_item_color'])
|
||||
color_disabled = QColor(self.app.defaults['global_proj_item_dis_color'])
|
||||
color = QColor(self.app.defaults['global_proj_item_color'][:-2])
|
||||
color_disabled = QColor(self.app.defaults['global_proj_item_dis_color'][:-2])
|
||||
obj = index.internalPointer().obj
|
||||
if obj:
|
||||
return QtGui.QBrush(color) if obj.options["plot"] else QtGui.QBrush(color_disabled)
|
||||
|
||||
Reference in New Issue
Block a user