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}
Best Answer
The highlight package seems to define
You can change those to be more suitable to what you want. In particular, you can remove the
\vspace
. Just use\renewenvironment
.