[PyKDE] [PyQt4] QDate.toString(QtCore.Qt.TextDate) is not UTF-8

Andreas Pakulat apaku at gmx.de
Thu Jan 26 09:29:26 GMT 2006


On 26.01.06 03:15:54, Ismail Donmez wrote:
> I am doing something like this QStatusBar.showMessage("Foo - %s" % 
> QDate.toString(QtCore.Qt.TextDate))

Does it work with:

QStatusBar.showMessage(QtCore.QString("Foo -
%1").arg(QDate.toString(QtCore.Qt.QTextDate)))

? I suspect that the %-replacement converts the QString to str and then
after replacement again into QString and in between you loose
Unicode'ness of your string. But this is only guessing, Phil should know
for sure.

Andreas

-- 
Don't go surfing in South Dakota for a while.




More information about the PyQt mailing list