# Package “mdframed” creating arbitrary gaps in the border

I used to define a small environment with the package "mdframed". I've included the package in the following way:

\usepackage[framemethod=tikz]{mdframed}


This is how I've set up the environment:

\newenvironment{bspbox}
[2]
{\begin{mdframed}[linecolor=gray!25, innerleftmargin=3pt, innerrightmargin=3pt, leftmargin=5pt, rightmargin=5pt, skipabove=5pt, skipbelow=5pt, linewidth=0pt, frametitle={Title#2: #1}, frametitlefont=\normalfont\bfseries]}
{\end{mdframed}}


It works okay, but unfortunately, there are some arbitrarily placed gaps interrupting the line / frame. They can appear in various places, but in most cases, it looks like in the following screenshot:

The environment was used in my document in the following way:

\begin{bspbox}{}{}
\lipsum[1]
\end{bspbox}


To sum it all up, this is what the MWE looks like:

\documentclass[a4paper,10pt]{article}
\usepackage[dvipsnames,usenames]{xcolor} % mehr vordefinierte Farben
\usepackage[utf8]{inputenc}
\parindent0pt
\usepackage{tikz}
\usepackage[framemethod=tikz]{mdframed}
\usepackage{lipsum}

\newenvironment{bspbox}
[2]
{\begin{mdframed}[linecolor=gray!25, innerleftmargin=3pt, innerrightmargin=3pt, leftmargin=5pt, rightmargin=5pt, skipabove=5pt, skipbelow=5pt, linewidth=0pt, frametitle={Title#2: #1}, frametitlefont=\normalfont\bfseries]}
{\end{mdframed}}

\begin{document}

\begin{bspbox}{}{}
\lipsum[1]
\end{bspbox}

\end{document}


Where lies my fault, why are there those arbitrary gaps interrupting the line?

-
Please make your code compilable (if possible), or at least complete it with \documentclass{...}, the required \usepackage's, \begin{document}, and \end{document}. That may seem tedious to you, but think of the extra work it represents for TeX.SX users willing to give you a hand. Help them help you: remove that one hurdle between you and a solution to your problem. –  Jubobs Jan 14 at 7:52
Please follow Jubobs request of providing a minimal working example (MWE). As it stands your options to mdframed contain linewidth=0pt which produces no frame at all. If I change that to 1pt then I do not see the describe behaviour in a minimal document. –  Andrew Swann Jan 14 at 8:02
Might also be an idea to list which version of mdframed you are using. –  daleif Jan 14 at 8:17
Your MWE does not produce the posted image. See my previous comment about linewidth. As daleif says, telling us the version numbers of the packages you are using could also be helpful; you can get these by adding \listfiles to your preamble, they will be printed in the log file. –  Andrew Swann Jan 14 at 8:27
As Andrew says, your MWE does not produce your image, please post exactly the code that gives the problem. And setting linewidth to something non-zero gives the expected frame. I'm using version 2013/07/01 1.9b so I;d suggest updating you LaTeX installation –  daleif Jan 14 at 9:12