Merge branch 'master' of ssh://git.code.sf.net/p/free-cad/code
This commit is contained in:
@@ -727,7 +727,7 @@ def survey(callback=False):
|
||||
t = t.getUserPreferred()[0]
|
||||
t = t.encode("utf8")
|
||||
anno.LabelText = "l " + t
|
||||
FreeCAD.Console.PrintMessage("Object: " + n + ", Element: Whole, Length: " + t + "\n")
|
||||
FreeCAD.Console.PrintMessage("Object: " + n + ", Element: Whole, Length: " + t.decode("utf8") + "\n")
|
||||
if FreeCAD.GuiUp and t:
|
||||
QtGui.qApp.clipboard().setText(t)
|
||||
else:
|
||||
@@ -755,13 +755,13 @@ def survey(callback=False):
|
||||
t = t.getUserPreferred()[0]
|
||||
t = t.encode("utf8")
|
||||
anno.LabelText = "l " + t
|
||||
FreeCAD.Console.PrintMessage("Object: " + n + ", Element: " + el + ", Length: " + t + "\n")
|
||||
FreeCAD.Console.PrintMessage("Object: " + n + ", Element: " + el + ", Length: " + t.decode("utf8") + "\n")
|
||||
elif "Vertex" in el:
|
||||
t = FreeCAD.Units.Quantity(e.Z,FreeCAD.Units.Length)
|
||||
t = t.getUserPreferred()[0]
|
||||
t = t.encode("utf8")
|
||||
anno.LabelText = "z " + t
|
||||
FreeCAD.Console.PrintMessage("Object: " + n + ", Element: " + el + ", Zcoord: " + t + "\n")
|
||||
FreeCAD.Console.PrintMessage("Object: " + n + ", Element: " + el + ", Zcoord: " + t.decode("utf8") + "\n")
|
||||
if FreeCAD.GuiUp and t:
|
||||
QtGui.qApp.clipboard().setText(t)
|
||||
|
||||
|
||||
@@ -521,7 +521,7 @@ class DraftToolBar:
|
||||
elif defaultWP == 3:
|
||||
self.wplabel.setText("Side")
|
||||
else:
|
||||
self.wplabel.setText("None")
|
||||
self.wplabel.setText("Auto")
|
||||
self.constrButton = self._pushbutton("constrButton", self.toptray, hide=False, icon='Draft_Construction',width=22, checkable=True)
|
||||
self.constrColor = QtGui.QColor(self.paramconstr)
|
||||
self.colorButton = self._pushbutton("colorButton",self.bottomtray, hide=False,width=22)
|
||||
@@ -607,7 +607,7 @@ class DraftToolBar:
|
||||
self.yzButton.setToolTip(translate("draft", "Select YZ plane"))
|
||||
self.currentViewButton.setText(translate("draft", "View"))
|
||||
self.currentViewButton.setToolTip(translate("draft", "Select plane perpendicular to the current view"))
|
||||
self.resetPlaneButton.setText(translate("draft", "None"))
|
||||
self.resetPlaneButton.setText(translate("draft", "Auto"))
|
||||
self.resetPlaneButton.setToolTip(translate("draft", "Do not project points to a drawing plane"))
|
||||
self.isCopy.setText(translate("draft", "&Copy"))
|
||||
self.isCopy.setToolTip(translate("draft", "If checked, objects will be copied instead of moved (C)"))
|
||||
|
||||
@@ -369,15 +369,15 @@ class SelectPlane(DraftTool):
|
||||
self.offset = 0
|
||||
if arg == "XY":
|
||||
FreeCADGui.doCommandGui("FreeCAD.DraftWorkingPlane.alignToPointAndAxis(FreeCAD.Vector(0,0,0), FreeCAD.Vector(0,0,1), "+str(self.offset)+")")
|
||||
self.display('top')
|
||||
self.display('Top')
|
||||
self.finish()
|
||||
elif arg == "XZ":
|
||||
FreeCADGui.doCommandGui("FreeCAD.DraftWorkingPlane.alignToPointAndAxis(FreeCAD.Vector(0,0,0), FreeCAD.Vector(0,-1,0), "+str(self.offset)+")")
|
||||
self.display('front')
|
||||
self.display('Front')
|
||||
self.finish()
|
||||
elif arg == "YZ":
|
||||
FreeCADGui.doCommandGui("FreeCAD.DraftWorkingPlane.alignToPointAndAxis(FreeCAD.Vector(0,0,0), FreeCAD.Vector(1,0,0), "+str(self.offset)+")")
|
||||
self.display('side')
|
||||
self.display('Side')
|
||||
self.finish()
|
||||
elif arg == "currentView":
|
||||
d = self.view.getViewDirection().negative()
|
||||
@@ -386,7 +386,7 @@ class SelectPlane(DraftTool):
|
||||
self.finish()
|
||||
elif arg == "reset":
|
||||
FreeCADGui.doCommandGui("FreeCAD.DraftWorkingPlane.reset()")
|
||||
self.display('None')
|
||||
self.display('Auto')
|
||||
self.finish()
|
||||
|
||||
def offsetHandler(self, arg):
|
||||
|
||||
Reference in New Issue
Block a user