From af091c7b142d614dccfc2b318c12c063277233e0 Mon Sep 17 00:00:00 2001 From: Marius Stanciu Date: Sat, 11 May 2019 04:54:05 +0300 Subject: [PATCH] - made the Feedrate Rapids parameter to depend on the type of postprocessor choosed. It will be showed only for a postprocessor which the name contain 'marlin' and for any postprocessor's that have 'custom' in the name --- FlatCAMObj.py | 14 ++++++++++++++ README.md | 3 ++- flatcamGUI/ObjectUI.py | 6 ++++++ 3 files changed, 22 insertions(+), 1 deletion(-) diff --git a/FlatCAMObj.py b/FlatCAMObj.py index dfd83612..0316d921 100644 --- a/FlatCAMObj.py +++ b/FlatCAMObj.py @@ -2448,6 +2448,13 @@ class FlatCAMExcellon(FlatCAMObj, Excellon): self.ui.feedrate_probe_entry.setVisible(False) self.ui.feedrate_probe_label.hide() + if 'marlin' in current_pp.lower() or 'custom' in current_pp.lower(): + self.ui.feedrate_rapid_label.show() + self.ui.feedrate_rapid_entry.show() + else: + self.ui.feedrate_rapid_label.hide() + self.ui.feedrate_rapid_entry.hide() + def on_create_cncjob_button_click(self, *args): self.app.report_usage("excellon_on_create_cncjob_button") self.read_form() @@ -4092,6 +4099,13 @@ class FlatCAMGeometry(FlatCAMObj, Geometry): self.ui.feedrate_probe_entry.setVisible(False) self.ui.feedrate_probe_label.hide() + if 'marlin' in current_pp.lower() or 'custom' in current_pp.lower(): + self.ui.fr_rapidlabel.show() + self.ui.cncfeedrate_rapid_entry.show() + else: + self.ui.fr_rapidlabel.hide() + self.ui.cncfeedrate_rapid_entry.hide() + def on_generatecnc_button_click(self, *args): self.app.report_usage("geometry_on_generatecnc_button") diff --git a/README.md b/README.md index 40a60b8c..b14ebefb 100644 --- a/README.md +++ b/README.md @@ -12,6 +12,7 @@ CAD program, and create G-Code for Isolation routing. 11.05.2019 - fixed issue in camlib.CNCjob.generate_from_excellon_by_tool() in the drill path optimization algorithm selection when selecting the MH algorithm. The new API's for Google OR-tools required some changes and also the time parameter can be now just an integer therefore I modified the GUI +- made the Feedrate Rapids parameter to depend on the type of postprocessor choosed. It will be showed only for a postprocessor which the name contain 'marlin' and for any postprocessor's that have 'custom' in the name 10.05.2019 @@ -21,7 +22,7 @@ CAD program, and create G-Code for Isolation routing. 9.05.2019 -- rework the Gerber parser +- reworked the Gerber parser 8.05.2019 diff --git a/flatcamGUI/ObjectUI.py b/flatcamGUI/ObjectUI.py index 4bf18386..84fd1986 100644 --- a/flatcamGUI/ObjectUI.py +++ b/flatcamGUI/ObjectUI.py @@ -674,6 +674,9 @@ class ExcellonObjectUI(ObjectUI): grid1.addWidget(self.feedrate_rapid_label, 7, 0) self.feedrate_rapid_entry = LengthEntry() grid1.addWidget(self.feedrate_rapid_entry, 7, 1) + # default values is to hide + self.feedrate_rapid_label.hide() + self.feedrate_rapid_entry.hide() # Spindlespeed spdlabel = QtWidgets.QLabel(_('Spindle speed:')) @@ -1188,6 +1191,9 @@ class GeometryObjectUI(ObjectUI): self.grid3.addWidget(self.fr_rapidlabel, 12, 0) self.cncfeedrate_rapid_entry = LengthEntry() self.grid3.addWidget(self.cncfeedrate_rapid_entry, 12, 1) + # default values is to hide + self.fr_rapidlabel.hide() + self.cncfeedrate_rapid_entry.hide() # Cut over 1st point in path self.extracut_cb = FCCheckBox(_('Cut over 1st pt'))