From eb608e818e27c240be8c6287ad6945e37b2b6759 Mon Sep 17 00:00:00 2001 From: sliptonic Date: Mon, 20 Mar 2017 15:17:27 -0500 Subject: [PATCH] Path: small bugs. remove deprecated setting of first rapid. minor fixup to smoothiepost to set ip address in post arguments --- src/Mod/Path/PathScripts/PathComment.py | 2 -- src/Mod/Path/PathScripts/PathFixture.py | 2 -- src/Mod/Path/PathScripts/PathInspect.py | 1 - src/Mod/Path/PathScripts/PathLoadTool.py | 2 -- src/Mod/Path/PathScripts/PathPlane.py | 2 -- src/Mod/Path/PathScripts/PathStop.py | 2 -- src/Mod/Path/PathScripts/PathToolLenOffset.py | 3 --- src/Mod/Path/PathScripts/smoothie_post.py | 4 ++-- 8 files changed, 2 insertions(+), 16 deletions(-) diff --git a/src/Mod/Path/PathScripts/PathComment.py b/src/Mod/Path/PathScripts/PathComment.py index de04866732..37878e8739 100644 --- a/src/Mod/Path/PathScripts/PathComment.py +++ b/src/Mod/Path/PathScripts/PathComment.py @@ -72,7 +72,6 @@ class _ViewProviderComment: vobj.setEditorMode('LineWidth', mode) vobj.setEditorMode('MarkerColor', mode) vobj.setEditorMode('NormalColor', mode) - vobj.setEditorMode('ShowFirstRapid', mode) vobj.setEditorMode('DisplayMode', mode) vobj.setEditorMode('BoundingBox', mode) vobj.setEditorMode('Selectable', mode) @@ -94,7 +93,6 @@ class _ViewProviderComment: vobj.setEditorMode('LineWidth', mode) vobj.setEditorMode('MarkerColor', mode) vobj.setEditorMode('NormalColor', mode) - vobj.setEditorMode('ShowFirstRapid', mode) vobj.setEditorMode('DisplayMode', mode) vobj.setEditorMode('BoundingBox', mode) vobj.setEditorMode('Selectable', mode) diff --git a/src/Mod/Path/PathScripts/PathFixture.py b/src/Mod/Path/PathScripts/PathFixture.py index 92364d56ee..d5ae6452d4 100644 --- a/src/Mod/Path/PathScripts/PathFixture.py +++ b/src/Mod/Path/PathScripts/PathFixture.py @@ -69,7 +69,6 @@ class _ViewProviderFixture: vobj.setEditorMode('LineWidth', mode) vobj.setEditorMode('MarkerColor', mode) vobj.setEditorMode('NormalColor', mode) - vobj.setEditorMode('ShowFirstRapid', mode) vobj.setEditorMode('DisplayMode', mode) vobj.setEditorMode('BoundingBox', mode) vobj.setEditorMode('Selectable', mode) @@ -95,7 +94,6 @@ class _ViewProviderFixture: vobj.setEditorMode('LineWidth', mode) vobj.setEditorMode('MarkerColor', mode) vobj.setEditorMode('NormalColor', mode) - vobj.setEditorMode('ShowFirstRapid', mode) vobj.setEditorMode('DisplayMode', mode) vobj.setEditorMode('BoundingBox', mode) vobj.setEditorMode('Selectable', mode) diff --git a/src/Mod/Path/PathScripts/PathInspect.py b/src/Mod/Path/PathScripts/PathInspect.py index 4fbc473dd6..496c31e260 100644 --- a/src/Mod/Path/PathScripts/PathInspect.py +++ b/src/Mod/Path/PathScripts/PathInspect.py @@ -123,7 +123,6 @@ class GCodeEditorDialog(QtGui.QDialog): self.selectionobj = FreeCAD.ActiveDocument.addObject("Path::Feature","selection") self.selectionobj.ViewObject.LineWidth = 4 self.selectionobj.ViewObject.NormalColor = highlightcolor - self.selectionobj.ViewObject.ShowFirstRapid = False # nice text editor widget for editing the gcode self.editor = QtGui.QTextEdit() diff --git a/src/Mod/Path/PathScripts/PathLoadTool.py b/src/Mod/Path/PathScripts/PathLoadTool.py index 53f4e7d72e..a8a620f144 100644 --- a/src/Mod/Path/PathScripts/PathLoadTool.py +++ b/src/Mod/Path/PathScripts/PathLoadTool.py @@ -121,7 +121,6 @@ class _ViewProviderLoadTool: vobj.setEditorMode('LineWidth', mode) vobj.setEditorMode('MarkerColor', mode) vobj.setEditorMode('NormalColor', mode) - vobj.setEditorMode('ShowFirstRapid', mode) vobj.setEditorMode('DisplayMode', mode) vobj.setEditorMode('BoundingBox', mode) vobj.setEditorMode('Selectable', mode) @@ -143,7 +142,6 @@ class _ViewProviderLoadTool: vobj.setEditorMode('LineWidth', mode) vobj.setEditorMode('MarkerColor', mode) vobj.setEditorMode('NormalColor', mode) - vobj.setEditorMode('ShowFirstRapid', mode) vobj.setEditorMode('DisplayMode', mode) vobj.setEditorMode('BoundingBox', mode) vobj.setEditorMode('Selectable', mode) diff --git a/src/Mod/Path/PathScripts/PathPlane.py b/src/Mod/Path/PathScripts/PathPlane.py index 8b5e7d100a..538ef0da8e 100644 --- a/src/Mod/Path/PathScripts/PathPlane.py +++ b/src/Mod/Path/PathScripts/PathPlane.py @@ -68,7 +68,6 @@ class _ViewProviderPlane: vobj.setEditorMode('LineWidth', mode) vobj.setEditorMode('MarkerColor', mode) vobj.setEditorMode('NormalColor', mode) - vobj.setEditorMode('ShowFirstRapid', mode) vobj.setEditorMode('DisplayMode', mode) vobj.setEditorMode('BoundingBox', mode) vobj.setEditorMode('Selectable', mode) @@ -90,7 +89,6 @@ class _ViewProviderPlane: vobj.setEditorMode('LineWidth', mode) vobj.setEditorMode('MarkerColor', mode) vobj.setEditorMode('NormalColor', mode) - vobj.setEditorMode('ShowFirstRapid', mode) vobj.setEditorMode('DisplayMode', mode) vobj.setEditorMode('BoundingBox', mode) vobj.setEditorMode('Selectable', mode) diff --git a/src/Mod/Path/PathScripts/PathStop.py b/src/Mod/Path/PathScripts/PathStop.py index 32ef3f98c0..6886d7fca8 100644 --- a/src/Mod/Path/PathScripts/PathStop.py +++ b/src/Mod/Path/PathScripts/PathStop.py @@ -77,7 +77,6 @@ class _ViewProviderStop: vobj.setEditorMode('LineWidth', mode) vobj.setEditorMode('MarkerColor', mode) vobj.setEditorMode('NormalColor', mode) - vobj.setEditorMode('ShowFirstRapid', mode) vobj.setEditorMode('DisplayMode', mode) vobj.setEditorMode('BoundingBox', mode) vobj.setEditorMode('Selectable', mode) @@ -99,7 +98,6 @@ class _ViewProviderStop: vobj.setEditorMode('LineWidth', mode) vobj.setEditorMode('MarkerColor', mode) vobj.setEditorMode('NormalColor', mode) - vobj.setEditorMode('ShowFirstRapid', mode) vobj.setEditorMode('DisplayMode', mode) vobj.setEditorMode('BoundingBox', mode) vobj.setEditorMode('Selectable', mode) diff --git a/src/Mod/Path/PathScripts/PathToolLenOffset.py b/src/Mod/Path/PathScripts/PathToolLenOffset.py index f4713a3142..0412cbc054 100644 --- a/src/Mod/Path/PathScripts/PathToolLenOffset.py +++ b/src/Mod/Path/PathScripts/PathToolLenOffset.py @@ -81,7 +81,6 @@ class _ViewProviderTLO: vobj.setEditorMode('LineWidth', mode) vobj.setEditorMode('MarkerColor', mode) vobj.setEditorMode('NormalColor', mode) - vobj.setEditorMode('ShowFirstRapid', mode) vobj.setEditorMode('DisplayMode', mode) vobj.setEditorMode('BoundingBox', mode) vobj.setEditorMode('Selectable', mode) @@ -103,7 +102,6 @@ class _ViewProviderTLO: vobj.setEditorMode('LineWidth', mode) vobj.setEditorMode('MarkerColor', mode) vobj.setEditorMode('NormalColor', mode) - vobj.setEditorMode('ShowFirstRapid', mode) vobj.setEditorMode('DisplayMode', mode) vobj.setEditorMode('BoundingBox', mode) vobj.setEditorMode('Selectable', mode) @@ -156,7 +154,6 @@ project = PathUtils.addToJob(obj) tl = PathUtils.changeTool(obj,project) if tl: obj.HeightNumber = tl -obj.ViewObject.ShowFirstRapid = False FreeCAD.ActiveDocument.recompute() ''' FreeCADGui.doCommand(snippet) diff --git a/src/Mod/Path/PathScripts/smoothie_post.py b/src/Mod/Path/PathScripts/smoothie_post.py index 94e64ad872..bd691f0270 100644 --- a/src/Mod/Path/PathScripts/smoothie_post.py +++ b/src/Mod/Path/PathScripts/smoothie_post.py @@ -122,8 +122,8 @@ def processArguments(argstring): SHOW_EDITOR = True elif arg == '--no-show-editor': SHOW_EDITOR = False - elif arg == '--IP_ADDR': - IP_ADDR = '192.168.1.11' + elif arg.split('=')[0] == '--IP_ADDR': + IP_ADDR = arg.split('=')[1] elif arg == '--verbose': VERBOSE = True