diff --git a/src/Mod/Path/Gui/Resources/panels/PathEdit.ui b/src/Mod/Path/Gui/Resources/panels/PathEdit.ui index b12c7dda9f..1a57ae079b 100644 --- a/src/Mod/Path/Gui/Resources/panels/PathEdit.ui +++ b/src/Mod/Path/Gui/Resources/panels/PathEdit.ui @@ -14,7 +14,7 @@ Job Edit - 0 + 2 @@ -146,30 +146,49 @@ 0 - - - 2 - - - - Create Box - - - - - Create Cylinder - - - - - Extend Model's Bound Box - - - - - Use Existing Solid - - + + + + + + + 0 + 0 + + + + 2 + + + + Create Box + + + + + Create Cylinder + + + + + Extend Model's Bound Box + + + + + Use Existing Solid + + + + + + + + New + + + + @@ -632,7 +651,6 @@ postProcessorSetOutputFile postProcessor postProcessorArguments - stock stockExisting stockExtXneg stockExtXpos diff --git a/src/Mod/Path/PathScripts/PathJobGui.py b/src/Mod/Path/PathScripts/PathJobGui.py index 3864018858..4b67900da4 100644 --- a/src/Mod/Path/PathScripts/PathJobGui.py +++ b/src/Mod/Path/PathScripts/PathJobGui.py @@ -900,6 +900,9 @@ class TaskPanel: PathLog.error(translate('PathJob', "Unsupported stock type %s (%d)") % (self.form.stock.currentText(), index)) self.stockEdit.activate(self.obj, index == -1) + def updateStock(self): + self.updateStockEditor(self.form.stock.currentIndex()) + def centerInStock(self): bbb = self.obj.Base.Shape.BoundBox bbs = self.obj.Stock.Shape.BoundBox @@ -982,6 +985,7 @@ class TaskPanel: self.form.centerInStockXY.clicked.connect(self.centerInStockXY) self.form.stock.currentIndexChanged.connect(self.updateStockEditor) + self.form.updateStock.clicked.connect(self.updateStock) self.form.orientXAxis.clicked.connect(lambda: self.orientSelected(FreeCAD.Vector(1, 0, 0))) self.form.orientYAxis.clicked.connect(lambda: self.orientSelected(FreeCAD.Vector(0, 1, 0))) diff --git a/src/Mod/Path/PathScripts/PathStock.py b/src/Mod/Path/PathScripts/PathStock.py index 9d187ad13c..dd0fb10ef4 100644 --- a/src/Mod/Path/PathScripts/PathStock.py +++ b/src/Mod/Path/PathScripts/PathStock.py @@ -31,9 +31,11 @@ import math from PySide import QtCore -if True: +if False: PathLog.setLevel(PathLog.Level.DEBUG, PathLog.thisModule()) PathLog.trackModule(PathLog.thisModule()) +else: + PathLog.setLevel(PathLog.Level.INFO, PathLog.thisModule()) # Qt tanslation handling def translate(context, text, disambig=None):