Re: how to translate software into other languages



Kaixo!

On Tue, Apr 03, 2001 at 12:28:45PM +0200, Raphael Zulliger wrote:

> i'm new to this list and also new to create software...
> 
> i've got a genereal question: i've programmed a little program now
> someone has asked me to translate the software into an other language.
...
> does anybody know of a tutorial, a howto or something else where i can
> get information about this topic? or could anybody give me a short
> introduction (but very basic please)?

There may be better material available (and that is an area where good
tutorials are needed), but here is a small thing I wrote some time ago
(result of my own experiences): http://chanae.stben.be/pablo/i18n/tutorial.var

If you use glade it should be even easier, everythign technical should
already be done.


In short the principle is simple:

- All translatable strigns are wrapped with _( ) (which is a macro that
actually calls gettext(), gettext is a function that gets a string as
argument and retruns a string that is either the translation of that
string or the string itself if no translation is available)
- in the beginning of the main() the environment is checked to know the
language the user has chosen, so the right translations can be displayed.

Yes, is that simple.

However, there are other things to keep in mind:


> 
> 
> thanks!
> raphael
> 
> _______________________________________________
> gnome-i18n mailing list
> gnome-i18n@gnome.org
> http://mail.gnome.org/mailman/listinfo/gnome-i18n

-- 
Ki ça vos våye bén,
Pablo Saratxaga

http://www.srtxg.easynet.be/		PGP Key available, key ID: 0x8F0E4975




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]