>
> Is the file, which you claim is UTF-8 encoded, actually UTF-8 encoded?
> If you're not sure, explicitly tell your text editor to save the file as
> UTF-8, and then try again.
I feel like an idiot... haven't used Python for some time... my editor was
set for utf-8 on PHP projects and other...
On 08/06/2010 04:37 PM, alejandro wrote:
>
>> # the last tuple is the background color
>> img = Image.new("RGBA",(300, 50), (0, 0, 0, 0))
> Thank you for this
>
>> # I think that the PIL can cope with unicode, so add a u-prefix here:
>> text = u"proba test ¾æèð¹"
>> draw.text((20,8), text ,fo
alejandro wrote:
>> Make sure that
>>
>> # encoding:utf-8
>>
>> is the first line of your script, details and fineprint here:
>>
>> http://www.python.org/dev/peps/pep-0263/
>>
>> Peter
>
> Tryed that...
What happened?
> What was the output of my script on your computer?
$ python -V
Python 2.6.
>
> Make sure that
>
> # encoding:utf-8
>
> is the first line of your script, details and fineprint here:
>
> http://www.python.org/dev/peps/pep-0263/
>
> Peter
Tryed that...
What was the output of my script on your computer?
--
http://mail.python.org/mailman/listinfo/python-list
alejandro wrote:
>> # the last tuple is the background color
>> img = Image.new("RGBA",(300, 50), (0, 0, 0, 0))
> Thank you for this
>
>> # I think that the PIL can cope with unicode, so add a u-prefix here:
>> text = u"proba test �"
>> draw.text((20,8), text ,font=arial, fill="red")
>
>
> # the last tuple is the background color
> img = Image.new("RGBA",(300, 50), (0, 0, 0, 0))
Thank you for this
> # I think that the PIL can cope with unicode, so add a u-prefix here:
> text = u"proba test ¾æèð¹"
> draw.text((20,8), text ,font=arial, fill="red")
Nope i gives:
SyntaxError: (u
alejandro wrote:
> Can please someone run this little script that should output characters
> like � in an image.
> If it does it correctly can you tell me what OS, python version & PIL
> version you have?
> Or better if someone can tell me why this is not working properly on my
> PC? (Win XP,
Can please someone run this little script that should output characters like
¾æè¹ð in an image.
If it does it correctly can you tell me what OS, python version & PIL
version you have?
Or better if someone can tell me why this is not working properly on my PC?
(Win XP, PIL 1.1.6., Python 2.6...)