Hi,<div><br></div><div>David's recent comments on the Sword mailing list seem relevant. They might imply that a more limited list of languages might be acceptable and he also mentions the approach taken by Xiphos. He says:</div>
<blockquote class="webkit-indent-blockquote" style="margin: 0 0 0 40px; border: none; padding: 0px;"><div>"<span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; ">Referring to <a href="http://www.crosswire.org/wiki/DevTools:confFiles" target="_blank" style="color: rgb(0, 0, 204); ">http://www.crosswire.org/wiki/DevTools:confFiles</a></span></div>
<span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; ">the only language related element is lang itself.</span><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; "><br>
</span><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; ">This means that when a front-end encounters a new module for which it cannot<br></span><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; ">yet provide a look-up for the localized language name, it will show Unknown<br>
</span><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; ">as the name of the language. That's what Xiphos does, for example.</span><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; "><br>
</span><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; ">As a fall-back position, might it be sensible to allow the conf file to<br></span><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; ">optionally include the localized language name in addition to the lang<br>
</span><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; ">element?</span><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; "><br>
</span><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; ">This would be processed as follows:</span><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; "><br>
</span><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; ">If the lang identifier can be looked up, use the look-up value.<br></span><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; ">If not, then if the conf file includes the localized language name, use<br>
</span><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; ">that.<br></span><span class="Apple-style-span" style="font-family: arial, sans-serif; font-size: 13px; border-collapse: collapse; ">Then if not either, fall back to using unknown, as at present.<span class="Apple-style-span" style="border-collapse: separate; font-family: arial; font-size: small; ">"</span></span></blockquote>
<div><br></div><div>Regards</div><div>Martin<br><br><div class="gmail_quote">On 22 December 2010 22:42, Martin Denham <span dir="ltr"><<a href="mailto:mjdenham@gmail.com">mjdenham@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
I was wondering if we need the iso639 properties files if the language codes and names returned by the standard Locale class contained all the codes and names that are in the large properties file - I don't know if they do. Using Locale could (I think) also automatically give us locale specific country names automatically for all Locales e.g. Angličtina instead of English on Czech mobiles.<div>
<br></div><div>I haven't tried this out yet and we are only talking about 2 secs at startup but I am trying to whittle away the 17 secs it currently takes to start up JSword-And Bible. However, this does possibly give other advantages.<div>
<div></div><div class="h5"><br>
<br><div class="gmail_quote">On 22 December 2010 18:04, DM Smith <span dir="ltr"><<a href="mailto:dmsmith@crosswire.org" target="_blank">dmsmith@crosswire.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
I've gone back and forth on this one. The goal is to have names for all the codes. There are a bunch of minority languages with Bibles in beta that this covers.<br>
<br>
The simplest solution is to rename the _en file to be the default.<br>
<br>
The bigger problem is that the confs are fully read on startup which is in necessary. This is causing the Lang lookup.<br>
<br>
In Him,<br>
DM<br>
<br>
Cent from my fone so theer mite be tipos. ;)<br>
<div><div></div><div><br>
On Dec 22, 2010, at 7:07 AM, Martin Denham <<a href="mailto:mjdenham@gmail.com" target="_blank">mjdenham@gmail.com</a>> wrote:<br>
<br>
> I have occasionally tried to improve the slow start-up times of And Bible & JSword without much success. However, one area which I have a suspicion may take time is property file loading.<br>
><br>
> I run out of memory part way through when profiling startup but I notice iso639.properties which has 7600 lines can take 2 seconds to load up on slow phones. I wonder if, instead of storing the language codes in properties files we could use methods like Locale.getDisplayLanguage(loc) and other Locale methods to completely remove the need for the iso639 properties files.<br>
><br>
> What do you think?<br>
><br>
> Regards<br>
> Martin<br>
><br>
</div></div><div><div></div><div>> _______________________________________________<br>
> jsword-devel mailing list<br>
> <a href="mailto:jsword-devel@crosswire.org" target="_blank">jsword-devel@crosswire.org</a><br>
> <a href="http://www.crosswire.org/mailman/listinfo/jsword-devel" target="_blank">http://www.crosswire.org/mailman/listinfo/jsword-devel</a><br>
<br>
_______________________________________________<br>
jsword-devel mailing list<br>
<a href="mailto:jsword-devel@crosswire.org" target="_blank">jsword-devel@crosswire.org</a><br>
<a href="http://www.crosswire.org/mailman/listinfo/jsword-devel" target="_blank">http://www.crosswire.org/mailman/listinfo/jsword-devel</a><br>
</div></div></blockquote></div><br></div></div></div>
</blockquote></div><br></div>