Skip to content
This repository has been archived by the owner on Jun 12, 2024. It is now read-only.

Commit

Permalink
Merge branch '46-command-to-repeat-titleslide' into release
Browse files Browse the repository at this point in the history
  • Loading branch information
Benno2000 committed Nov 14, 2022
2 parents b1f5d34 + 65ee25d commit b8cb927
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 3 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ The title picture can be changed with an optional parameter: ``\maketitle[<path-

If no picture is given (`\maketitle`), a default picture is used. To create a title frame without a picture, you can use `\maketitle[]`.

To repeat the title slide you can use the command `\againtitle` at any point. It creates a copy of the last title slide with the same picture and picture-offset.

### Section Frames

At the begin of each section a title slide is automatically generated. If you are in handout-mode, this slide also includes an overview of all sections and subsections that can be used to navigate through the slides easily.
Expand Down
19 changes: 16 additions & 3 deletions beamerthemeuulm.sty
Original file line number Diff line number Diff line change
Expand Up @@ -123,10 +123,9 @@
\universitylogo{uulm}
\clearinstitutelogo

\renewcommandx{\maketitle}[2][1=apr21-o25a,2=150]{
\newcommand{\@createtitleslide}{
{
\def \picture {#1}
\ifx \picture \empty \else \usebackgroundtemplate{\includegraphics[trim=0 0 0 #2,clip,width=\paperwidth]{#1}} \fi
\ifx \uulmtitlepicture \empty \else \usebackgroundtemplate{\includegraphics[trim=0 0 0 \uulmtitlepictureoffset,clip,width=\paperwidth]{\uulmtitlepicture}} \fi
\begin{frame}[plain]
\vskip0pt plus 1filll
\begin{beamercolorbox}[wd=\paperwidth,ht=4.5ex,dp=2ex,right]{titlebox}
Expand All @@ -151,6 +150,20 @@
}
}

\renewcommandx{\maketitle}[2][1=apr21-o25a,2=150]{
\gdef\uulmtitlepicture{#1}
\gdef\uulmtitlepictureoffset{#2}
\@createtitleslide
}

\newcommand{\againtitle}{
\ifcsname uulmtitlepicture\endcsname
\@createtitleslide
\else
\PackageError{beamerthemeuulm}{To use \string\againtitle\space you must first use \string\maketitle!}{Either comment out this line or check if you forgot to issue the \string\maketitle-macro.}%
\fi
}

\setbeamertemplate{frametitle}{
\vspace{20pt}%
\fitbox[maxheight=2.5ex,minheight=0pt,maxwidth=\textwidth,minwidth=0pt]{%
Expand Down
Binary file modified demo-slides/demoSlides.pdf
Binary file not shown.
3 changes: 3 additions & 0 deletions demo-slides/demoSlides.tex
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,9 @@ \subsection{Easy Navigation in Slides}
\vfill
\end{frame}

\subsection{Repeating the Last Title Slide}
\againtitle

\subsection{Alternative Title Pictures}
\maketitle[] % title page without a picture
% examples for alternative title pictures:
Expand Down

0 comments on commit b8cb927

Please sign in to comment.