Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

multiline listing #33

Closed
daenney opened this issue May 6, 2014 · 4 comments
Closed

multiline listing #33

daenney opened this issue May 6, 2014 · 4 comments
Labels

Comments

@daenney
Copy link

daenney commented May 6, 2014

The documentation has an example of using a listing with a \minted but I can only get that to work for a single line. How do I get a multiline listing?

@gpoore
Copy link
Owner

gpoore commented May 6, 2014

For multiline, you want

\begin{minted}
...
\end{minted}

The \mint command is for a listing that contains only a single line.

@daenney
Copy link
Author

daenney commented May 6, 2014

I suspect as much but then I'm slightly stuck. Normally with listing it generates a label along the lines of Listing X-Y which is now missing. I tried getting that back with label but I keep getting Package keyval error label.

@gpoore
Copy link
Owner

gpoore commented May 6, 2014

Is this what you want?

\begin{listing}
\caption{<caption>}
\label{<label>}
\begin{minted}{<language>}
...
\end{minted}
\end{listing}

@daenney
Copy link
Author

daenney commented May 6, 2014

Yes. I feel stupid that it didn't occur to me to simply wrap a listing around it. Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants