I am using mdframed to create big boxes that span more than one page, but they just leave an unframed side at the top and down of the page. Is there a way to solve this?
\documentclass{article}
\usepackage[demo]{graphicx}% demo option just for the example
\usepackage{blindtext}% demo option just for the example
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{natbib}
\usepackage{float}
\usepackage[small]{caption}
\usepackage[usenames,dvipsnames]{xcolor}
\usepackage[xcolor,framemethod=tikz]{mdframed}
\begin{document}
\global\mdfdefinestyle{tag}{%
roundcorner=5pt,innerlinewidth=2pt,innerlinecolor=RubineRed,%
middlelinewidth=3pt,middlelinecolor=white,%
outerlinewidth=2pt,outerlinecolor=Melon,%
backgroundcolor=Melon!20,%
}
\begin{mdframed}[style=tag]
\begin{center}
\blindtext
\includegraphics[width=\textwidth]{foo}
\captionof{figure}{This is foo.}
\label{fig:foo}
\blindtext
\includegraphics[width=\textwidth]{foo}
\captionof{figure}{This is foo2.}
\label{fig:foo}
\blindtext
\blindtext
\blindtext
\end{center}
Lots of text
\blindtext
\blindtext
\blindtext
\includegraphics[width=\textwidth]{foo}
\captionof{figure}{This is foo3.}
\label{fig:foo}
\end{mdframed}
\end{document}

\documentclassand the appropriate packages so that those trying to help don't have to recreate it. – Peter Grill May 24 '12 at 05:22!. Those with editing privileges will re-insert it to embed the image in your post. – Werner May 24 '12 at 05:25everyline=true. The global is useless. It is only needed in my example files. – Marco Daniel May 24 '12 at 06:50