[Etoys] How to translate Etoys
Takashi Yamamiya
tak at metatoys.org
Mon Jul 23 19:04:29 EDT 2007
Just a quick report.
I measured how much keywords are covered by new gettext exporter.
Detected keywords by GetTextExporter2: 2630
All known phrases in NaturalLanguageTranslator: 4526
Coverage: 58.1087052585064%
| categories keys diff |
categories := Dictionary new.
GetTextExporter2 new appendStringReceivers: categories.
GetTextExporter2 new appendVocabularies: categories.
keys := categories values
inject: Set new
into: [:set :next | set addAll: next keys;
yourself].
diff := NaturalLanguageTranslator allKnownPhrases keys difference: keys.
Transcript cr; show: 'Detected keywords by GetTextExporter2: ' , keys size printString.
Transcript cr; show: 'All known phrases in NaturalLanguageTranslator: ' , NaturalLanguageTranslator allKnownPhrases size printString.
Transcript cr; show: 'Coverage: ' , (keys size / NaturalLanguageTranslator allKnownPhrases size * 100.0) printString , '%'.
diff inspect
Although, All known phrases includes much unused keywords.
Cheers,
- Takashi
>>> And I notice that some Comments are not too helpful - like, all
>>> comments in Protocols.pot are the same.
>> I know, current one is just a hack. The gettext exporter only works
>> with
>> literal receivers properly. We should fix, but it will need more a
>> week.
>
> Well, if it takes that time so be it. We need to get it right. Btw, I
> think the vocabulary translations belong to the classes they are
> declared in, rather than in a central file.
More information about the Etoys
mailing list