-
Notifications
You must be signed in to change notification settings - Fork 21
/
beamerouterthemeusyd-logobar.sty
63 lines (56 loc) · 2.09 KB
/
beamerouterthemeusyd-logobar.sty
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
\mode<presentation>
\beamer@compresstrue
% This is the padding between text elements and the edges of the colorboxes
\newlength{\theme@hpadding}
\setlength{\theme@hpadding}{1.5em}
% This is the whitespace on the top and bottom of the slides.
\newlength{\theme@vpadding}
\setlength{\theme@vpadding}{0.3em}
\defbeamertemplate*{frametitle}{usyd logo}[1][]
{%
\vskip1ex
\begin{beamercolorbox}[wd=\textwidth, #1]{frametitle}
\usebeamerfont{frametitle}\insertframetitle\par%
\end{beamercolorbox}
}
\defbeamertemplate*{headline}{usyd logo}
{%
% Leave a gap at the top of the slide before the headline
\vspace{\theme@vpadding}
\ifnum\thepage=1\relax%
% For beamer to not raise an error it needs to know the height of this element for all slides.
% This creates an placeholder for the title-page to satisfy positioning on all subsequent
% slides.
\begin{beamercolorbox}[wd=\paperwidth, ht=1.2em,dp=1.5em]{placeholder}%
\end{beamercolorbox}
\else%
\leavevmode%
\begin{beamercolorbox}[center,wd=0.25\paperwidth,ht=1.2em,dp=1.5em]{logo in head/foot}%
% Move down by the depth (dp) of the colorbox
\vspace{-1.75em}\insertlogo%
\end{beamercolorbox}%
\begin{beamercolorbox}[wd=0.75\paperwidth,ht=1.2em,dp=1.5em]{section in head/foot}%
\insertnavigation{0.75\linewidth} \hfill %
\insertframenumber\hspace{\theme@hpadding}
\end{beamercolorbox}
\fi
}
\defbeamertemplate*{footline}{usyd logo}
{%
\ifnum\thepage=1\relax%
% Empty colourbox on titlepage to retain spacing on subsequent pages
\begin{beamercolorbox}[wd=\paperwidth,ht=1em,dp=0.5em]{placeholder}%
\end{beamercolorbox}%
\else%
\leavevmode%
\begin{beamercolorbox}[center,wd=0.25\paperwidth,ht=1em,dp=0.5em]{author in head/foot}%
\insertshortauthor
\end{beamercolorbox}%
\begin{beamercolorbox}[wd=0.75\paperwidth,ht=1em,dp=0.5em]{title in head/foot}%
\hspace{\theme@hpadding}\insertshorttitle\hfill\insertdate\hspace{\theme@hpadding}
\end{beamercolorbox}%
\fi
% Leave gap at bottom of slide the same size as at top
\vspace{\theme@vpadding}
}
\mode<all>