About 7051 and Multilingual-TextConversion

Lic. Edgar J. De Cleene edgardec2001 at yahoo.com.ar
Thu Aug 3 12:03:50 UTC 2006


Marcus Denker puso en su mail :

> - I have no problem with "TextMorph fileOut" on 7051 (the new one).
> - .changes and .sources do have different encoding right now... this
>    will be fixed as soon as we write a new .sources (yet another
> reason to do
>     so).
Ok I download the new one.

> what does that have to do with FFI?

Nothing. I mean what he put in his answer

> I'll note that if you have a string (8 bits) in Squeak you must
> decide what the bits mean, is that a
> latin 1 string, a mac roman, or something else.
> 
> 
>     converter := Smalltalk platformName = 'Mac OS'
>         ifTrue:  [MacRomanUnicodeTextConverter new]
>         ifFalse: [Latin1TextConverter new].
>     wideStringMangled := string convertFromWithConverter: converter.

I could do the fileOut in my image with

'From Squeak3.9alpha of 4 July 2005 [latest update: #7051] on 3 August 2006
at 9:00:16 am'!

!PositionableStream methodsFor: 'fileIn/Out' stamp: 'edc 8/3/2006 08:27'!
copyMethodChunkFrom: aStream
    "Copy the next chunk from aStream (must be different from the
receiver)."
    | chunk |
    aStream converter: Latin1TextConverter new. "this fixes the problem for
me."
    chunk := aStream nextChunkText.
    chunk runs values size = 1 "Optimize for unembellished text"
        ifTrue: [self nextChunkPut: chunk asString]
        ifFalse: [self nextChunkPutWithStyle: chunk]! !

Again thanks, and yes, a new .changes and .sources in only a format could
help all.
What format you choose ?

Edgar



	
	
		
__________________________________________________
Preguntá. Respondé. Descubrí.
Todo lo que querías saber, y lo que ni imaginabas,
está en Yahoo! Respuestas (Beta).
¡Probalo ya! 
http://www.yahoo.com.ar/respuestas




More information about the Squeak-dev mailing list