Skip to content

Commit

Permalink
fix UnicodeEncodeError writing SVG string to .svg file, fixes ipython…
Browse files Browse the repository at this point in the history
  • Loading branch information
mspacek committed Jun 1, 2011
1 parent 5163e14 commit 5acdcc1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion IPython/frontend/qt/svg.py
Expand Up @@ -29,7 +29,7 @@ def save_svg(string, parent=None):
filename = dialog.selectedFiles()[0]
f = open(filename, 'w')
try:
f.write(string)
f.write(string.encode('UTF-8'))
finally:
f.close()
return filename
Expand Down

0 comments on commit 5acdcc1

Please sign in to comment.