Screenshot instructions:
Windows
Mac
Red Hat Linux
Ubuntu
Click URL instructions:
Right-click on ad, choose "Copy Link", then paste here →
(This may not be possible with some types of ads)
From: Glen Koundry <gkoundr@op...> - 2004-09-25 20:23:39
|
> You can use Encode.pm to the same result. Someone had suggested this already, but I'm not sure what I'm supposed to do with the Encode module. I tried converting to UTF-16, UTF-32 and UCS2 and it still doesn't display properly. >I thing you are on Windows. Which version? Which version >of Perl/ActiveState build? I am using Windows 2000 with ActiveState Perl version 5.8. However, I also tried it on a machine running Gentoo Linux but it still wouldn't work. for a test case, try this (the print statement is to show the Japanese text if your terminal can handle UTF-8): use Wx; package MyFrame; use base 'Wx::Frame'; sub new { my $ref = shift; my $self = $ref->SUPER::new( undef, -1, 'wxPerl rules', [-1, -1], [250, 300],); my $panel = Wx::Panel->new( $self, -1,); my $list = Wx::ListBox->new($panel,-1,[20,20],[210,180], ["aa","bb","cc"],wxLB_SINGLE); $utf8 ="\xe8\xbb\xbd\xe3\x81\x84\xe3\x81"; $utf8.="\x8b\xe3\x82\x8b\xe3\x81\x84\xe8"; $utf8.="\x8c\xb6\xe8\x89\xb2\xe3\x81\xa1"; $utf8.="\xe3\x82\x83\xe3\x81\x84\xe3\x82"; $utf8.="\x8d"; $list->Append($utf8); print "$utf8\n"; return $self; }package MyApp; use base 'Wx::App'; sub OnInit { my $frame = MyFrame->new; $frame->Show( 1 ); } package main; my $app = MyApp->new; $app->MainLoop; |