consiglio tecnico su gettext e i18n

Danilo Piazzalunga danilopiazza@libero.it
Gio 24 Feb 2005 14:00:10 CET


On Thursday 24 February 2005 12:47, Marco Colombo wrote:
> >Should I do this? I was under the impression that building string from
> >fragments is not considered good practise from the i18n POV. Please
> >enlighten me here :) Is it a good idea to build the strings in a way
> >like this:
> >
> >s = _("%i packages listed, %i installed, %i broken. %i to install/upgrade,
> > %i to remove")
> >
> >and build the other two with it?
> >
> >_("%s; %s will be used", s, space)
> >_("%s; %s will be freed", s, space)
> >
> >Couldn't it e.g. cause trouble with left-to-right languages (just a
> >guess/concern)?
>
> qualcuno sa rispondere a questo dubbio? magari con indicazioni a qualche
> documento su web, di modo che posso indicarlo al responsabile? grazie
> mille!

Forse ho esagerato un po' nel proporti un merge cosė aggressivo... L'ideale 
per farlo sarebbe

s = _("%i packages listed, etc. etc.")
t = _("%s will be freed")

e infine

sprintf(_("%s; %s"), s, t)

Ma per messaggi cosė corti forse č un po' eccessivo, mentre ne varrebbe la 
pena per stringhe lunghe almeno due o tre righe (o ripetute molte pių volte).


Sul web trovi:
http://www.mozilla.org/docs/refList/i18n/l12yGuidelines.html
http://developer.gnome.org/doc/tutorials/gnome-i18n/developer.html


Ciao e scusami ancora per averti messo questo dubbio :-)

Danilo


Maggiori informazioni sulla lista tp