I tried to make the basic examples of mdframed
given in the corresponding documentation, but I get an error stating
! You can't use a prefix with `\begingroup'.
The example is
\documentclass{article}
\usepackage[framemethod=default]{mdframed}
\usepackage{showexpl}
\global\mdfapptodefinestyle{exampledefault}{%
rightline=true,innerleftmargin=10,innerrightmargin=10,
frametitlerule=true,frametitlerulecolor=green,
frametitlebackgroundcolor=yellow,
frametitlerulewidth=2pt}
\begin{document}
\begin{mdframed}[style=exampledefault,frametitle={Inhomogeneous linear}]
\ExampleText
\end{mdframed}
\end{document}
Where did I do wrong?
Best Answer
You have some mistakes in your code:
\mdfapptodefinestyle
. But the styleexampledefault
isn't defined here. So the command fails. To define a style use\mdfdefinestyle
.\ExampleText
is defined in my example files but not in your example. So run:Here are some comments copied from the example file:
\global
inside the examples is necessary to work with the packageshowexpl
.All examples have the following settings:
Here an example