Hi,
I am strugling with unicode strings.
It is the modified version of PyCon Hello World simple form, but as soon as I
introduced unicode characters in strings Dabo (Python) always get stuck and in
cmd window I can see Unicode Encode Error: 'ascii' codec can't encode chracter
u'\u017d' in position 154: ordinal not in range(128)
here is the code
******************************************
# -*- coding: utf-8 -*-
import dabo
dabo.ui.loadUI("wx")
class HelloPyConForm(dabo.ui.dForm):
def afterInit(self):
tekst = u"Pozdrav Ž".encode("utf-8")
self.Caption = u"Hello PyCon"
self.lblHello = dabo.ui.dLabel(self,
Caption=tekst, FontSize=24,
ForeColor="blue")
app = dabo.dApp()
app.MainFormClass = HelloPyConForm
app.start()
***********************************************
Z.
--- StripMime Report -- processed MIME parts ---
multipart/alternative
text/plain (text body -- kept)
text/html
---
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message:
http://leafe.com/archives/byMID/CE4774CBF7F843E189468B3BD1DB710A@Perajoe