A simple(?) question, how do I reduce the space before and after a environment?
I suppose I'm after a redefine environment command that I can put at the top of my document.
Example
I'm using Sweave and the R highlight environment. Basically, R code gets transformed into latex code. The end latex result looks like this:
\begin{Hchunk}
\begin{Hinput}
\ttfamily\noindent
\hlprompt{\usebox{\hlnormalsizeboxgreaterthan}{\ }}<snip>
\normalfont
\end{Hinput}
\begin{Houtput}
\ttfamily\noindent
NC-17{\ }{\ }{\ }{\ }PG{\ }PG-13{\ }{\ }{\ }{\ }{\ }<snip>
\end{Houtput}
%A few more Hinput and Houtput environments.
\end{Hchunk}
I would like to reduce the space after \end{Houtput}
For example \end{Houtput}\vspace{-0.2em}
highlight
package documentation says that you should just redefineHinput
andHoutput
as you desire. Note that using a negative\vspace
is almost always the wrong thing to do.\renewenvironment
to change the definition of theHchunk
environment.