diff --git a/FlatCAMGUI.py b/FlatCAMGUI.py index 61c1ac36..57b07c5f 100644 --- a/FlatCAMGUI.py +++ b/FlatCAMGUI.py @@ -1521,14 +1521,16 @@ class ExcellonPrefGroupUI(OptionsGroupUI): grid1 = QtWidgets.QGridLayout() self.layout.addLayout(grid1) + self.plot_cb = FCCheckBox(label='Plot') self.plot_cb.setToolTip( "Plot (show) this object." ) grid1.addWidget(self.plot_cb, 0, 0) + self.solid_cb = FCCheckBox(label='Solid') self.solid_cb.setToolTip( - "Solid circles." + "Plot as solid circles." ) grid1.addWidget(self.solid_cb, 0, 1) @@ -1560,7 +1562,7 @@ class ExcellonPrefGroupUI(OptionsGroupUI): hlay1 = QtWidgets.QHBoxLayout() self.layout.addLayout(hlay1) - self.excellon_format_in_label = QtWidgets.QLabel("INCH") + self.excellon_format_in_label = QtWidgets.QLabel("INCH:") self.excellon_format_in_label.setAlignment(QtCore.Qt.AlignLeft) self.excellon_format_in_label.setToolTip( "Default values for INCH are 2:4") @@ -1593,7 +1595,7 @@ class ExcellonPrefGroupUI(OptionsGroupUI): hlay2 = QtWidgets.QHBoxLayout() self.layout.addLayout(hlay2) - self.excellon_format_mm_label = QtWidgets.QLabel("METRIC") + self.excellon_format_mm_label = QtWidgets.QLabel("METRIC:") self.excellon_format_mm_label.setAlignment(QtCore.Qt.AlignLeft) self.excellon_format_mm_label.setToolTip( "Default values for METRIC are 3:3") @@ -1627,10 +1629,10 @@ class ExcellonPrefGroupUI(OptionsGroupUI): hlay3 = QtWidgets.QHBoxLayout() self.layout.addLayout(hlay3) - self.excellon_zeros_label = QtWidgets.QLabel('Excellon Zeros Type:') + self.excellon_zeros_label = QtWidgets.QLabel('Default Zeros Type:') self.excellon_zeros_label.setAlignment(QtCore.Qt.AlignLeft) self.excellon_zeros_label.setToolTip( - "This sets the type of excellon zeros.\n" + "This sets the type of Excellon zeros.\n" "If LZ then Leading Zeros are kept and\n" "Trailing Zeros are removed.\n" "If TZ is checked then Trailing Zeros are kept\n" @@ -1641,7 +1643,9 @@ class ExcellonPrefGroupUI(OptionsGroupUI): self.excellon_zeros_radio = RadioSet([{'label': 'LZ', 'value': 'L'}, {'label': 'TZ', 'value': 'T'}]) self.excellon_zeros_radio.setToolTip( - "This sets the type of excellon zeros.\n" + "This sets the default type of Excellon zeros.\n" + "If it is not detected in the parsed file the value here\n" + "will be used." "If LZ then Leading Zeros are kept and\n" "Trailing Zeros are removed.\n" "If TZ is checked then Trailing Zeros are kept\n" @@ -1653,10 +1657,12 @@ class ExcellonPrefGroupUI(OptionsGroupUI): hlay4 = QtWidgets.QHBoxLayout() self.layout.addLayout(hlay4) - self.excellon_units_label = QtWidgets.QLabel('Excellon Units Type:') + self.excellon_units_label = QtWidgets.QLabel('Default Units Type:') self.excellon_units_label.setAlignment(QtCore.Qt.AlignLeft) self.excellon_units_label.setToolTip( - "This sets the units of Excellon files.\n" + "This sets the default units of Excellon files.\n" + "If it is not detected in the parsed file the value here\n" + "will be used." "Some Excellon files don't have an header\n" "therefore this parameter will be used.\n" ) @@ -1790,13 +1796,14 @@ class ExcellonPrefGroupUI(OptionsGroupUI): endzlabel = QtWidgets.QLabel('End move Z:') endzlabel.setToolTip( - "Tool Z where user can change drill bit." + "Height of the tool after\n" + "the last move at the end of the job." ) grid2.addWidget(endzlabel, 6, 0) self.eendz_entry = LengthEntry() grid2.addWidget(self.eendz_entry, 6, 1) - frlabel = QtWidgets.QLabel('Feedrate (Plunge):') + frlabel = QtWidgets.QLabel('Feedrate:') frlabel.setToolTip( "Tool speed while drilling\n" "(in units per minute)." @@ -1845,7 +1852,7 @@ class ExcellonPrefGroupUI(OptionsGroupUI): self.ois_dwell_exc = OptionalInputSection(self.dwell_cb, [self.dwelltime_entry]) # postprocessor selection - pp_excellon_label = QtWidgets.QLabel("Postprocessor") + pp_excellon_label = QtWidgets.QLabel("Postprocessor:") pp_excellon_label.setToolTip( "The postprocessor file that dictates\n" "gcode output." @@ -1992,7 +1999,10 @@ class GeometryPrefGroupUI(OptionsGroupUI): dplabel = QtWidgets.QLabel('Depth/Pass:') dplabel.setToolTip( "The depth to cut on each pass,\n" - "when multidepth is enabled." + "when multidepth is enabled.\n" + "It has positive value although\n" + "it is a fraction from the depth\n" + "which has negative value." ) grid2.addWidget(dplabel, 2, 0) @@ -2042,8 +2052,7 @@ class GeometryPrefGroupUI(OptionsGroupUI): # Start move Z startzlabel = QtWidgets.QLabel('Start move Z:') startzlabel.setToolTip( - "Height of the tool just\n" - "after starting the work.\n" + "Height of the tool just after starting the work.\n" "Delete the value if you don't need this feature." ) grid2.addWidget(startzlabel, 7, 0) @@ -2054,7 +2063,7 @@ class GeometryPrefGroupUI(OptionsGroupUI): endzlabel = QtWidgets.QLabel('End move Z:') endzlabel.setToolTip( "Height of the tool after\n" - " the last move." + "the last move at the end of the job." ) grid2.addWidget(endzlabel, 8, 0) self.gendz_entry = LengthEntry() @@ -2071,10 +2080,11 @@ class GeometryPrefGroupUI(OptionsGroupUI): grid2.addWidget(self.cncfeedrate_entry, 9, 1) # Feedrate Z (Plunge) - frz_label = QtWidgets.QLabel('Feed Rate Z (Plunge):') + frz_label = QtWidgets.QLabel('Feed Rate Z:') frz_label.setToolTip( "Cutting speed in the XY\n" - "plane in units per minute" + "plane in units per minute.\n" + "It is called also Plunge." ) grid2.addWidget(frz_label, 10, 0) self.cncplunge_entry = LengthEntry() @@ -2125,21 +2135,18 @@ class GeometryPrefGroupUI(OptionsGroupUI): grid2.addWidget(dwelltime, 15, 0) grid2.addWidget(self.dwelltime_entry, 15, 1) - grid3 = QtWidgets.QGridLayout() - self.layout.addLayout(grid3) - self.ois_dwell = OptionalInputSection(self.dwell_cb, [self.dwelltime_entry]) # postprocessor selection - pp_label = QtWidgets.QLabel("Postprocessor") + pp_label = QtWidgets.QLabel("Postprocessor:") pp_label.setToolTip( "The postprocessor file that dictates\n" - "gcode output." + "Machine Code output." ) - grid3.addWidget(pp_label) + grid2.addWidget(pp_label, 16, 0) self.pp_geometry_name_cb = FCComboBox() self.pp_geometry_name_cb.setFocusPolicy(Qt.StrongFocus) - grid3.addWidget(self.pp_geometry_name_cb) + grid2.addWidget(self.pp_geometry_name_cb, 16, 1) # ------------------------------ ## Paint area diff --git a/FlatCAMObj.py b/FlatCAMObj.py index a3c04d86..381f1a8e 100644 --- a/FlatCAMObj.py +++ b/FlatCAMObj.py @@ -1017,6 +1017,8 @@ class FlatCAMExcellon(FlatCAMObj, Excellon): # add a last row with the Total number of drills empty = QtWidgets.QTableWidgetItem('') empty.setFlags(~QtCore.Qt.ItemIsSelectable | QtCore.Qt.ItemIsEnabled) + empty_1 = QtWidgets.QTableWidgetItem('') + empty_1.setFlags(~QtCore.Qt.ItemIsSelectable | QtCore.Qt.ItemIsEnabled) label_tot_drill_count = QtWidgets.QTableWidgetItem('Total Drills') tot_drill_count = QtWidgets.QTableWidgetItem('%d' % self.tot_drill_cnt) @@ -1026,6 +1028,7 @@ class FlatCAMExcellon(FlatCAMObj, Excellon): self.ui.tools_table.setItem(self.tool_row, 0, empty) self.ui.tools_table.setItem(self.tool_row, 1, label_tot_drill_count) self.ui.tools_table.setItem(self.tool_row, 2, tot_drill_count) # Total number of drills + self.ui.tools_table.setItem(self.tool_row, 3, empty_1) # Total number of drills font = QtGui.QFont() font.setBold(True) @@ -1058,7 +1061,7 @@ class FlatCAMExcellon(FlatCAMObj, Excellon): self.ui.tools_table.item(self.tool_row, kl).setForeground(QtGui.QColor(0, 70, 255)) # sort the tool diameter column - self.ui.tools_table.sortItems(1) + # self.ui.tools_table.sortItems(1) # all the tools are selected by default self.ui.tools_table.selectColumn(0) # @@ -1077,7 +1080,7 @@ class FlatCAMExcellon(FlatCAMObj, Excellon): horizontal_header.setSectionResizeMode(3, QtWidgets.QHeaderView.ResizeToContents) # horizontal_header.setStretchLastSection(True) - self.ui.tools_table.setSortingEnabled(True) + self.ui.tools_table.setSortingEnabled(False) self.ui.tools_table.setMinimumHeight(self.ui.tools_table.getHeight()) self.ui.tools_table.setMaximumHeight(self.ui.tools_table.getHeight()) @@ -3644,6 +3647,14 @@ class FlatCAMCNCjob(FlatCAMObj, CNCjob): FlatCAMObj.build_ui(self) + # if the FlatCAM object is Excellon don't build the CNC Tools Table but hide it + if self.cnc_tools: + self.ui.cnc_tools_table.show() + self.ui.plot_options_label.show() + else: + self.ui.cnc_tools_table.hide() + self.ui.plot_options_label.hide() + offset = 0 tool_idx = 0 diff --git a/ObjectUI.py b/ObjectUI.py index 6adc8426..e8ad7bc9 100644 --- a/ObjectUI.py +++ b/ObjectUI.py @@ -421,6 +421,20 @@ class ExcellonObjectUI(ObjectUI): self.tools_table.setHorizontalHeaderLabels(['#', 'Diameter', 'D', 'S']) self.tools_table.setSortingEnabled(False) + self.tools_table.horizontalHeaderItem(0).setToolTip( + "This is the Tool Number.\n" + "When ToolChange is checked, on toolchange event this value\n" + "will be showed as a T1, T2 ... Tn in the Machine Code.") + self.tools_table.horizontalHeaderItem(1).setToolTip( + "Tool Diameter. It's value (in current FlatCAM units) \n" + "is the cut width into the material.") + self.tools_table.horizontalHeaderItem(2).setToolTip( + "The number of Drill holes. Holes that are drilled with\n" + "a drill bit.") + self.tools_table.horizontalHeaderItem(3).setToolTip( + "The number of Slot holes. Holes that are created by\n" + "milling them with an endmill bit.") + self.empty_label = QtWidgets.QLabel('') self.tools_box.addWidget(self.empty_label) diff --git a/README.md b/README.md index 27254b4f..267e1d56 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,14 @@ CAD program, and create G-Code for Isolation routing. ================================================= +21.01.2019 + +- changed some tooltips +- added tooltips in Excellon tool table headers +- in Excellon Tool Table the columns are now only selectable by clicking on the header (sorting is done automatically) +- if CNCJob from Excellon then hide the CNC tools table in CNCJob Object + + 20.01.2019 - fixed the HPGL code geometry rendering when travel