Mantis - Squeak
Viewing Issue Advanced Details
7071 Multilingual major always 05-28-08 09:58 04-18-10 21:59
closed 3.10  
none trunk  
0007071: Key values from Input Method are not converted correctly on new Unicode Windows VM
On new Windows VM, Squeak gets key value as unicode. However, VI still assumes it is legacy encode like Shift-JIS.
I wrote a WinUnicodeInputInterpreter for handling unicode values from IM properly.
child of 0006570assigned tim A Mother for font and font test problems 
 WinUnicodeInputInterpreter-mu.4.cs [^] (2,075 bytes) 05-28-08 09:58
 0482UnicodeInput1-yo.cs [^] (13,759 bytes) 05-29-08 00:58
 1713UnicodeInput1-yo.1.cs [^] (13,723 bytes) 05-30-08 05:49
 1714UnicodeInput2-yo.1.cs [^] (965 bytes) 05-30-08 05:49
 1925unixLatin1Input-yo.cs [^] (797 bytes) 08-21-08 16:05
 1935unicodeFallback-bf.cs [^] (2,417 bytes) 08-21-08 16:05
 UnixVM-UnicodeInput-310ImageCompatible-M7071-nice.1.cs [^] (4,555 bytes) 08-21-08 16:39

05-29-08 01:04   
Yoshiki informed me that there has already been UTF32InputInterpreter (and its peers) in OLPC eToys image. His patch is more complete. I think his patch should be applied to 3.10 image also. (See: 0482UnicodeInput1-yo.cs)
05-30-08 05:54   
More recent versions from etoys-dev-3.0.image (1713UnicodeInput1-yo.1.cs, 1714UnicodeInput2-yo.1.cs). I confirmed they are loadable in 3.10.1 image.
06-05-08 23:15   
Hi umejava,

Thanks for the bug report and tracking the olpc repairs down.

There are a lot of font stuff in 3.10.n that need updating.
To get things into the image and insure they have some correctness we will need tests.

I am encouraging all who offer fixes to supplies tests that cover their changes. The simple criteria is that the tests should fail before the patch and pass afterwords. The tests serve to explain why the changes are needed and that the changes will do the job.

If you can help with this, it would be appreciated.

Partial progress counts and some tests are better than none.

I note that the changes are going to be large.
nicolas cellier   
08-21-08 16:04   
The same behavior appears on unix recent VM with unicode support (VM 3.10.1 for example).

Bert proposed OLPC updated patches at [^]

But I noticed a few differences between OLPC versions and 3.10 version for some ParagraphEditor methods in 1713UnicodeInput1-yo.1.cs :


OLPC: self zapSelectionWithCompositionWith: typeAhead contents.
3.10: self zapSelectionWith:
    (Text string: typeAhead contents emphasis: emphasisHere).
THIS ONE IS OK, emphasisHere IS HANDLED CORRECTLY IN #zapSelectionWithCompositionWith:


OLPC: lacks support for multilevel undo
      "===Support for multilevel undo start ==="
      rText _ (paragraph text copyFrom: start to: (stop - 1)).
      rInterval _ start to: (stop - 1).
      isInTypeRun _ self isInTypeRun.
      "===Support for multilevel undo end ==="
      "===Support for multilevel undo start ==="
      (Preferences multipleTextUndo and: [isInTypeRun not])ifTrue:
         [ self addEditCommand:
                  textMorph: morph
                  replacedText: rText
                  replacedTextInterval: rInterval
                  newText: aText
                  newTextInterval: super selectionInterval)].
      "===Support for multilevel undo end ==="

1935unicodeFallback-bf.cs also has some uncompatibilities with 3.10 image:


OLPC: lacks support for Preferences autoIndent on return
   char asciiValue = 13 ifTrue: [
      ^ sensor controlKeyPressed
         ifTrue: [self crWithIndent: typeAheadStream]
         ifFalse: [self normalCharacter: typeAheadStream]].
   char asciiValue = 13 ifTrue: [
      ^Preferences autoIndent
         ifTrue: [
            sensor controlKeyPressed
               ifTrue: [self normalCharacter: typeAheadStream]
               ifFalse: [self crWithIndent: typeAheadStream]]
         ifFalse: [
            sensor controlKeyPressed
               ifTrue: [self crWithIndent: typeAheadStream]
               ifFalse: [self normalCharacter: typeAheadStream]]].

Maybe it would be better to have an updated patch for 3.10 images.
Least TODO list before integrating in an official release:
- test if the patch works with an old VM (unix and windows),
- test if the patch works with new VM (unix and windows).

08-21-08 18:54   
"fix begin"
Installer bug: 7071 fix: '1713UnicodeInput1-yo.1.cs'.
Installer bug: 7071 fix: '1714UnicodeInput2-yo.1.cs'.
Installer bug: 7071 fix: '1925unixLatin1Input-yo.cs'.
Installer bug: 7071 fix: '1935unicodeFallback-bf.cs'.
"fix end"
nicolas cellier   
08-21-08 19:03   
Hi Matthew, also give a try to UnixVM-UnicodeInput-310ImageCompatible-M7071-nice.1.cs and add it to the list of patches if you want to preserve the two features that are in 3.10 image but do not seem to be in OLPC image:

- Preferences autoIndent
- Preferences multipleTextUndo

Unless these are unecessary? (I did not check what these features are worth)
02-15-09 05:17   
"fix begin"
Installer mantis bug: 7071 fix: '1713UnicodeInput1-yo.1.cs'.
Installer mantis bug: 7071 fix: '1714UnicodeInput2-yo.1.cs'.
Installer mantis bug: 7071 fix: '1925unixLatin1Input-yo.cs'.
Installer mantis bug: 7071 fix: '1935unicodeFallback-bf.cs'.
"fix end"
nicolas cellier   
11-09-09 18:00   
Fixed in [^] [^] [^]