Go to page:

Search:   Help

Edit

FAQ /

Categories: Tag me
<< | Page list | >>

> I've got an ERT for defining a shaded box with a line around it. I'm
> trying to make my own environment for it, but I'm just not getting the
> Preamble right.

Well, after spending a few hours reading 'The Not So Short Guide to LaTex' and 'A Simplified Introduction to LaTeX' and pulling some of Herbert Voss' pages out of Google's catch (a few transatlantic links have been spotty, so I can't get there directly) I've got this, which works quite nicely:


\usepackage{color,calc}
{
%\setlength{\fboxsep}{-\fboxrule}
\footnotesize\normalfont\ttfamily\raggedright
\setlength{\rightmargin}{\leftmargin}
\setlength{\itemsep}{-12pt}
\setlength{\parsep}{20pt}
\begin{lrbox}{\@tempboxa}%
\begin{minipage}{\linewidth-2\fboxsep}
}%
{
\end{minipage}%
\end{lrbox}%
}%



Just figured I'd post it in case anyone else was curious how to do it. (From: Peter Harkins)

If you want to redefine the 'Box (Minipage, shaded background)' you can the same construct only slightly adjusted:


\usepackage{calc}
{
%\setlength{\fboxsep}{-\fboxrule}
\footnotesize\normalfont\ttfamily\raggedright
\setlength{\rightmargin}{\leftmargin}
\setlength{\itemsep}{-12pt}
\setlength{\parsep}{20pt}
\begin{lrbox}{\@tempboxa}%
\begin{minipage}{\linewidth-2\fboxsep}
}%
{
\end{minipage}%
\end{lrbox}%