Re: [AD] allegrowww updates

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


On 2008-06-22, Elias Pschernig <elias@xxxxxxxxxx> wrote:
> > Serves me well for being dead so long.
> 
> Welcome back!

Last week I got internet at home, so at least I should be able to answer
email with less delays.

> Yeah, something which allows to use all the gettext tools. Back when you
> implemented the translation system for the website, gettext probably
> didn't even exist yet - but seems to be some kind of standard in open
> source projects by now. With those mentioned really useful and easy to
> use tools.

Gettext is plenty old, however it has a different aim, and just because
it is there I find many people using it when it is not really that good.
AFACS gettext was the first open effort to make a library where you
would be able to translate strings in C source. And by C source, it is
usually targetted at already written C source, so you have these ugly
macros to wrap around your literals and stuff like that.

However, if you start a new program, why would you bother doing such a
hack? It is much more efficient and maintenable storing all i18n
literals in an external file, load them at runtime and use numerical
constants in your source. Reading code with number is not that fun
though, so near each number I write a comment that includes the first
words of the message. Then have a source scanner that can update those
comments to refresh them if the external string changes.

Gettext still has the advantage of not being a one person hack, and many
people have worked on it. Even though it is overcomplicated for simple
things, many interfaces exist, and possibly the best would be something
like a web collaborative interface:

  http://translate.sourceforge.net/wiki/pootle/index

It would be nice if web sites had some sort of feeding text into that to
let others translate them.




Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/