Open EmmanuelCharpentier opened 6 years ago
It would be good to have a longlisting
environment. The minted
documentation FAQ actually links to the same StackExchange discussion with the one-line solution. The main reason there isn't a longlisting
is that there would really need to be some of the enhanced options you mentioned. If you can figure out a way to get something equivalent to longtable
, I would be happy to include that in minted
. Otherwise, maybe I will get around to working on a proper longlisting
someday.
i am not getting a truncated listing (taking from a file)
is this issue still valid?
i am not getting a truncated listing (taking from a file) is this issue still valid?
I am including a 171 lines long snippet in the appendix of my thesis, at the page break the rest is still truncated:
I am including a 171 lines long snippet in the appendix of my thesis, at the page break the rest is still truncated:
MWE??
ive-just-been-asked-to-write-a-minimal-working-example-mwe-what-is-that https://tex.meta.stackexchange.com/questions/228/
I am including a 171 lines long snippet in the appendix of my thesis, at the page break the rest is still truncated:
MWE??
ive-just-been-asked-to-write-a-minimal-working-example-mwe-what-is-that https://tex.meta.stackexchange.com/questions/228/
I fixed it with the longlisting example, but i can provide a minimal example once i ripped out everything else
The current
listing
environment is handy for code snippets and small extracts. But it cannot (obviously) typeset programs more than one page long (if you try it, you get a truncated listing).This is inconvenient for "verbose" languages, such as C++ or Stan, or for long programs. For such lengthy code, one does not need a
float
environment, but a caption and a label are useful.inspired by the answer to this StackExchange question, the following one liner is handy :
and allows this đź‘Ť
But this solution can be enhanced :
An example of similar output can be obtained by the
longtable
environment. But its implementation seems quite different of what can be easily done withminted
.Do you think it is worthwhile to pursue this idea ?