How to print a unicode string?
bignose+hates-spam at benfinney.id.au
Sat Apr 19 02:53:15 CEST 2008
damonwischik at gmail.com writes:
> On Apr 19, 12:51 am, Ben Finney wrote:
> > Just because the locale library knows the normalised name for it
> > doesn't mean it's available on your OS. Have you confirmed that
> > your OS (independent of Python) supports the locale you're trying
> > to set?
> No. How do I found out which locales my OS supports? (I'm running
> Windows XP.)
Can't help you there.
> Why does it matter what locales my OS supports, when all I want is
> to set the encoding to be used for the output
Because the Python 'locale' module is all about using the OS's
(actually, the underlying C library's) locale support.
The locale you request with 'locale.setlocale' needs to be supported
by the locale database, which is independent of any specific
application, be it Python, Emacs, or otherwise.
\ "Two rules to success in life: 1. Don't tell people everything |
`\ you know." -- Sassan Tat |
More information about the Python-list