[Gtk-sharp-list] New (stupid) application :)

David Makovský (Yakeen) yakeen@sannyas-on.net
Fri, 14 Nov 2003 14:16:18 +0100


--=-jL+yxHWXiHLTwsCxPCBx
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

V P=C3=A1, 14. 11. 2003 v 13:33, Jonathan Pryor p=C3=AD=C5=A1e:

> Inline...
>=20
> On Fri, 2003-11-14 at 04:56, David Makovsk=C3=BD (Yakeen) wrote:
> <snip/>
> > public void LocalizeGui(){
> > 	process_def_dialog.Title =3D _("...");
> > 	info_label.Text =3D MARKUP_PRE + _("...") + MARKUP_POST;
> > 	info_label.UseMarkup =3D true;
> > 	cavity_label.Text =3D MARKUP_PRE + _("...") + MARKUP_POST;
> > 	cavity_label.UseMarkup =3D true;
> > 		=09
> > 	name_label.Text =3D _("...");
> > 	inuse_checkbutton.Label =3D _("...");
> > 		=09
> > 	cavity1_button.Label =3D _("...");
> > 	cavity2_button.Label =3D _("...");
> > }
>=20
> I don't like this solution at all, because it causes string duplication
> between the .glade file and the application.
> At worst, this is annoying, but I despise all forms of duplication.
> I suppose that, for strings within glade, we could have multiple
> different glade files, and then use the resource manager to determine
> which file to use. :-)
>=20
> Alas, this doesn't hook up with the .po file system, but at least when
> you're editing the .glade file, you don't need to worry about
> duplicating all the strings in the resource manager.  You just
> copy/rename the .glade file for each language, and lookup the language
> (file) to use at runtime.
>=20
>  - Jon


Agree, duplication isn't looking great, but this is only one solution
that I found (exept your othet one with more .glade files ;)
But you are not forced to have duplication, cause strings are getting
only from cs files....=20
Yes this is not hooking up with gettext this cannot cause it is using
System.Resources and this one is win based, I think that solution from
Win side
will come with .Net 1.2 with the new XML based gui description language
for Longhorn, til now who knows...
I would be glad to have better translation string handlig process.
Kind Regards

--=20
David Makovsk=C3=BD (Yakeen) <yakeen@sannyas-on.net>

--=-jL+yxHWXiHLTwsCxPCBx
Content-Type: text/html; charset=utf-8
Content-Transfer-Encoding: 7bit

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 TRANSITIONAL//EN">
<HTML>
<HEAD>
  <META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=UTF-8">
  <META NAME="GENERATOR" CONTENT="GtkHTML/3.0.9">
</HEAD>
<BODY>
V P&#225;, 14. 11. 2003 v 13:33, Jonathan Pryor p&#237;&#353;e:
<BLOCKQUOTE TYPE=CITE>
<PRE><FONT COLOR="#555050"><I>Inline...

On Fri, 2003-11-14 at 04:56, David Makovsk&#253; (Yakeen) wrote:
&lt;snip/&gt;
&gt; public void LocalizeGui(){
&gt; 	process_def_dialog.Title = _(&quot;...&quot;);
&gt; 	info_label.Text = MARKUP_PRE + _(&quot;...&quot;) + MARKUP_POST;
&gt; 	info_label.UseMarkup = true;
&gt; 	cavity_label.Text = MARKUP_PRE + _(&quot;...&quot;) + MARKUP_POST;
&gt; 	cavity_label.UseMarkup = true;
&gt; 			
&gt; 	name_label.Text = _(&quot;...&quot;);
&gt; 	inuse_checkbutton.Label = _(&quot;...&quot;);
&gt; 			
&gt; 	cavity1_button.Label = _(&quot;...&quot;);
&gt; 	cavity2_button.Label = _(&quot;...&quot;);
&gt; }

I don't like this solution at all, because it causes string duplication
between the .glade file and the application.
At worst, this is annoying, but I despise all forms of duplication.
I suppose that, for strings within glade, we could have multiple
different glade files, and then use the resource manager to determine
which file to use. :-)

Alas, this doesn't hook up with the .po file system, but at least when
you're editing the .glade file, you don't need to worry about
duplicating all the strings in the resource manager.  You just
copy/rename the .glade file for each language, and lookup the language
(file) to use at runtime.

 - Jon</I></FONT></PRE>
</BLOCKQUOTE>
<BR>
Agree, duplication isn't looking great, but this is only one solution that I found (exept your othet one with more .glade files ;)<BR>
But you are not forced to have duplication, cause strings are getting only from cs files.... <BR>
Yes this is not hooking up with gettext this cannot cause it is using System.Resources and this one is win based, I think that solution from Win side<BR>
will come with .Net 1.2 with the new XML based gui description language for Longhorn, til now who knows...<BR>
I would be glad to have better translation string handlig process.<BR>
Kind Regards
<PRE><TABLE CELLSPACING="0" CELLPADDING="0" WIDTH="100%">
<TR>
<TD>
-- <BR>
David Makovsk&#253; (Yakeen) &lt;<A HREF="mailto:yakeen@sannyas-on.net"><U>yakeen@sannyas-on.net</U></A>&gt;
</TD>
</TR>
</TABLE>
</PRE>
</BODY>
</HTML>

--=-jL+yxHWXiHLTwsCxPCBx--