[Etoys] Translating projects
Scott Wallace
scott.wallace at squeakland.org
Thu Sep 27 18:29:11 EDT 2007
Hi, Bert,
Good stuff!
After loading the update, however, I found that when I dropped a
project created in another language, specifically Pierre-Andre's
"traitementSons.015.pr", onto my olpc dev image, I got a message-not-
understood, because "Locale previous" was nil... debug log appended
below.
This is probably a problem only affecting evolved dev images -- an up-
to-date plug-in image didn't have trouble with this. But perhaps
it's still something worth bulletproofing against...
Cheers,
-- Scott
-----
MessageNotUnderstood: UndefinedObject>>localeID
27 September 2007 2:11:48 pm
VM: Mac OS - a SmalltalkImage
Image: etoys2.2 [latest update: #1668]
SecurityManager state:
Restricted: false
FileAccess: true
SocketAccess: true
Working Dir /Users/scottwal/Kazi/etoys2.x/etoys2.2 Fwd
Trusted Dir /foobar/tooBar/forSqueak/bogus
Untrusted Dir /Users/scottwal/Library/Preferences/Squeak/Internet/My
Squeak
UndefinedObject(Object)>>doesNotUnderstand: #localeID
Receiver: nil
Arguments and temporary variables:
aMessage: localeID
Receiver's instance variables:
nil
LocaleID class>>previous
Receiver: LocaleID
Arguments and temporary variables:
Receiver's instance variables:
superclass: Object
methodDict: a MethodDictionary(#displayCountry->a CompiledMethod
(538) #display...etc...
format: 134
instanceVariables: #('isoLanguage' 'isoCountry')
organization: ('initialize' isoLanguage:isoCountry:)
('accessing' displayCountr...etc...
subclasses: nil
name: #LocaleID
classPool: nil
sharedPools: nil
environment: a SystemDictionary(lots of globals)
category: nil
TextMorph>>localeChanged
Receiver: a TextMorph(3447)
Arguments and temporary variables:
locale: #none
oldContents: nil
Receiver's instance variables:
bounds: 3 at 81 corner: 20 at 163
owner: a FlapTab<Help>(367) "Help"
submorphs: #()
fullBounds: 3 at 81 corner: 20 at 163
color: Color black
extension: a MorphExtensionPlus (3233) [locked] [other:
(translations -> a Di...etc...
borderWidth: 0
borderColor: Color black
textStyle: a TextStyle BitstreamVeraSans
text: Text: 'H
e
l
p'
wrapFlag: false
paragraph: a MultiNewParagraph
editor: nil
container: nil
predecessor: nil
successor: nil
backgroundColor: nil
margins: nil
fillStyle: nil
[] in Project>>updateLocaleDependentsWithPreviousSupplies:gently:
{[:morph | morph isTileScriptingElement ifTrue: [morph
localeChanged]. mo...]}
Arguments and temporary variables:
aCollection: nil
gentlyFlag: false
morphs: an IdentitySet(a Morph(2133) a SketchMorph<Green2>(1070) a
NoHaloMorph(...etc...
morph: a TextMorph(3447)
key: nil
class: nil
--- The full stack ---
UndefinedObject(Object)>>doesNotUnderstand: #localeID
LocaleID class>>previous
TextMorph>>localeChanged
[] in Project>>updateLocaleDependentsWithPreviousSupplies:gently:
{[:morph | morph isTileScriptingElement ifTrue: [morph
localeChanged]. mo...]}
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
IdentitySet(Set)>>do:
Project>>updateLocaleDependentsWithPreviousSupplies:gently:
Project>>updateLocaleDependents
Project>>localeChanged
Project>>finalEnterActions
Project>>enter:revert:saveForRevert:
Project>>enter
ProjectEntryNotification>>defaultAction
UndefinedObject>>handleSignal:
MethodContext(ContextPart)>>handleSignal:
MethodContext(ContextPart)>>handleSignal:
ProjectEntryNotification(Exception)>>signal
ProjectEntryNotification(Exception)>>signal:
ProjectEntryNotification class>>signal:
ProjectLoading class>>openName:stream:fromDirectory:withProjectView:
[] in ProjectLoading class>>openOn: {[self openName: nil stream:
aStream fromDirectory: nil withProjectVi...]}
[] in ProjectLoading class>>showProgressBarDuring: {[aBlock value]}
BlockContext>>on:do:
[] in ProjectLoading class>>showProgressBarDuring: {[[aBlock value]
on: ProgressNotification do: [:e | bar value: e mess...]}
BlockContext>>on:do:
[] in ProjectLoading class>>showProgressBarDuring: {[:bar | [[aBlock
value] on: ProgressNotification do: [:e | bar value...]}
[] in ProgressInitiationException>>defaultMorphicAction {[result _
workBlock value: progress]}
BlockContext>>ensure:
ProgressInitiationException>>defaultMorphicAction
ProgressInitiationException>>defaultAction
UndefinedObject>>handleSignal:
ProgressInitiationException(Exception)>>signal
ProgressInitiationException>>display:at:from:to:during:
ProgressInitiationException class>>display:during:
ProjectLoading class>>showProgressBarDuring:
ProjectLoading class>>openOn:
[] in ExternalDropHandler class>>defaultProjectHandler {[:stream |
ProjectLoading openOn: stream]}
ExternalDropHandler>>handle:in:dropEvent:
[] in PasteUpMorph>>dropFiles: {[handler ifNotNil: [handler
handle: stream in: self dropEvent:...]}
BlockContext>>ensure:
PasteUpMorph>>dropFiles:
PasteUpMorph(Morph)>>handleDropFiles:
DropFilesEvent>>sentTo:
...etc...
--------------------------------
On Sep 26, 2007, at 5:38 PM, Bert Freudenberg wrote:
> Just published an update to do this. Seems to work nicely so far, I
> translated the three cloud inscriptions of the launcher to German,
> and they do switch on startup or when selecting a language from the
> toolbar.
>
> To try, just drag out a Text from supplies, change language, edit it,
> switch back.
>
> No way to disable yet, but if there are translations, they are shown
> in the menu.
>
> Not sure how we would handle these translations with external
> developers. We could translate all our example projects to at least
> one other language, and then extract all text morphs that have at
> least two translations. Or, maybe better, have translators translate
> in etoys and send back the translated projects. Then load both our
> master project and the translated one, find the new translations and
> merge into master.
>
> - Bert -
>
> On Sep 22, 2007, at 19:24 , Alan Kay wrote:
>
>> Good idea!
>>
>> Cheers,
>>
>> Alan
>>
>> --------------
>>
>> At 07:58 AM 9/22/2007, Bert Freudenberg wrote:
>>> One thing I thought about was making a Text object be translatable
>>> itself - when switching the locale we would store the previous
>>> translation in a dictionary (in a property of the object). Then the
>>> text could be edited, and when switching back, the old string would
>>> reappear. Hopefully we could make this behavior be the default, but
>>> it should be disabled from the halo menu, which could also show the
>>> other translations in a submenu.
>>>
>>> - Bert -
>>> _______________________________________________
>>> Etoys mailing list
>>> Etoys at lists.laptop.org
>>> http://lists.laptop.org/listinfo/etoys
>>
>
>
> _______________________________________________
> Etoys mailing list
> Etoys at lists.laptop.org
> http://lists.laptop.org/listinfo/etoys
More information about the Etoys
mailing list