Fwd: [squeak-dev] About Squeak 4.1 Language Support

Eric ericqiu at gmail.com
Fri Jan 28 04:46:00 UTC 2011


FYI

---------- Forwarded message ----------
From: Eric <ericqiu at gmail.com>
Date: 2011/1/28
Subject: Re: [squeak-dev] About Squeak 4.1 Language Support
To: kksubbu.ml at gmail.com


Thanks Subbu,

As you mentioned, I tried the CNGBTextConverter existing in Squeak4.1 and I
assume that it will invoke the languageEnvironment to
SimplifiedChineseEnvironment, am i right?

I tried following code like:
 (MultiByteFileStream fileNamed: 'file.txt')
               converter: (CNGBTextConverter new);
               contents.

And it still doesn't work, does it mean i need to import some fonts for it
or other ways?

Also another question is in Squeak4.1 what could i do to make sure the the
language environment I use is chinese or some others?

My understanding now in Squeak4.1 that the default language is UTF8 or
Unicode, where could i do the switch?

I am just a beginner on Squeak Smalltalk, please correct me if I make any
mistakes on understanding

Eric
2011/1/27 K. K. Subramaniam <kksubbu.ml at gmail.com>

 On Thursday 27 Jan 2011 3:22:37 pm Eric wrote:
> > Now Squeak 4.1 has supported Chinese from Code level, I have tried to
> read
> > a file containing Chinese character from attached file, it showed up ??
> > for chinese character.
> >
> > Note: run
> >
> > (MultiByteFileStream fileNamed: 'file.txt') contents
> > in the workspace
> >
> > Any one know some about it?
>
> LanguageEnvironment defaultSystemConverter
>
> determines the text converter used for reading text files for your
> environment.
> Inspect
>    (MultiByteFileStream fileNamed: 'file.txt') converter
> and make sure it is UTF8TextConverter. If not, you may need to override the
> converter before reading its contents. e.g.
>        (MultiByteFileStream fileNamed: 'file.txt')
>                converter: (UTF8TextConverter new);
>                contents.
>
> If the characters are being decoded correctly then you may need specific
> language support (fonts, rendering engine etc.) for your dialect. See
> language
> support classes in Multilingual-Languages for more details.
>
> Subbu
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20110128/19580ee1/attachment.htm


More information about the Squeak-dev mailing list