Michael Geng wrote: > My intention is in fact to invoke xgettext on the parser files which > genparse generates. ... You can watch the genparse > generated parser for it from > http://genparse.sourceforge.net/examples/wc_clp.c.
OK, this kind of generated code is not bad; it's acceptable to have translators look at it. But there are still two problems: 1) The gettext documentation [1] recommends to not make the _() arguments unnecessarily large. printf (_("\ --files0-from=F read input from the files specified by\n\ NUL-terminated names in file F\n\ -L, --max-line-length print the length of the longest line\n\ -w, --words print the word counts\n")); This is too large. When the maintainer adds another option, the translator should not have to re-proofread the 3 existing options. So you should better generate code like this: printf (_("\ --files0-from=F read input from the files specified by\n\ NUL-terminated names in file F\n")); printf (_("\ -L, --max-line-length print the length of the longest line\n")); printf (_("\ -w, --words print the word counts\n")); 2) What about translator comments? How can a maintainer provide additional information for the translators? Does this work? /* TRANSLATORS: the length here is actually the screen width */ L / max-line-length flag "print the length of the longest line" /* TRANSLATORS: Keep the colons aligned. */ Usage: __PROGRAM_NAME__ [OPTION]... [FILE]... or: __PROGRAM_NAME__ [OPTION]... --files0-from=F__NEW_PRINT__ Bruno [1] http://www.gnu.org/software/gettext/manual/html_node/Preparing-Strings.html _______________________________________________ Bug-coreutils mailing list Bug-coreutils@gnu.org http://lists.gnu.org/mailman/listinfo/bug-coreutils