gusl: (Default)
[personal profile] gusl
Dear LJ Genie,

how do I insert code snippets in a LaTeX document?

In LJ, there is the very nice < pre > tag, which tends to be rendered in the fixed-width "Courier New", which also makes it suitable for ASCII art.

(no subject)

Date: 2005-09-02 01:01 pm (UTC)
From: [identity profile] zarex.livejournal.com
I think it's \verb

(no subject)

Date: 2005-09-05 12:23 am (UTC)
From: [identity profile] gustavolacerda.livejournal.com
\begin-end{verbatim} if you want to have spaces. Thanks...

(no subject)

Date: 2005-09-02 01:13 pm (UTC)
From: [identity profile] mathemajician.livejournal.com
Let me email you a really great latex guide that I use ALL THE TIME...

After using it a few times you will be able to look up how to do most things in a matter of seconds.

(no subject)

Date: 2005-09-03 12:50 am (UTC)
From: [identity profile] chipuni.livejournal.com
*grin*

\verb works, but there's a much nicer way to do it, if you can install additions.

Download and install listings. This is a wonderful package that intelligently formats your source code, and lets you specify how to format things.

February 2020

S M T W T F S
      1
2345678
9101112131415
16171819202122
23242526272829

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags