[Pythonmac-SIG] read content from latin-1 file, write it to ut8 file

Henning Hraban Ramm hraban at fiee.net
Tue Apr 18 21:40:38 CEST 2006


Am 2006-04-18 um 10:27 schrieb Piet van Oostrum:
>> FH> my problem is, that when I open "newtest.txt" in Textwrangler  
>> again,
>> FH> Textwrangler recognizes the file as "MacRoman" encoded and the  
>> content is
>> FH> garbled.
>
> Then that is Textwrangler's fault. Interpreting a utf-8 file as  
> MacRoman
> will indeed give garbage. Maybe you can configure Texwrangler to  
> recognize
> utf-8 files. Otherwise use an editor that does this well. This is  
> not a
> python problem, as the file should be (and probably is) generated  
> in utf-8.

You can define TW's default encoding and define a different encoding  
of some file in the Open dialogue or use the "re-open in another  
encoding" menu entry.


Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net
http://www.cacert.org (I'm an assurer)




More information about the Pythonmac-SIG mailing list