Problems with the listings package
Hoffmann, Jobst
j.hoffmann at fh-aachen.de
Fri Jan 24 18:12:35 CET 2025
Hello Karl,
I wanted to prepare the next version of the listings package v1.11.
v1.11 is needed, because there is an error since v1.3b, you can see the
error by formatting the attached file list_tex.tex.
The documentation says:
stepnumber=number
All lines with “line number ≡ 0 modulo number” get a line number. If
you
turn line numbers on and off with numbers, the parameter stepnumber
will
keep its value. Alternatively you can turn them off via stepnumber=0
and
on with a nonzero number, and keep the value of numbers.
numberfirstline=true|false
The first line of each listing gets numbered (if numbers are on at all)
even if
the line number is not divisible by stepnumber.
In list_test.tex the first line of the first snippet gets wrongly a 1,
the second snippet is ok.
This error was introduced by Carsten with the patch for v1.3b (Oct.
that 2002), Matt copied this patch directly into listings.dtx v1.4, so
at least the command \lst at SetFirstNumber is contained twice. Obviously
no regression test took place.
The question is, whether I should fix the error after such a long time
and how can I assure compatibility with the current user
documents/package documentation?
While testing the different versions I found that at the moment the
file listings.dtx isn't formattable. I found the culprit in the
comparison of different flexible columns format, I attach two MWEs (one
tabular_00.dtx for .dtx-files, the other tabular_01.tex for .tex-
files), which are formattable with a pdflatex version at least from
Sep. 2024, but not with the current version. Is this incompatibility
intended or will ist be fixed? If it is intended, is there a way to use
the old documentation code?
Best wishes
Jobst
--
Prof. Dr. Jobst Hoffmann Tel: +49 (241) 6009-5 31 59
Fachhochschule Aachen Abt. Jülich Fax: +49 (241) 6009-5 31 89
Fachbereich 09 email: j.hoffmann at fh-aachen.de
-------------- next part --------------
A non-text attachment was scrubbed...
Name: list_test.tex
Type: text/x-tex
Size: 247 bytes
Desc: list_test.tex
URL: <https://tug.org/pipermail/tex-live/attachments/20250124/ae9f939f/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: tabular_00.dtx
Type: text/x-tex
Size: 1109 bytes
Desc: tabular_00.dtx
URL: <https://tug.org/pipermail/tex-live/attachments/20250124/ae9f939f/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: tabular_01.tex
Type: text/x-tex
Size: 996 bytes
Desc: tabular_01.tex
URL: <https://tug.org/pipermail/tex-live/attachments/20250124/ae9f939f/attachment-0002.bin>
More information about the tex-live
mailing list.