-
Notifications
You must be signed in to change notification settings - Fork 6
/
beamerthemeprogressbar.sty
69 lines (56 loc) · 2.18 KB
/
beamerthemeprogressbar.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
64
65
66
67
68
69
\ProvidesPackage{beamerthemeprogressbar}[2007/06/21]
% Beamer theme by Sylvain Bouveret <sylvain[dot]bouveret[aT]cert[DoT]fr>
% sep. 2010 version 0.42
%
% based on the LaTeX-Beamer package :
% Copyright 2003 by Till Tantau <[email protected]>
%
% This program can be redistributed and/or modified under the terms
% of the GNU Public License, version 2.
\RequirePackage{tikz}
%\RequirePackage{bibunits}
\usecolortheme{progressbar}
\useinnertheme{progressbar}
\usefonttheme{progressbar}
\useoutertheme{progressbar}
\setbeamertemplate{navigation symbols}{}
\AtBeginDocument{%
\typeout{..................................................................}
\typeout{You are using the progressbar beamer theme (Sylvain B.)}
\typeout{Version: 0.42 September 2010.}
\typeout{..................................................................}
}
\def\insertintermediateframenumber{\inserttotalframenumber}
\renewcommand{\appendix}[1][0void0]
{
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% This piece of code is supposed to introduce a bias in the
% number of slides
\makeatletter
\immediate\write\@auxout{\string\@writefile{nav}%
{\noexpand\headcommand{\noexpand\def\noexpand\insertintermediateframenumber{\the\c@framenumber}}}}
\renewcommand{\insertintermediateframenumber}{\inserttotalframenumber}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\def\tmparg{#1}
\def\tmpargref{0void0}
\ifx\tmparg\tmpargref\else
\begin{frame}[plain]
\vfill
\begin{center}
\usebeamerfont{title}\usebeamercolor{title}{\color{fg}\ #1\ }
\end{center}
\vfill
\end{frame}
\fi
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% We recompute the progressbar step and the current position
\progressbar@numer=1
\progressbar@denom=\insertintermediateframenumber
\advance\progressbar@denom by -1
\progressbar@tmpresult=\progressbar@barlength
\multiply\progressbar@tmpresult by \progressbar@numer
\divide\progressbar@tmpresult by \progressbar@denom
\global\progressbar@stepbar=\progressbar@tmpresult
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\makeatother
}