<div dir="ltr">2010/3/2 drizt <span dir="ltr"><<a href="mailto:drizt.ruan@gmail.com">drizt.ruan@gmail.com</a>></span><br><div class="gmail_quote"><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
--------------------------------------------------------------------------------<br>
2010-03-02, 17:20:07<br>
--------------------------------------------------------------------------------<br>
<class 'ValueError'>:<br>
Can only set default encoding to utf-8<br>
--------------------------------------------------------------------------------<br>
File "C:\Python31\Lib\site-packages\eric5\eric5.py", line 253, in<br>
<module><br>
main()<br>
File "C:\Python31\Lib\site-packages\eric5\eric5.py", line 212, in main<br>
sys.setappdefaultencoding(Preferences.getSystem("StringEncoding"))<br>
<br>
--------------------------------------------------------------------------------<br>
Version Numbers:<br>
Python 3.1.1<br>
Qt 4.6.1<br>
PyQt4 4.7<br>
sip 4.10<br>
QScintilla 2.4.2<br>
eric5 5.0-snapshot-20100206 (r107)<br>
<br>
Platform: win32<br>
3.1.1 (r311:74483, Aug 17 2009, 17:02:12) [MSC v.1500 32 bit (Intel)]<br>
<br>
<br>
<br>
After modified the eric5\Preference\__init__.py file, i can now run<br>
eric5, but i am not sure if it is ok.<br>
<br>
from<br>
<br>
# defaults for system settings<br>
if isWindowsPlatform():<br>
sysDefaults = {<br>
"StringEncoding" : "cp1251",<br>
"IOEncoding" : "cp1251",<br>
}<br>
else:<br>
sysDefaults = {<br>
"StringEncoding" : "utf-8",<br>
"IOEncoding" : "utf-8",<br>
}<br>
<br>
to<br>
# defaults for system settings<br>
if isWindowsPlatform():<br>
sysDefaults = {<br>
"StringEncoding" : "utf-8",<br>
"IOEncoding" : "utf-8",<br>
}<br>
else:<br>
sysDefaults = {<br>
"StringEncoding" : "utf-8",<br>
"IOEncoding" : "utf-8",<br>
}<br>
<br>
<br>
<br>
Regards,<br>
drizt.ruan<br>
<br>
<br>
_______________________________________________<br>
Eric mailing list<br>
<a href="mailto:Eric@riverbankcomputing.com">Eric@riverbankcomputing.com</a><br>
<a href="http://www.riverbankcomputing.com/mailman/listinfo/eric" target="_blank">http://www.riverbankcomputing.com/mailman/listinfo/eric</a><br>
</blockquote></div>I always use utf-8. What utf-8 can't cp1251 can I can understand is an argument. Anything?<br>
<a href="http://dragonflybsd.org/niklas">dragonflybsd.org/niklas</a><br></div>