mquinson/po4a

po4a modifes the msgid from man page

goeranu opened this issue · 0 comments

After having translated the manual page for test.1 to Swedish, I noticed the translation's synopsis comes out incorrect. The underlying problem seems to be that po4a modifies the source, which fooled me into giving an incorrect translation.

More exactly, this line is part of the original manual page:

.B "[\& ]\&"

In the pot file generated by po4a this shows up like this:

msgid "B<[\\& ]\">"

Notice that the final \\& has been changed into \". That is, the roff code for a zero-width mark has become a double quote as part of the string.

(Since this string doesn't actually contain anything to translate, I just copied it to the msgstr, resulting in the double quotes showing up in the final manual page. Now knowing about the bug, I can obviously work around it in this particular case.)

I attach an example with a very much stripped down manual page, and the result of running po4a on it.

po4a-bug.tar.gz