[BUG] Unicode in multilingualized Squeak

Yoshiki.Ohshima at acm.org Yoshiki.Ohshima at acm.org
Tue Mar 25 03:31:05 UTC 2003


  Boris,

> I think the statement should read:
> 
>   unicode >= 16r2E80 ifTrue: [
>    ^ self leadingCharForKanjiClass: kanjiClass
>   ].
> 
> which looks understandable, 16r2E80 is the first code point of the 
> CJK part of Unicode.

  This is correct.  Thanks again!  I have been deferring a test until
the file out format for CJKVs is defined.  After that, we can go ahead
and try the CJKV chars in methods and do-its.

> When my assumption is right, we have here an example of what a
> programmer has to fear most: A typo that results in a strange but
> valid statement.

  Exactly.  In Squeak, the step execution would usually help, though.

> I have also reason to believe that 
> UTF8TextConverter>>nextFromStream:
> should be revised. Currently no value is assigned to the
> temporary variable  codesets when "Smalltalk primaryLanguage"
> is not one of Japanese, Korean, ContinentalChinese.
> Perhaps it is a good idea to  add
>   
>   codesets isNil ifTrue: [^Unicode value: unicode]
> 
>  but this proposal is highly speculative.

  The implementation of UTF8TextConverter is mostly based on the 'old
implementation' and haven't been tested much yet with the 'new
implementation.'

  In the near future, JISX0208, KSX1001, and GB2312 are going to be
obsoleted.  The CJK characters returned from
UTF8TextConverter>>nextFromStream: should be MultiCharacters with
Unicode{Japanese,Korean,TraditionalChinese,SimplifiedChinese}>>leadingChar.
(To load a project exported from the 'old' implementation, those
ISO-2022 based mechanism might be needed, though.)

  In this case, UTF8TextConverter doesn't have to worry about
converting from EUC-{jp,kr.cn} or ISO-2022 based code to the Unicode
based code.  Such conversion will be done by looking up the UCS2Table
and modified CompoundTextConverter or EUC??TextConverter.

  For temporarily, adding the line you proposed to make sense.

> A change set is added. What do you think about it? Can you
> approve my changes or did I miss somthing important?

  That is great.  Until we have a update stream, we should assemble
such changes to a wiki, possibly at minnow or somewhere else.

-- Yoshiki



More information about the Squeak-dev mailing list