diff options
| author | Rémi Verschelde | 2016-06-22 00:32:29 +0200 |
|---|---|---|
| committer | Rémi Verschelde | 2016-06-22 00:32:29 +0200 |
| commit | 5e082d583b1dc0fcdefe39960bcefda7955b8537 (patch) | |
| tree | d2dfcf4e2ce6e96093831363be4884a29ad59c6a /doc/tools/makerst.py | |
| parent | e69e50040b51d3cba4bb38b848bac6ed003640d7 (diff) | |
| download | godot-5e082d583b1dc0fcdefe39960bcefda7955b8537.tar.gz godot-5e082d583b1dc0fcdefe39960bcefda7955b8537.tar.zst godot-5e082d583b1dc0fcdefe39960bcefda7955b8537.zip | |
Diffstat (limited to 'doc/tools/makerst.py')
| -rw-r--r-- | doc/tools/makerst.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/doc/tools/makerst.py b/doc/tools/makerst.py index 060dbc805..45e690cb6 100644 --- a/doc/tools/makerst.py +++ b/doc/tools/makerst.py @@ -1,6 +1,7 @@ #!/usr/bin/python # -*- coding: utf-8 -*- +import codecs import sys import xml.etree.ElementTree as ET @@ -32,7 +33,7 @@ def ul_string(str,ul): def make_class_list(class_list, columns): - f = open('class_list.rst', 'wb') + f = codecs.open('class_list.rst', 'wb', 'utf-8') prev = 0 col_max = len(class_list) / columns + 1 print ('col max is ', col_max) @@ -347,7 +348,7 @@ def make_rst_class(node): name = node.attrib['name'] - f = open("class_"+name.lower() + '.rst', 'wb') + f = codecs.open("class_"+name.lower() + '.rst', 'wb', 'utf-8') # Warn contributors not to edit this file directly f.write(".. Generated automatically by doc/tools/makerst.py in Godot's source tree.\n") |
