Re: Internationalizing Linux

Patrick Kursawe (kursawe@zaphod.anachem.ruhr-uni-bochum.de)
Tue, 8 Dec 1998 15:38:24 +0100 (MET)


On Mon, 7 Dec 1998, Tim Smith wrote:

> A truly horrible kludge I've used in that case is to put this in my code:
>
> printf( msg[code], taskname, condname, taskname );
>
> and in English, msg[code] would be
>
> "Could not do task %s because of condition %s\n"
>

On AmigaOS, the localization issue was solved in this way: You create
a catalog of strings with associated ID numbers with a special program.
This catalog is just copied to a special subdirectory. A locale-aware
program would just open its catalog (without caring for the language) and
ask for the string belonging to an ID number. For the order of parameters,
there are printf-like functions which accept something like %2s (AFAIR)
for printing the second argument to the function.

The Amiga locale system is implemented in a way which allows you to pick a
language on the fly, every program started after the selection will use
it (if there are the right catalogs, of course). For translating a
program, you just need to supply a new .catalog file and copy it to the
right place. This system (locale.library) works quite fine.

Just my 0.00¤, Patrick

-- 
Patrick Kursawe       Patrick.Kursawe@ruhr-uni-bochum.de
Hohenzollernstr. 69   http://www.anachem.ruhr-uni-bochum.de/patrick
45128 Essen           saft://zaphod.anachem.ruhr-uni-bochum.de/kursawe
Who needs windows and gates in a world without walls and fences?

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/