Package: po4a
Version: 0.72-1
Severity: wishlist

groff 1.23 introduces the macro .MR for references like "groff(1)".
Using --option translate_joined or --option untranslated this macro
can be considered for translation.

However, this is not very good. Consider the following examples 
from groff(1):

Run eqn(1) preprocessor.

.
.TP
.B \-e
Run
.MR \%eqn 1
preprocessor.
.

This is now 3 paragraphs in the po file:
#. type: Plain text
msgid "Run"
msgstr ""

#. type: MR
#, no-wrap
msgid "\\%eqn 1"
msgstr ""

#. type: Plain text
msgid "preprocessor."
msgstr ""

As you can see, po strings may become very short. Some 
paragraphs are now a few po strings in the file, making it clumsy to
translate, especially if the "MR" part is the last in the english
sentence, but should be somewhere else in the translated sentence.

Or:
A
.MR man 1
librarian program \" such as man-db, since 2001
may use this macro file to delegate loading of the correct macro
…

which becomes

#. type: Plain text
msgid "A"
msgstr ""

#. type: MR
#, no-wrap
msgid "man 1"
msgstr ""

#.  such as man-db, since 2001
msgid ""
"librarian program may use this macro file to delegate loading of the correct "
"macro package; it is thus unnecessary for I<man> itself to scan the contents "
"of a document to decide the issue."
msgstr ""

Here, you have the problem that "A" can be translated as "Ein", "Eine" oder 
"Einer" in German, so if this occurs multiple times, you might not be able to 
correctly translate it. Fortunately, current groff(1) uses this one
only once.

Maybe you can implement it like B<> and I<>, e.g. using R<> for
"reference" or simmilar?


groff(1) has some fallback code for older groffs, maybe you can use
this as starting point for implementation?
.\" Define fallback for groff 1.23's MR macro if the system lacks it.
.nr do-fallback 0
.if !\n(.f           .nr do-fallback 1 \" mandoc
.if  \n(.g .if !d MR .nr do-fallback 1 \" older groff
.if !\n(.g           .nr do-fallback 1 \" non-groff *roff
.if \n[do-fallback]  \{\
.  de MR
.    ie \\n(.$=1 \
.      I \%\\$1
.    el \
.      IR \%\\$1 (\\$2)\\$3
.  .
.\}
.rr do-fallback

Thank you very much for considering.


-- System Information:
Debian Release: trixie/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: amd64 (x86_64)

Locale: LANG=de_DE.UTF-8, LC_CTYPE=de_DE.UTF-8 (charmap=UTF-8) (ignored: LC_ALL 
set to de_DE.UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages po4a depends on:
ii  gettext                     0.21-14+b1
ii  libpod-parser-perl          1.67-1
ii  libsgmls-perl               1.03ii-38
ii  libsyntax-keyword-try-perl  0.29-2
ii  libyaml-tiny-perl           1.74-1
ii  opensp                      1.5.2-15
ii  perl                        5.38.2-5

Versions of packages po4a recommends:
ii  liblocale-gettext-perl     1.07-7
ii  libterm-readkey-perl       2.38-2+b3
ii  libtext-wrapi18n-perl      0.06-10
ii  libunicode-linebreak-perl  0.0.20190101-1+b7

po4a suggests no packages.

-- no debconf information

-- 
      Dr. Helge Kreutzmann                     deb...@helgefjell.de
           Dipl.-Phys.                   http://www.helgefjell.de/debian.php
        64bit GNU powered                     gpg signed mail preferred
           Help keep free software "libre": http://www.ffii.de/

Attachment: signature.asc
Description: PGP signature

Reply via email to