Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #100048 > unrolled thread

Re: Unicode failure

Started byTerry Reedy <tjreedy@udel.edu>
First post2015-12-05 17:03 -0500
Last post2015-12-05 17:03 -0500
Articles 1 — 1 participant

Back to article view | Back to comp.lang.python

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: Unicode failure Terry Reedy <tjreedy@udel.edu> - 2015-12-05 17:03 -0500

#100048 — Re: Unicode failure

FromTerry Reedy <tjreedy@udel.edu>
Date2015-12-05 17:03 -0500
SubjectRe: Unicode failure
Message-ID<mailman.229.1449353059.14615.python-list@python.org>
On 12/5/2015 2:44 PM, Random832 wrote:
> On 2015-12-05, Terry Reedy <tjreedy@udel.edu> wrote:
>> On 12/4/2015 10:22 PM, Random832 wrote:
>>> Well, any bar 1200, 1201, 12000, 12001, 65000, 65001, and 54936.
>>
>> Test before you post.
>
> As someone else pointed out, I meant that as a list of codepages
> which support all Unicode codepoints, not a list of codepoints
> not supported by Tk's UCS-2.  Sorry, I assumed everyone knew
> offhand that 65001 was UTF-8

So Microsoft claims, but it is not terribly useful.  Currently, on my 
Win 10 system, 'chcp 65001' results in sys.stdout.encoding = 'cp65001', and

for cp in 1200, 1201, 12000, 12001, 65000, 65001, 54936:
     print(chr(cp))

running without the usual exception.  But of the above numbers 
mis-interpreted as codepoints, only 1200 and 1201 print anything other 
than a box with ?, whereas IDLE printed 3 other chars for 3 other 
assigned codepoints. If I change the console font to Lucida Console, 
which I use in IDLE, even chr(1200) gives a box.

> and would infer that the rest were for other UTF encodings.

After re-reading, I see how I might have inferred that.  Anyway, the OP 
found the solution for his system.

-- 
Terry Jan Reedy

[toc] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web