[Debian-handbook-translators] Help wanted

Daniel Leidert dleidert at debian.org
Sat Sep 4 17:30:28 BST 2021


x-posting this back to debian-handbook-translators

Am Samstag, dem 04.09.2021 um 13:37 +0900 schrieb Norbert Preining:

> Well, dblatex produces incorrect LaTeX code, so nothing we can do about
> this: The generated code is
>         \begin{lstcode}[escapeinside={<:}{:>}][scale=false,firstnumber=1,esca
> peinside={<t>}{</t>},moredelim={**[is][\bfseries]{<b>}{</b>}},moredelim={**[i
> s][\itshape]{<i>}{</i>}},]
> 
> which is of the form
> 
>         \begin{lstcode}[opts][opts]
> 
> which should be
> 
>         \begin{lstcode}[opts,opts]
> 
> Manually changing this makes the file compile.

Thanks for the explanation. dblatex produces the same for lstlisting, but that
doesn't fail. It just generates a warning. So this is a genuine bug.

After digging into the issue further, the problem is that
/usr/lib/python3/dist-packages/dbtexmf/dblatex/rawverb.py adds the

[escapeinside={<:}{:>}]

sequence instead of adding it inside the existing options added by
/usr/share/xml/docbook/stylesheet/dblatex/xsl/verbatim.xsl already. I think we
need to fix the issue here by checking for existing options and adding the
escapeinside option to them instead of adding another pair of brackets. Maybe
we just need to fix the search pattern? Anybody with enough Python knowledge to
write a patch? I'll have a look at it myself, but I'd prefer to keep updating
the handbook if possible.

Regards, Daniel
-- 
Regards,
Daniel Leidert <dleidert at debian.org> | https://www.wgdd.de/
GPG-Key RSA4096 / BEED4DED5544A4C03E283DC74BCD0567C296D05D
GPG-Key ED25519 / BD3C132D8B3805D1808123AB7ACE00941E338C78

https://www.fiverr.com/dleidert
https://www.patreon.com/join/dleidert
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part
URL: <http://alioth-lists.debian.net/pipermail/debian-handbook-translators/attachments/20210904/27ac4c90/attachment.sig>


More information about the Debian-handbook-translators mailing list