4

I'm creating a beamer presentation. This is my code:

\documentclass{beamer}

\usetheme{Berlin}
\useoutertheme{miniframes} %Titelbalken
\setbeamertemplate{blocks}[rounded][shadow=true]

%Packages
\usepackage{amsmath, amssymb, amsthm}

\newenvironment{te bewijzen}[1][]
{\textbf{Te bewijzen:} #1}

\newenvironment{bewijs}[1]{
    \pushQED{\qed}
    \textbf{Bewijs:} #1}
{\popQED}

\begin{document}

\section{Deelvraag 1}

\subsection{Bewijs}
\frame{\frametitle{Bewijs}
    \begin{block}{Block}
        some text in my block
    \end{block}
    \begin{te bewijzen}
        this is what I have to prove
    \end{te bewijzen}
    \begin{bewijs}
        \begin{align*}
                               & line 1\\
            \Longrightarrow~    & line 2\\
            \Longrightarrow~    & line 3\\
            \Longrightarrow~    & line 4
        \end{align*}
\end{bewijs}
}

\end{document}

As you can see, the block and the text underneath are a bit close together and I don't really like that. How can I get some more space between them?

  • 1
    Can't you add \vspace*{10pt} or \bigskip or similar after the block? – karlkoeller Dec 5 '13 at 11:43
  • 1
    Hi! Would \medskip help? (Sorry, I don't have a good LaTeX here now, so I can't test.) You can put it directly at the beginning of te bewijzen definition, too. Just one note: you can try \implies instead of \Longrightarrow~ ;) – yo' Dec 5 '13 at 11:43
  • Thanks for accepting my answer, but please consider to also upvote it -- upvoting must be done separate from accepting. – lockstep Dec 5 '13 at 16:08
  • @tohecz: \medskip works perfectly and \implies really is an improvement. Thanks! – Jeroen Dec 5 '13 at 16:10
  • @lockstep: Done! :) – Jeroen Dec 5 '13 at 16:10
2

Instead of adding commands like \medskip after each block in your presentation, add the following to your preamble:

\addtobeamertemplate{block end}{}{\medskip}

MWE:

\documentclass{beamer}

\usetheme{Berlin}
\useoutertheme{miniframes} %Titelbalken
\setbeamertemplate{blocks}[rounded][shadow=true]

\addtobeamertemplate{block end}{}{\medskip}

%Packages
\usepackage{amsmath, amssymb, amsthm}

\newenvironment{te bewijzen}[1][]
{\textbf{Te bewijzen:} #1}

\newenvironment{bewijs}[1]{
    \pushQED{\qed}
    \textbf{Bewijs:} #1}
{\popQED}

\begin{document}

\section{Deelvraag 1}

\subsection{Bewijs}
\frame{\frametitle{Bewijs}
    \begin{block}{Block}
        some text in my block
    \end{block}
    \begin{te bewijzen}
        this is what I have to prove
    \end{te bewijzen}
    \begin{bewijs}
        \begin{align*}
        & line 1\\
        \Longrightarrow~    & line 2\\
        \Longrightarrow~    & line 3\\
        \Longrightarrow~    & line 4
        \end{align*}
    \end{bewijs}
}

\end{document}

enter image description here

1

As karlkoeller mentioned, you can do this by using \vspace or \bigskip. For example:

\documentclass{beamer}

\usetheme{Berlin}
\useoutertheme{miniframes} %Titelbalken
\setbeamertemplate{blocks}[rounded][shadow=true]

%Packages
\usepackage{amsmath, amssymb, amsthm}

\newenvironment{te bewijzen}[1][]
{\textbf{Te bewijzen:} #1}

\newenvironment{bewijs}[1]{
    \pushQED{\qed}
    \textbf{Bewijs:} #1}
{\popQED}

\begin{document}

\section{Deelvraag 1}

\subsection{Bewijs}
\frame{\frametitle{Bewijs}
    \begin{block}{Block}
        some text in my block
    \end{block}

    \bigskip

    \begin{te bewijzen}
        this is what I have to prove
    \end{te bewijzen}
    \begin{bewijs}
        \begin{align*}
                               & line 1\\
            \Longrightarrow~    & line 2\\
            \Longrightarrow~    & line 3\\
            \Longrightarrow~    & line 4
        \end{align*}
\end{bewijs}
}

\end{document}
  • \vspaceand \bigskip didn't work, but @lockstep's answer is perfect. – Jeroen Dec 5 '13 at 16:06
  • 1
    It does work, but you have to make sure that there is an empty line between the \end{block} and \bigskip and another empty line between \bigskip and \begin{te bewijzen} – I Like to Code Dec 5 '13 at 19:37
  • Your absolutely right: I forgot an empty line after the \bigskip. It works fine now. Although I find @lockstep's solution more elegant, I'll update your answer too. Thanks! – Jeroen Dec 5 '13 at 22:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.