[Tutor] output not in ANSI

eryksun eryksun at gmail.com
Mon Aug 13 21:12:04 CEST 2012


On Mon, Aug 13, 2012 at 2:04 PM, Joel Goldstick
<joel.goldstick at gmail.com> wrote:
>
> I believe in this context the OP means ASCII.  ASCII became an ANSI
> recognized standard many years ago

In Windows, ANSI refers to the locale-dependent 8-bit codepage. But
there is no ANSI standard for Windows1252. It's a common misnomer in
the OS dialog boxes and controls. Another MS misnomer is labeling
UTF-16 as 'Unicode'.

@leon zaat

Process your text with Unicode. Open the file using codecs.open set to
your platform's preferred encoding, e.g. 'cp1252' for Western,
'cp1251' for Cyrilic, or locale.getpreferredencoding() in general.


More information about the Tutor mailing list