[Sugar-devel] [PATCH Browse] Use UNICODE string to search into places SL #2830
Manuel Quiñones
manuq at laptop.org
Wed May 23 19:09:03 EDT 2012
2012/5/2 Daniel Drake <dsd at laptop.org>:
> On Wed, May 2, 2012 at 10:24 AM, Manuel Quiñones <manuq at laptop.org> wrote:
>> Works for me in my dev machine and in the XO. Are we safe to assume
>> that the text in GtkEntry is utf-8 ?
>
> All strings in GTK+ are in UTF-8.
> However, python tends to work in UTF16.
>
> I am surprised that it is not automatically converted to UTF16 by pygobject.
>
> What is the data type of self.props.text?
It is <type 'str'>, even if I do in the setter method:
if not isinstance(text, unicode):
text = unicode(text, 'utf-8')
self.props.text = text
> Can you do self.get_text()?
Yes and its return value is <type 'str'> too.
Shall we commit humito's patch, or file a bug upstream?
--
.. manuq ..
More information about the Sugar-devel
mailing list