>> Hello,
>>
>> I'm a french user and I'm trying to put an  'é' into a pylab title.
>> My locales and fully utf-8 and the code is the following under ipthon:
>> import pylab
>> a="é"
>> pylab.plot([1])
>> pylab.title(a)
>>
>> raises the error :
>> UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 0: 
>> ordinal not in range(128)
>>     
>
> Have you tried using a Unicode string as input? e.g.
>
> a = u"é"
>
> That works for me, though it stops at the LaTeX step because I'm missing 
> some LaTeX packages.
>
>   
>> Is it a bug or a I doing something wrong? I'm using up to date pylab svn 
>> with the tk backend.
>>
>> The prolem is that only the tk backend is fully functionnal on my box. 
>> HTe gtk one never shows the buttons (debian up to date sid).
>>     
>
> The Tk backend is treating your input string as Latin-1, not UCS, which 
> is the same for codepoints < 255, so you got lucky.
>
> There are probably a few of these encoding bugs in various backends that 
> should probably be worked through.
>
> Cheers,
> Mike
>
>   

With a = u"é" I get no error but also nothing as a title. No strange 
characters. Nothing.

Xavier


-- 
############################################
Xavier Gnata
CRAL - Observatoire de Lyon
9, avenue Charles André
69561 Saint Genis Laval cedex
Phone: +33 4 78 86 85 28
Fax: +33 4 78 86 83 86
E-mail: [EMAIL PROTECTED]
############################################ 


-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to