Loading [MathJax]/jax/output/HTML-CSS/jax.js

Ярлыки

суббота, 3 ноября 2012 г.

problem with encoding in PyQt4


Python2.7, Eric4, PyQt4 
I have follow problem:
when I send list to form for fill ComboBox: in ComboBox I see abracadabra. My coding is utf-8.

My code:
sectList=i[0 for i in sectionsDict.items]
printsectList
main_window.selectSection.addItemssectList

Function "print" insert for see what doing here.

Solve of the problem:
sectList=unicode(i[0, 'cp1251') for i in sectionsDict.items]
printsectList
main_window.selectSection.addItemssectList

Комментариев нет:

Отправить комментарий