|
@@ -53,6 +53,7 @@ import textwrap
|
|
|
import os
|
|
|
import time
|
|
|
import copy
|
|
|
+import locale
|
|
|
|
|
|
### i18N
|
|
|
import gettext
|
|
@@ -1729,8 +1730,14 @@ class GUI:
|
|
|
# parse the interface decription
|
|
|
self.grass_task = grassTask()
|
|
|
handler = processTask(self.grass_task)
|
|
|
- xml.sax.parseString( getInterfaceDescription(cmd[0]), handler )
|
|
|
-
|
|
|
+ enc = locale.getdefaultlocale()[1]
|
|
|
+ if enc and enc.lower() not in ("utf8", "utf-8"):
|
|
|
+ xml.sax.parseString(getInterfaceDescription(cmd[0]).decode(enc).encode("utf-8"),
|
|
|
+ handler)
|
|
|
+ else:
|
|
|
+ xml.sax.parseString(getInterfaceDescription(cmd[0]),
|
|
|
+ handler)
|
|
|
+
|
|
|
# if layer parameters previously set, re-insert them into dialog
|
|
|
if completed is not None:
|
|
|
if 'params' in dcmd_params:
|