I would like to have an easy way to write code like:
#include <iostream>
int main (){
std::cout << "hello, world!\n";
}
but supports i18n. The following is an example of use gettext():
#include <libintl.h>
#include <iostream>
int main (){
std::cout << gettext("hello, world!\n");
}
This can then be processed using xgettext to create a message catalog file that translators can use to create different versions. These additional files can be processed on the target system, allowing the user to interact in their preferred language.
I would like to write code something like this:
#include <i18n-iostream>
int main (){
i18n::cout << "hello, world!\n";
}
, xgettext,
. << i18n::cout
literal , .
- ?