2

I am using the beamer class to create the slides and use the scrartl with \usepackage{beamerarticle} to create the script. The block environment looks well separated and coloured in the slide. I would like to have these blocks, at least, emphasised with a frame in the article mode; without creating a new environment. I want to use simply begin{block}{title} ... \end{block} for both, the presentation and the article mode. The image shows, how I would like to appear it in the article mode: Blocks with a red frame in the article mode

Here is the mini-example, separated in two tex files. The first one for the article:

\documentclass[parskip=half,headings=optiontohead]{scrartcl}
\usepackage{beamerarticle}

%% -------------------
\title[Baustatik]{Vorlesung Baustatik}
\author{Prof. Irgendwer}
%% -------------------
\usepackage[ngerman]{babel}

\begin{document}

\maketitle
\tableofcontents

\section{Arbeit am Gesamtsystem}

\begin{frame}
\frametitle{Satz von Betti und Maxwell}
Der Endzustand der Verformung ist von der Reihenfolge des Aufbringens der Kräfte unabhängig
\begin{equation*}
W_1 = W_2 \ \ \Longrightarrow \ \ W_{ik} = W_{ki} \ \ \Longrightarrow \ \ \boxed{F_i\delta_{ik} = F_k\delta_{ki}}
\end{equation*}

%Satz von \textit{Betti} (1872)
\begin{block}{Satz von Betti}
Die elastische Verschiebungsarbeit eines Kräftesystems auf dem Weg eines Zweiten ist gleich derjenigen Verschiebungsarbeit des zweiten Kräftesystems auf dem Weg des Ersten.
\end{block}

\mode<article>{Die Spezialisierung auf Einheitslastgrößen $F_i = 1$ und $F_k = 1$ ergibt:}
\begin{equation*}
F_i = 1\ \&\ F_k = 1 \Longrightarrow  \delta_{ik} = \delta_{ki}
\end{equation*}

\begin{block}{Satz von Maxwell}
Die Weggrößen zweier beliebiger Einheitslastzustände in Richtung des jeweils anderen Lastzustandes sind gleich groß. Ort und Ursache dürfen vertauscht werden
\end{block}
\end{frame}

\end{document}

The second code for the slides:

%\documentclass{beamer}
\documentclass[smaller,t,fleqn]{beamer}


%% Presentation Themes with Sidebars
\usetheme[hideothersubsections,width=1.8cm,right]{Berkeley}
\usecolortheme{sidebartab} % changes the backgound color of current subsection in navigation bar 


\usefonttheme{structurebold}
\setbeamertemplate{navigation symbols}{} % hide navigation symbols in the PDF file
\setbeamertemplate{sections/subsections in toc}[ball unnumbered]
\usecolortheme{seahorse}

\usepackage[ngerman]{babel}

\begin{document}

\section{Arbeit am Gesamtsystem}

\begin{frame}
\frametitle{Satz von Betti und Maxwell}
Der Endzustand der Verformung ist von der Reihenfolge des Aufbringens der Kräfte unabhängig
\begin{equation*}
W_1 = W_2 \ \ \Longrightarrow \ \ W_{ik} = W_{ki} \ \ \Longrightarrow \ \ \boxed{F_i\delta_{ik} = F_k\delta_{ki}}
\end{equation*}

%Satz von \textit{Betti} (1872)
\begin{block}{Satz von Betti}
Die elastische Verschiebungsarbeit eines Kräftesystems auf dem Weg eines Zweiten ist gleich derjenigen Verschiebungsarbeit des zweiten Kräftesystems auf dem Weg des Ersten.
\end{block}

\mode<article>{Die Spezialisierung auf Einheitslastgrößen $F_i = 1$ und $F_k = 1$ ergibt:}
\begin{equation*}
F_i = 1\ \&\ F_k = 1 \Longrightarrow  \delta_{ik} = \delta_{ki}
\end{equation*}

\begin{block}{Satz von Maxwell}
Die Weggrößen zweier beliebiger Einheitslastzustände in Richtung des jeweils anderen Lastzustandes sind gleich groß. Ort und Ursache dürfen vertauscht werden
\end{block}
\end{frame}

\end{document}

Many thanks for your help in advance. Gerlind

1 Answer 1

4
\documentclass[parskip=half,headings=optiontohead]{scrartcl}
\usepackage{beamerarticle}

\usepackage{tcolorbox}

\mode<article>{%
  \setbeamertemplate{block begin}{
    \begin{tcolorbox}[%
      colback=white,
      colframe=red,
      arc=0mm,
      title=\insertblocktitle,
      colbacktitle=white,
      coltitle=black,
      fonttitle=\bfseries,
      detach title,
      before upper={\tcbtitle\par}
    ]
  }

  \setbeamertemplate{block end}{
    \end{tcolorbox}
  }
}

\begin{document}

\section{Arbeit am Gesamtsystem}

\begin{frame}
\frametitle{Satz von Betti und Maxwell}
Der Endzustand der Verformung ist von der Reihenfolge des Aufbringens der Kräfte unabhängig
\begin{equation*}
W_1 = W_2 \ \ \Longrightarrow \ \ W_{ik} = W_{ki} \ \ \Longrightarrow \ \ \boxed{F_i\delta_{ik} = F_k\delta_{ki}}
\end{equation*}

%Satz von \textit{Betti} (1872)
\begin{block}{Satz von Betti}
Die elastische Verschiebungsarbeit eines Kräftesystems auf dem Weg eines Zweiten ist gleich derjenigen Verschiebungsarbeit des zweiten Kräftesystems auf dem Weg des Ersten.
\end{block}

\mode<article>{Die Spezialisierung auf Einheitslastgrößen $F_i = 1$ und $F_k = 1$ ergibt:}
\begin{equation*}
F_i = 1\ \&\ F_k = 1 \Longrightarrow  \delta_{ik} = \delta_{ki}
\end{equation*}

\begin{block}{Satz von Maxwell}
Die Weggrößen zweier beliebiger Einheitslastzustände in Richtung des jeweils anderen Lastzustandes sind gleich groß. Ort und Ursache dürfen vertauscht werden
\end{block}
\end{frame}

\end{document}

enter image description here

2
  • Great help, perfectly working for the block environment.When I want to do the same for the \begin{alertblock} .. \end{alertblock} environment can I then simply use \setbeamertemplate{alertblock begin} ... \setbeamertemplate{alertblock end}? This is unfortunately not working for me. Mar 20, 2018 at 21:10
  • 1
    @GerlindSchubert Try with block alerted begin Mar 20, 2018 at 21:12

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .