Fixed wrong encoding in App.openTransaction

This commit is contained in:
Yorik van Havre
2018-05-21 12:11:46 -03:00
parent c039bfb011
commit 4f5e304d64
2 changed files with 2 additions and 2 deletions

View File

@@ -341,7 +341,7 @@ PyObject* DocumentPy::openTransaction(PyObject *args)
}
#else
else if (PyUnicode_Check(value)) {
PyObject* unicode = PyUnicode_AsLatin1String(value);
PyObject* unicode = PyUnicode_AsUTF8String(value);
cmd = PyString_AsString(unicode);
Py_DECREF(unicode);
}

View File

@@ -271,7 +271,7 @@ class _CommandWall:
self.Activated()
def addDefault(self,l):
FreeCADGui.doCommand('base=FreeCAD.ActiveDocument.addObject("Sketcher::SketchObject","'+translate('Arch','WallTrace')+'")')
FreeCADGui.doCommand('base=FreeCAD.ActiveDocument.addObject("Sketcher::SketchObject","WallTrace")')
FreeCADGui.doCommand('base.Placement = FreeCAD.DraftWorkingPlane.getPlacement()')
FreeCADGui.doCommand('base.addGeometry(trace)')
FreeCADGui.doCommand('wall = Arch.makeWall(base,width='+str(self.Width)+',height='+str(self.Height)+',align="'+str(self.Align)+'")')