[texhax] Verbatim environment in LaTeX
ian.watson at tpg.com.au
Thu Aug 26 22:46:06 CEST 2004
Thanks for the useful advice. I suspected there was something funny
about verbatim, since my other environment definitions or
redefinitions worked OK. I'll look into fancyvrb.
The bit about maths symbols was not that Latex can't handle them,
since I do this all the time with inline $ delimiters. Rather, the
fact that I didn't want them treated at maths. That is, didn't want
to have to insert dozens of $s and put up with font changes.
Thanks again for you help.
University of Sydney
Thursday, August 26, 2004, 11:04:57 PM, you wrote:
>> I'm trying to reduce the size of the text inside a verbatim
>> environment in order to stop the display of some regression results
>> spilling across into the right margin. Verbatim is needed because
>> the maths symbols etc freak out LaTeX.
RF> i find it hard to imagine what maths symbols you can't put in
RF> "ordinary" latex, that you can put in verbatim. in general, (la)tex
RF> deals with maths, whereas most other systems (plain text included)
RF> just don't.
>> I've tried redefining the verbatim environment but without success.
>> So I've then tried creating a new verbatim environment, but that
>> doesn't work either. Any advice would be most appreciated.
>> My command, in the preamble:
RF> to first order, you can't do anything with verbatim in the argument of
RF> a command. even if that command is \newenvironment. (your command
RF> wouldn't work, anyway, since the \small would affect the \baselineskip
RF> of the text immediately before it.)
RF> there are exceptions to the rule about verbatim, of course, but you
RF> don't need them. the fancyvrb package does pretty much everything
RF> anyone could want of verbatim, not limited to mere size changes.
More information about the texhax