[pygtk] Microsoft Windows pygtk: gtk.FileChooserDialog returns weird characters when opening cyrillic filepath
Christian Mallwitz
c.mallwitz at gmail.com
Thu Jan 24 03:18:32 WST 2013
Assuming you 'print' the filename to stdout and Python has the
filename internally as UTF-8 string, Python may not do the right thing
when converting the string to bytes to be processed by your console
window. The console windows code page would be of interest too (run
chcp).
Christian
On Wed, Jan 23, 2013 at 5:52 PM, Giuseppe Penone <giuspen at gmail.com> wrote:
> Hi,
>
> while I have a file named E:\SOFTWARE\Кириллица.ctb on my pc, selecting it
> with a gtk.FileChooserDialog
> and printing to terminal returns weird characters
> E:\SOFTWARE\ÐsиÑ?иллиÑ┼а.ctb.
>
> Does anybody have a clue of the reason?
> PS I have all my files starting with # -*- coding: UTF-8 -*-
>
> Regards,
> Giuseppe.
>
> _______________________________________________
> pygtk mailing list pygtk at daa.com.au
> http://www.daa.com.au/mailman/listinfo/pygtk
> Read the PyGTK FAQ: http://faq.pygtk.org/
More information about the pygtk
mailing list