<div class="gmail_quote">On Thu, Jan 10, 2013 at 7:25 PM, Hans-Christoph Steiner <span dir="ltr"><<a href="mailto:hans@at.or.at" target="_blank">hans@at.or.at</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im">On 01/10/2013 12:36 PM, András Murányi wrote:<br>
> On Wed, Jan 9, 2013 at 5:35 PM, Hans-Christoph Steiner <<a href="mailto:hans@at.or.at">hans@at.or.at</a>>wrote:<br>
><br>
>><br>
>> Since Tcl handles all of the changing of English strings to the chosen<br>
>> language,<br>
><br>
><br>
> Does it mean that there are no GUI strings in the C code?<br>
<br>
</div>There are GUI strings in the C code, but in order for you to see them, they<br>
are sent to pd-gui, the Tcl process. If you're running in -nogui mode, there<br>
will be no translations since all the translations are handled in Tcl.<br>
</blockquote><div><br>Ah! BTW, would it take much to have gettext working on the C side too?<br><br> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im">
<br>
>> it is theoritically possible to do in a plugin. The key problem is<br>
>> that the translations are loaded (load_locale in pd-gui.tcl) before the<br>
>> plugins and Tcl's msgcat, the library for the translations, provides<br>
>> mcload,<br>
>> but no mkunload.<br>
>><br>
><br>
> To be exact, not even mcunload would be necessary, just a way to reload<br>
> strings according to the new locale. Unfortunately, this functionality is<br>
> missing from TCL (there are some feature requests in the tracker that<br>
> target it, though).<br>
> So, to effectively change the GUI language, Pd needs to be restarted. Do we<br>
> wish to have a language selection option in the preferences, which writes<br>
> its setting somewhere on the disk, and then load_locale would be changed in<br>
> a way that it takes a look at the saved setting before defaulting to the<br>
> OS/env language? (my vote is: no)<br>
<br>
</div>That would be possible. I would be willing to accept such a patch if it was<br>
well tested but I'm not going to write it :)<br>
<span class="HOEnZb"><font color="#888888"><br>
.hc<br>
</font></span></blockquote><div><br>Well I shall not take on more things (but to carry on with things that I've already started), but... :)<br>This stuff would actually be another driver for me to dive into the prefs system... and eventually evolve that a bit, too*.<br>
<br>* right now the guiprefs system is geared towards the recentfiles list, and it might need some mods to serve other purposes as well.<br><br></div></div> András