hdb has asked for the wisdom of the Perl Monks concerning the following question:
I am not able to get unicode to work under Win7 command prompt. I am changing the code page to 65000 and want to print the diagonals from Re^2: Random maze generator. I cannot post all the permutations I have tried from the various Perl unicode tutorials and FAQs. So here is my skeleton code and I would like to know which combination of encode, decode, etc makes this work and what is not needed to do. Many thanks
use strict; use warnings; use Encode; use utf8; binmode STDOUT, ':encoding(UTF-8)'; my $enc = "utf-8"; system( "chcp 65000" ); # from node http://www.perlmonks.org/?node_id=843144 my $ne = "\xe2\x95\xb1"; my $nw = "\xe2\x95\xb2"; print $ne, $nw, "\n";
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Unicode again, in Win7 cmd
by choroba (Cardinal) on Jun 07, 2013 at 11:27 UTC | |
by hdb (Monsignor) on Jun 07, 2013 at 11:31 UTC | |
by choroba (Cardinal) on Jun 07, 2013 at 11:58 UTC | |
by hdb (Monsignor) on Jun 07, 2013 at 12:06 UTC | |
by karlgoethebier (Abbot) on Jun 07, 2013 at 12:37 UTC | |
| |
Re: Unicode again, in Win7 cmd (chcp 65001)
by Anonymous Monk on Jun 07, 2013 at 11:30 UTC |