<div id="__MailbirdStyleContent" style="font-size: 10pt;font-family: Arial;color: #000000">
                                        
                                        
                                            
                                        
                                        
                                        Hi Vanessa.<div><br></div><div>> <span style="font-family: Arial, Helvetica, sans-serif;font-size: 13px">There probably should be an early return if there are no translations (as is the case with trunk images, I think?).</span></div><div><span style="font-family: Arial, Helvetica, sans-serif;font-size: 13px"><br></span></div><div><span style="font-family: Arial, Helvetica, sans-serif;font-size: 13px">Last time the translations where updated (or merged from Etoys) was with the 5.1 release. Tim (tfel) also used some automation to do that. Since then, we have added more #translated calls and corrected existing ones as well. So, even in a 5.2 oder 5.3 release, there are likely to be a lot of misses and thus a lot of calls to #</span><span style="font-size: 10pt">translatedInAllDomains.</span></div><div><span style="font-size: 10pt"><br></span></div><div><span style="font-size: 10pt">Well, instead of supporting the '*' domain, we could also just remove that behavior. Not optimal but a quick workaround. Not sure how often that helps anyway. For example, having a "Yes -> Ja" translation for one domain might as well apply to another domain. But that itself looks like a workaround for poor translation jobs. :-D</span></div><div><span style="font-size: 10pt"><br></span></div><div><span style="font-size: 10pt">Best,</span></div><div><span style="font-size: 10pt">Marcel</span></div><div class="mb_sig"></div>
                                        
                                        <blockquote class="history_container" type="cite" style="border-left-style: solid;border-width: 1px;margin-top: 20px;margin-left: 0px;padding-left: 10px;min-width: 500px">
                        <p style="color: #AAAAAA; margin-top: 10px;">Am 28.10.2020 19:49:31 schrieb Vanessa Freudenberg <vanessa@codefrau.net>:</p><div style="font-family:Arial,Helvetica,sans-serif">
<div dir="ltr"><div>The mechanism assumes that basically all translation files are loaded so a match is found quickly. There probably should be an early return if there are no translations (as is the case with trunk images, I think?).</div><div><br></div><div>- Vanessa -</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Oct 28, 2020 at 1:53 AM Marcel Taeumel <<a href="mailto:marcel.taeumel@hpi.de">marcel.taeumel@hpi.de</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin: 0px 0px 0px 0.8ex;border-left: 1px solid rgb(204,204,204);padding-left: 1ex;min-width: 500px"><div id="gmail-m_7675254145361433566__MailbirdStyleContent" style="font-size: 10pt;font-family: Arial;color: rgb(0,0,0)">
                                        
                                        
                                            
                                        
                                        
                                        Hi Eliot.<div><br></div><div>Hmm... in 2010 there was a change in String >> #translated to also include some kind of domain knowledge based on "thisContext sender method". (I suppose it got merged with all Etoys changes in Squeak 5.1).</div><div><br></div><div>['world' translated] bench.</div><div>---NO DOMAIN LOOKUP --- '847,000 per second. 1.18 microseconds per run. 3.69926 % GC time.'</div><div>---DO DOMAIN LOOKUP  --- '9,190 per second. 109 microseconds per run. 3.57928 % GC time.'</div><div><br></div><div>Given that there are 1558 senders in a Trunk image, this might be worth improving. :-)</div><div><br></div><div>I propose to change #translatedInAllDomains, which is kind of a "detect" looking desperately for some translation that has not the given form.... enumerating all package names along the way to be used as domain names.</div><div><br></div><div>Domain names are for GetText support. Each .mo file can represent a different domain. Such a modular separation helps external tools (and humans) to better browse and understand the kind of translation that is needed. It's rather common practice, I suppose.</div><div><br></div><div>Maybe we should just support a wildcard '*' as valid domain name and then let the GetTextTranslator figure out how to enumerate all the accessible .mo files?</div><div><br></div><div><div><span style="font-size: 13.3333px">String >> translatedInAllDomains</span></div><div><span style="font-size: 13.3333px"><span style="white-space:pre-wrap">    </span>^self translatedTo: LocaleID current inDomain: '*'</span></div></div><div><br></div><div>['world' translated] bench.<br></div><div><span style="font-size: 13.3333px">---WILDCARD---  '408,000 per second. 2.45 microseconds per run. 1.55938 % GC time.'</span><br></div><div><br></div><div>Now somebody has to change GetTextTranslator. I hope it does not break any generic GetText support to enumerate all .mo files in a locale directory.</div><div><br></div><div>Best,</div><div>Marcel</div><div></div>
                                        
                                        <blockquote type="cite" style="border-left-style: solid;border-width: 1px;margin-top: 20px;margin-left: 0px;padding-left: 10px;min-width: 500px">
                        <p style="color:rgb(170,170,170);margin-top:10px">Am 28.10.2020 06:59:07 schrieb Eliot Miranda <<a href="mailto:eliot.miranda@gmail.com" target="_blank">eliot.miranda@gmail.com</a>>:</p><div style="font-family:Arial,Helvetica,sans-serif">
<div dir="ltr"><div dir="ltr"><div style="font-size: 14pt">Hi All,</div><div style="font-size: 14pt"><br></div><div style="font-size: 14pt">    I have occasion to simulate the simulator (chancing down a context manipulation bug).  In doing so I notice that there seems to be some awful ) N^2 behaviour in doing things as straight-forward as setting up the world menu.  Here's a back trace from the simulator of a current trunk image:</div><div style="font-size: 14pt"><br></div><div style="font-size: 14pt"><div>  16r3061C8 M Dictionary>associationsDo: 16r16BC028: a(n) Dictionary</div><div>  16r306200 M Dictionary>keysDo: 16r16BC028: a(n) Dictionary</div><div>  16r306238 M [] in Dictionary>keys 16r16BC028: a(n) Dictionary</div><div>  16r306280 M Array class(SequenceableCollection class)>new:streamContents: 16r16FA068: a(n) Array class</div><div>  16r3062C0 M Dictionary>keys 16r16BC028: a(n) Dictionary</div><div>  16r3062F0 M PackageOrganizer>packageNames 16r1540BE8: a(n) PackageOrganizer</div><div>  16r306320 M TextDomainManager class>allKnownDomains 16r188A848: a(n) TextDomainManager class</div><div>  16r306358 M ByteString(String)>translatedInAllDomains 16r3479FF8: a(n) ByteString</div><div>  16r306390 M ByteString(String)>translated 16r3479FF8: a(n) ByteString</div><div>  16r3063D8 M [] in TheWorldMenu>fillIn:from: 16r3C93C0: a(n) TheWorldMenu</div><div>  16r303F38 M Array(SequenceableCollection)>do: 16rB681C8: a(n) Array</div><div>  16r303F70 M TheWorldMenu>fillIn:from: 16r3C93C0: a(n) TheWorldMenu</div><div>  16r303FC0 I TheWorldMenu>addSaveAndQuit: 16r3C93C0: a(n) TheWorldMenu</div><div><br></div><div>I.e. for every item in the world menu we are enumerating over all packages.  Shurely shome mistake, hic!, ed.</div></div><div dir="ltr"><div dir="ltr"><div><span style="font-size: 10pt;border-collapse: separate"><div>_,,,^..^,,,_<br></div><div>best, Eliot</div></span></div></div></div></div></div>
</div></blockquote></div><br>
</blockquote></div></div>
</div></blockquote></div>