From: Lyre <41...@gm...> - 2011-01-18 14:29:55
|
for example, i have a string in file scope: char *str = "hello world"; int main () { ... } And for some reasons I could not put the string in a function. Is there a way to translate it? Typping ' char *str = _("hello world");' outside of functions would not work. BTW, I noticed virsh in libvirt is able to translate strings in file scope, and their implement looks like this: #define N_(str) str char *str = N_("just an example"); But I'm not able to trace how they did it. |