but didn't see any Asian characters in there. So without ever specifying a font in my script, I'm wondering what font it chose and how it managed to display (almost all of) the Chinese characters.

I admit I am not very familiar with unicode and asian fonts. I do remember, however, that when I build and install Tk, one of the tests it runs thru is to fill up a window with alot of asian characters, even though I don't have any asian fonts installed. It probably does it just like you did, specifying the unicode characters with Encode? One of the test scripts in the root of the Tk source tree is called "chfont" and it displays asian characters.

use strict; use Tk; use Encode qw(decode); my $face = (@ARGV) ? shift : 'fixed'; my @headers = <DATA>; my $mw = MainWindow->new; foreach my $text (@headers) { my $str = decode('MIME-Header' => $text); $mw->Label(-text => $str, -font => [$face,14])->pack; } MainLoop; __DATA__ From: =?Big5?B?qfq8dw==?= <tukb122@ms12.url.com.tw> Subject:=?big5?Q?=A9_=A4b=A5=D8=BF=FD=A7=F3=B7s!!?= Subject: =?Big5?B?o7Ck+S4uLi4uLi4uLi4uLi4uLi4uLg==?= From: =?Big5?B?tW6//bdqtE2k3sC6?= <twpalm@pchome.com.tw> Subject: =?Big5?B?rf6xeqq6uvSvuLVuv/23arRNpN7Aug==?= Subject:=?big5?Q?=A7K=B6O=A5=F4=A5=B4=A4=A4=B4=E4=AA=F8=B3~=B9q=B8=DC? += Subject:=?big5?Q? =A4u=A7@=B2=D6=A4F=A4@=A4=D1=BA=D6=A7Q=B0e=B5=B9=A7A + ^0^ =A6A=A6=B8=B7P=C1=C2=BE=E3=B2z=B3o=A5=F7=B8=EA=AE=C6=AA=BA=A4H +!!! ?= Subject:=?big5?Q? =A4u=A7@=B2=D6=A4F=A4@=A4=D1=BA=D6=A7Q=B0e=B5=B9=A7A + ^0^ =A6A=A6=B8=B7P=C1=C2=BE=E3=B2z=B3o=A5=F7=B8=EA=AE=C6=AA=BA=A4H +!!! ?= Subject:=?big5?Q? =A4u=A7@=B2=D6=A4F=A4@=A4=D1=BA=D6=A7Q=B0e=B5=B9=A7A + ^0^ =A6A=A6=B8=B7P=C1=C2=BE=E3=B2z=B3o=A5=F7=B8=EA=AE=C6=AA=BA=A4H +!!! ?=

I'm not really a human, but I play one on earth. flash japh

In reply to Re^3: Chinese font problem in Perl/Tk by zentara
in thread Chinese fonts problem in Perl/Tk by shockers

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.