[Pharo-project] Issue 3670 in pharo: Fixes for Latin1Environment from EToys

pharo at googlecode.com pharo at googlecode.com
Sun Feb 6 21:44:19 CET 2011


Status: FixedWaitingToBePharoed
Owner: stephane... at gmail.com
Labels: Type-Squeak Milestone-1.3

New issue 3670 by stephane... at gmail.com: Fixes for Latin1Environment from  
EToys
http://code.google.com/p/pharo/issues/detail?id=3670


Name: Multilingual-sn.131
Author: sn
Time: 8 November 2010, 12:54:12.262 am
UUID: 64aa8ddf-9938-4373-a45d-7bde1c0ccced
Ancestors: Multilingual-ul.130

Fixes for Latin1Environment from EToys

=============== Diff against Multilingual-ul.130 ===============

Item was changed:
  ----- Method: Latin1Environment class>>fileNameConverterClass (in  
category 'subclass responsibilities') -----
  fileNameConverterClass

+       ^ self systemConverterClass
-       ^ Latin1TextConverter
  !

Item was changed:
  ----- Method: Latin1Environment class>>inputInterpreterClass (in  
category 'subclass responsibilities') -----
  inputInterpreterClass
        | platformName osVersion |
        platformName := SmalltalkImage current platformName.
        osVersion := SmalltalkImage current osVersion.
        (platformName = 'Win32' and: [osVersion ~= 'CE'])
                ifTrue: [^ (self win32VMUsesUnicode) ifTrue:  
[UTF32InputInterpreter] ifFalse: [MacRomanInputInterpreter]].
        platformName = 'Mac OS'
+               ifTrue: [^ MacUnicodeInputInterpreter].
-               ifTrue: [^ MacRomanInputInterpreter].
        platformName = 'unix'
                ifTrue: [^ UTF32InputInterpreter].
+       ^ MacUnicodeInputInterpreter!
-       ^ MacRomanInputInterpreter!

Item was changed:
  ----- Method: Latin1Environment class>>systemConverterClass (in  
category 'subclass responsibilities') -----
  systemConverterClass

+       | platformName osVersion |
+       platformName := SmalltalkImage current platformName.
+       osVersion := SmalltalkImage current getSystemAttribute: 1002.
+       (platformName = 'Win32'
+                       and: [osVersion = 'CE'])
+               ifTrue: [^ MacRomanTextConverter].
+       platformName = 'Win32'
+               ifTrue: [^ (self win32VMUsesUnicode) ifTrue:  
[UTF8TextConverter] ifFalse: [Latin1TextConverter]].
+       platformName = 'Mac OS'
+               ifTrue: [^ ('10*' match: SmalltalkImage current osVersion)
+                               ifTrue: [UTF8TextConverter]
+                               ifFalse: [MacRomanTextConverter]].
+       platformName = 'unix'
+               ifTrue: [^ UTF8TextConverter].
+       ^ MacRomanTextConverter!
-       ^ Latin1TextConverter.
- !

Item was changed:
  ----- Method: MacUnicodeInputInterpreter>>initialize (in  
category 'initialization') -----
  initialize
        | satisfiesVersion |
        satisfiesVersion := self
                                majorMinorBuildFrom: SmalltalkImage current  
vmVersion
+                               satisfies: [:major :minor :build |
+                                       major >= 4 or: [
+                                       major >= 3 and: [minor >= 8 and:  
[build >= 7]]]].
-                               satisfies: [:major :minor :build |  (major  
>= 3
-                                               and: [minor >= 8
-                                                               and: [build  
>= 7]]) or: [major >= 4]].
-
        satisfiesVersion
                ifTrue: [keyValueIndex := 6]
                ifFalse: [keyValueIndex := 3]!






More information about the Pharo-project mailing list