[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] textboxes and buttons (solved)



Matthieu TC <matthieutc@xxxxxxxxx>:

I suprisingly solved the problem. It was one of encoding.
I replaced:

self._text = self._text[:self._caret] + event.unicode + self._text[self._caret:]

with

self._text = self._text[:self._caret] + str(event.unicode) + self._text[self._caret:]

in ocempgui's Editable.py, and everything seems dandy once everything is cx_freezed.
[...]

This will break the box with encodings different from US-ASCII like e.g.
ISO-8859-15 (latin-1 with EURO symbol) and various others. Do you
have a cx_freze example I can easily use to track that issue down, so
that I can fix that error?

Regards
Marcus