Remove decode as returned object by translate() function is a unicode oject

This commit is contained in:
wmayer
2019-01-08 13:23:51 +01:00
parent 55a4f78adf
commit 1ebcb36545

View File

@@ -64,11 +64,11 @@ def getIndices(shape,offset):
if not isinstance(e.Curve,Part.LineSegment):
if not curves:
curves = shape.tessellate(1)
FreeCAD.Console.PrintWarning(translate("Arch","Found a shape containing curves, triangulating").decode('utf8')+"\n")
FreeCAD.Console.PrintWarning(translate("Arch","Found a shape containing curves, triangulating")+"\n")
break
except: # unimplemented curve type
curves = shape.tessellate(1)
FreeCAD.Console.PrintWarning(translate("Arch","Found a shape containing curves, triangulating").decode('utf8')+"\n")
FreeCAD.Console.PrintWarning(translate("Arch","Found a shape containing curves, triangulating")+"\n")
break
elif isinstance(shape,Mesh.Mesh):
curves = shape.Topology
@@ -186,7 +186,7 @@ def export(exportList,filename):
for f in flist:
outfile.write("f" + f + "\n")
outfile.close()
FreeCAD.Console.PrintMessage(translate("Arch","Successfully written").decode('utf8') + " " + filename + "\n")
FreeCAD.Console.PrintMessage(translate("Arch","Successfully written") + " " + filename + "\n")
if materials:
outfile = pythonopen(filenamemtl,"wb")
outfile.write("# FreeCAD v" + ver[0] + "." + ver[1] + " build" + ver[2] + " Arch module\n")