On Wed, Oct 24, 2007 at 01:31:46PM +0400, Vladimir Prus wrote:
Jens Seidel wrote:
On Wed, Oct 24, 2007 at 11:12:28AM +0400, Vladimir Prus wrote: But a gettext approach uses nearly always macros such as _("") and N_(""). If Boost would at least mark all translatable texts using _() or N_() a user who wishs i18n support could define these macros (e.g. by including first a new boost/i18n.h file) and have messages translatable.
but Boost could at least provide PO files containing translations so that users can merge these with own files.
That's what I have in mind. It's not particularly hard, either, since Boost.Build has support for gettext already. The question is whether the will be objections to using tool that is mostly only available on Linux. And, the model of _("") is somewhat
Only available on Linux? Probably you refer to the gettext system call in glibc but isn't/wasn't there also a external library of gettext. (I think a separate copy of gettext is part of many packages using autotools.)
specific to Linux, I think on windows one has to make integer ids.
Not if a const char* gettext(const char*) function is used there too (or are there license issues which make this not possible?).
Actually, .mo might be of use, too, assuming _("") expands to
dgettext("boost", ...)
as opposed to
gettext(...)
which is a good idea anyway. Of course, the main application will be responsible for install .mo files and hooking them in. And given that, .mo is indeed little advantage over translated .po.
I'm not sure whether an application can use multiple message catalogs ... PS: I could provide the German translation if wanted. Jens