2014-06-27 15:29:29 +02:00
|
|
|
|
% Name : beamerthemehri.sty
|
|
|
|
|
% Author : Séverin Lemaignan (severin.lemaignan@epfl.ch)
|
2014-03-24 14:52:51 +01:00
|
|
|
|
% Author : Benjamin Weiss (benjamin.weiss@kreatiefton.de)
|
2013-05-16 15:16:01 +02:00
|
|
|
|
% License : This file may be distributed and/or modified under the
|
|
|
|
|
% GNU Public License.
|
|
|
|
|
|
2014-06-27 15:29:29 +02:00
|
|
|
|
\ProvidesPackage{beamerthemehri}[2013/05/05]
|
2013-05-16 15:16:01 +02:00
|
|
|
|
|
2014-07-08 14:39:53 +02:00
|
|
|
|
\usepackage{color}
|
|
|
|
|
\usepackage{etoolbox}
|
2013-05-16 15:16:01 +02:00
|
|
|
|
\usepackage{eso-pic}
|
|
|
|
|
|
|
|
|
|
\newif\if@doSans
|
|
|
|
|
\@doSansfalse
|
|
|
|
|
\DeclareOption{noserifmath}{\@doSanstrue}
|
|
|
|
|
\newif\if@doNoFlama
|
|
|
|
|
\@doNoFlamafalse
|
|
|
|
|
\DeclareOption{noflama}{\@doNoFlamatrue}
|
2016-02-18 17:58:55 +01:00
|
|
|
|
\newif\if@doBasicFont
|
|
|
|
|
\@doBasicFontfalse
|
|
|
|
|
\DeclareOption{basicfont}{\@doBasicFonttrue}
|
2013-05-16 15:16:01 +02:00
|
|
|
|
\newif\if@doSectionPage
|
|
|
|
|
\@doSectionPagefalse
|
|
|
|
|
\DeclareOption{nosectionpages}{\@doSectionPagetrue}
|
|
|
|
|
\ProcessOptions
|
|
|
|
|
|
|
|
|
|
\mode<presentation>
|
|
|
|
|
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
% TOC
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
\useoutertheme[subsection=false,shadow]{miniframes}
|
|
|
|
|
\setbeamertemplate{section in toc}[sections numbered]
|
|
|
|
|
\setbeamertemplate{subsection in toc}[subsections numbered]
|
|
|
|
|
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
% custom commands
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
\newcommand{\rightTextArrow}{→}
|
|
|
|
|
\newcommand{\quoted}[1]{›#1‹}
|
|
|
|
|
\newcommand{\doublequoted}[1]{»#1«}
|
|
|
|
|
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
% Itemize
|
|
|
|
|
%---------------------------------------------------------------------
|
2016-02-15 17:45:32 +01:00
|
|
|
|
\setbeamertemplate{itemize item}{$\circ$}
|
2013-05-16 15:16:01 +02:00
|
|
|
|
\setbeamertemplate{itemize subitem}{\rightTextArrow}
|
|
|
|
|
\setbeamertemplate{itemize subsubitem}{\rightTextArrow}
|
|
|
|
|
|
|
|
|
|
\setlength{\parskip}{0.5em}
|
|
|
|
|
|
2014-06-27 23:11:09 +02:00
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
% Background
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
\setbeamertemplate{background}{
|
|
|
|
|
\includegraphics[width=\paperwidth,
|
|
|
|
|
height=\paperheight]{slide-background.pdf}
|
|
|
|
|
}
|
|
|
|
|
|
2013-05-16 15:16:01 +02:00
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
% Colors
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
% Primary Colors
|
2014-06-27 15:29:29 +02:00
|
|
|
|
\definecolor{hriRed}{rgb}{0.882352941,0,0.098039216}
|
|
|
|
|
\definecolor{hriRedDark}{rgb}{0.588235294,0,0.058823529}
|
|
|
|
|
\definecolor{hriWarmGreyDark}{rgb}{0.274509804,0.254901961,0.235294118}
|
|
|
|
|
\definecolor{hriWarmGreyLight}{rgb}{0.666666667,0.647058824,0.62745098}
|
2013-05-16 15:16:01 +02:00
|
|
|
|
|
|
|
|
|
% Secondary Colors
|
2014-06-27 15:29:29 +02:00
|
|
|
|
\definecolor{hriSec1}{rgb}{0,0.588235294,0.509803922}
|
|
|
|
|
\definecolor{hriSec1Dark}{rgb}{0,0.392156863,0.31372549}
|
|
|
|
|
\definecolor{hriSec1Comp}{rgb}{0.294117647,0.745098039,0.882352941}
|
|
|
|
|
\definecolor{hriSec1CompDark}{rgb}{0.196078431,0.490196078,0.568627451}
|
2013-05-16 15:16:01 +02:00
|
|
|
|
|
2014-06-27 15:29:29 +02:00
|
|
|
|
\definecolor{hriSec2}{rgb}{0.607843137,0.764705882,0.156862745}
|
|
|
|
|
\definecolor{hriSec2Dark}{rgb}{0.411764706,0.490196078,0.098039216}
|
|
|
|
|
\definecolor{hriSec2Comp}{rgb}{0.254901961,0.156862745,0.509803922}
|
|
|
|
|
\definecolor{hriSec2CompDark}{rgb}{0.176470588,0.098039216,0.333333333}
|
2013-05-16 15:16:01 +02:00
|
|
|
|
|
2014-06-27 15:29:29 +02:00
|
|
|
|
\definecolor{hriSec3}{rgb}{0.509803922,0.078431373,0.31372549}
|
|
|
|
|
\definecolor{hriSec3Dark}{rgb}{0.338345865,0.058823529,0.196078431}
|
|
|
|
|
\definecolor{hriSec3Comp}{rgb}{1,0.509803922,0}
|
|
|
|
|
\definecolor{hriSec3CompDark}{rgb}{0.666666667,0.333333333,0}
|
2013-05-16 15:16:01 +02:00
|
|
|
|
|
|
|
|
|
% General
|
2014-06-27 15:29:29 +02:00
|
|
|
|
\setbeamercolor{normal text}{fg=hriWarmGreyDark}
|
|
|
|
|
\setbeamercolor{structure}{fg=hriWarmGreyDark}
|
|
|
|
|
\setbeamercolor{alerted text}{fg=hriRed}
|
2013-05-16 15:16:01 +02:00
|
|
|
|
\setbeamercolor{example text}{fg=white}
|
2014-06-27 15:29:29 +02:00
|
|
|
|
\setbeamercolor{copyright text}{fg=hriWarmGreyLight}
|
|
|
|
|
\setbeamercolor{palette primary}{fg=hriWarmGreyDark}
|
|
|
|
|
\setbeamercolor{palette secondary}{fg=hriWarmGreyDark,bg=hriWarmGreyLight}
|
|
|
|
|
\setbeamercolor{palette tertiary}{fg=black,bg=hriWarmGreyLight}
|
|
|
|
|
\setbeamercolor{palette quaternary}{fg=white, bg=hriWarmGreyDark}
|
2013-05-16 15:16:01 +02:00
|
|
|
|
% Titlepage
|
|
|
|
|
\setbeamercolor{title}{parent=normal text}
|
|
|
|
|
\setbeamercolor{subtitle}{parent=normal text}
|
|
|
|
|
\setbeamercolor{institute}{parent=normal text}
|
|
|
|
|
% Content
|
|
|
|
|
\setbeamercolor{frametitle}{parent=palette quaternary}
|
|
|
|
|
% Blocks
|
|
|
|
|
\setbeamercolor{block title}{parent=palette quaternary}
|
|
|
|
|
\setbeamercolor{block body}{parent=palette secondary}
|
2014-06-27 15:29:29 +02:00
|
|
|
|
\setbeamercolor{block title example}{fg=white, bg=hriSec1Dark}
|
|
|
|
|
\setbeamercolor{block body example}{fg=white, bg=hriSec1}
|
|
|
|
|
\setbeamercolor{block title alerted}{fg=white, bg=hriRedDark}
|
|
|
|
|
\setbeamercolor{block body alerted}{fg=white, bg=hriRed}
|
2013-05-16 15:16:01 +02:00
|
|
|
|
% Notes
|
2014-06-27 15:29:29 +02:00
|
|
|
|
\setbeamercolor{note page}{fg=hriWarmGreyDark,bg=hriWarmGreyLight}
|
|
|
|
|
\setbeamercolor{note title}{fg=white, bg=hriWarmGreyDark}
|
2013-05-16 15:16:01 +02:00
|
|
|
|
\setbeamercolor{note date}{parent=note title}
|
|
|
|
|
% Page Number
|
2014-06-27 15:29:29 +02:00
|
|
|
|
\setbeamercolor{page number in head/foot}{fg=hriWarmGreyDark}
|
2013-05-16 15:16:01 +02:00
|
|
|
|
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
% Fonts
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
% General
|
|
|
|
|
|
|
|
|
|
% Declare fontfamilys
|
2016-02-18 17:58:55 +01:00
|
|
|
|
\if@doBasicFont%
|
|
|
|
|
% basic font option
|
|
|
|
|
\newcommand{\Light}{}%
|
|
|
|
|
\newcommand{\Book}{\bf}%
|
|
|
|
|
\newcommand{\Medium}{\bf}%
|
2013-05-16 15:16:01 +02:00
|
|
|
|
\else%
|
2016-02-18 17:58:55 +01:00
|
|
|
|
\if@doNoFlama%
|
|
|
|
|
% Sans serif math option
|
|
|
|
|
\if@doSans%
|
|
|
|
|
% sans serif math %
|
|
|
|
|
\usepackage[no-math]{fontspec}%
|
|
|
|
|
\setmainfont{Arial}%
|
|
|
|
|
\else%
|
|
|
|
|
% serif math %
|
|
|
|
|
\usepackage{fontspec}%
|
|
|
|
|
\usefonttheme[onlymath]{serif}%
|
|
|
|
|
\fi%
|
|
|
|
|
\newfontfamily\Light{Arial}%
|
|
|
|
|
\newfontfamily\Book{Arial-Bold}%
|
|
|
|
|
\newfontfamily\Medium{Arial-Bold}%
|
|
|
|
|
\setsansfont{Arial}%
|
|
|
|
|
\else%
|
|
|
|
|
% Sans serif math option
|
|
|
|
|
\if@doSans%
|
|
|
|
|
\usepackage[no-math]{fontspec}%
|
|
|
|
|
\setmainfont{FlamaLight}%
|
|
|
|
|
\else%
|
|
|
|
|
\usepackage{fontspec}%
|
|
|
|
|
\usefonttheme[onlymath]{serif}%
|
|
|
|
|
\fi%
|
|
|
|
|
\usepackage{fontspec}
|
|
|
|
|
\defaultfontfeatures{Ligatures=TeX} % To support LaTeX quoting style
|
|
|
|
|
\newfontfamily\Light{FlamaLight}%
|
|
|
|
|
\newfontfamily\Book{FlamaBook}%
|
|
|
|
|
\newfontfamily\Medium{FlamaMedium}%
|
|
|
|
|
\setsansfont{FlamaLight}%
|
|
|
|
|
\fi%
|
2013-05-16 15:16:01 +02:00
|
|
|
|
\fi%
|
|
|
|
|
|
|
|
|
|
\renewcommand\UrlFont{\Medium}
|
|
|
|
|
% Titlepage
|
|
|
|
|
\setbeamerfont{title}{family=\Light,size=\fontsize{20}{20}}
|
|
|
|
|
\setbeamerfont{subtitle}{family=\Light,size=\fontsize{12}{14}}
|
|
|
|
|
\setbeamerfont{date}{size=\fontsize{8}{10}}
|
|
|
|
|
\setbeamerfont{author}{size=\fontsize{12}{15}}
|
|
|
|
|
\setbeamerfont{institute}{size=\fontsize{8}{10}}
|
|
|
|
|
% Section
|
|
|
|
|
\setbeamerfont{section title}{size=\LARGE}
|
|
|
|
|
% Content
|
|
|
|
|
\setbeamerfont{frametitle}{family=\Light,size=\large}
|
|
|
|
|
\setbeamerfont{copyright text}{family=\Light,size=\tiny}
|
|
|
|
|
\setbeamerfont{block title}{family=\Book,size=\large}
|
|
|
|
|
\setbeamerfont{block title alerted}{family=\Book,size=\large}
|
|
|
|
|
\setbeamerfont{alerted text}{family=\Medium}
|
|
|
|
|
% Captions
|
|
|
|
|
\setbeamerfont{caption name}{family=\Book}
|
|
|
|
|
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
% Titlepage
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
% Titlepage structure
|
2014-06-27 23:11:09 +02:00
|
|
|
|
\def\maketitle{\ifbeamer@inframe\titlepage\else{\setbeamertemplate{background}{}\frame[plain]{\titlepage}}\fi}
|
|
|
|
|
|
|
|
|
|
\def\titlepage{
|
|
|
|
|
\usebeamertemplate{title page}
|
|
|
|
|
}
|
2013-05-16 15:16:01 +02:00
|
|
|
|
\setbeamertemplate{title page}
|
|
|
|
|
{
|
2014-07-08 14:58:35 +02:00
|
|
|
|
% Add background to title page
|
|
|
|
|
\AddToShipoutPictureFG*{\includegraphics[width=\paperwidth]{background.pdf}}
|
|
|
|
|
\begin{minipage}[b][\paperheight]{\textwidth}
|
|
|
|
|
\vspace*{5mm}
|
|
|
|
|
\includegraphics[height=14mm]{logo}\par
|
|
|
|
|
\vspace*{5mm}
|
|
|
|
|
\ifx\insertsubtitle\@empty%
|
|
|
|
|
\else%
|
|
|
|
|
{\usebeamerfont{title}\usebeamercolor[fg]{title}\inserttitle\par}%
|
|
|
|
|
\fi%
|
|
|
|
|
\ifx\insertsubtitle\@empty%
|
|
|
|
|
\else%
|
|
|
|
|
{\usebeamerfont{subtitle}\usebeamercolor[fg]{subtitle}\insertsubtitle\par}%
|
|
|
|
|
\vspace*{5mm}
|
|
|
|
|
\fi%
|
|
|
|
|
\ifx\insertdate\@empty%
|
|
|
|
|
\else%
|
|
|
|
|
{\usebeamerfont{date}\usebeamercolor[fg]{date}\insertdate\par}%
|
|
|
|
|
\fi%
|
|
|
|
|
|
|
|
|
|
\vfill
|
|
|
|
|
|
|
|
|
|
\ifx\insertauthor\@empty%
|
|
|
|
|
\else%
|
|
|
|
|
{\usebeamerfont{author}\usebeamercolor[fg]{author}\insertauthor\par}%
|
|
|
|
|
\fi%
|
|
|
|
|
\ifx\insertinstitut\@empty%
|
|
|
|
|
\else%
|
|
|
|
|
\vspace*{3mm}
|
|
|
|
|
{\usebeamerfont{institute}\usebeamercolor[fg]{institute}\insertinstitute\par}%
|
|
|
|
|
\fi%
|
|
|
|
|
\vspace*{5mm}
|
|
|
|
|
\end{minipage}
|
2013-05-16 15:16:01 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
% Sectionpages
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
% Make Sectionhead uppercase
|
|
|
|
|
\newcommand{\insertsectionHEAD}{%
|
2014-07-08 14:58:35 +02:00
|
|
|
|
\expandafter\insertsectionHEADaux\insertsectionhead}
|
|
|
|
|
\newcommand{\insertsectionHEADaux}[3]{\MakeUppercase{#3}
|
2013-05-16 15:16:01 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
\if@doSectionPage\@empty
|
|
|
|
|
\else
|
|
|
|
|
% Insert frame with section title at every section start
|
|
|
|
|
\AtBeginSection[]
|
|
|
|
|
{
|
|
|
|
|
\begingroup
|
2014-06-27 23:11:09 +02:00
|
|
|
|
\setbeamertemplate{background}{}
|
2014-06-27 15:29:29 +02:00
|
|
|
|
\setbeamercolor{background canvas}{bg=hriWarmGreyDark}
|
2013-05-16 15:16:01 +02:00
|
|
|
|
\begin{frame}[plain]
|
|
|
|
|
\centering
|
|
|
|
|
\vfill\usebeamerfont{section title}\textcolor{white}{\insertsectionHEAD}\vfill
|
|
|
|
|
\end{frame}
|
|
|
|
|
\endgroup
|
|
|
|
|
}
|
|
|
|
|
\fi
|
|
|
|
|
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
% Frametitle
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
\setbeamertemplate{frametitle}
|
|
|
|
|
{
|
|
|
|
|
\begin{beamercolorbox}[wd=\paperwidth,leftskip=0.3cm,rightskip=0.3cm,ht=3ex,dp=1.5ex]{frametitle}
|
2016-02-15 17:53:17 +01:00
|
|
|
|
\usebeamerfont{frametitle}\MakeUppercase{\insertframetitle}%
|
2013-05-16 15:16:01 +02:00
|
|
|
|
\end{beamercolorbox}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
% Footline
|
2014-03-24 14:52:51 +01:00
|
|
|
|
%---------------------------------------------------------------------
|
2013-05-16 15:16:01 +02:00
|
|
|
|
\usenavigationsymbolstemplate{}
|
|
|
|
|
\setbeamertemplate{footline}
|
|
|
|
|
{%
|
|
|
|
|
\begin{beamercolorbox}[wd=\textwidth,ht=3ex,dp=1.5ex,leftskip=0.3cm,rightskip=0.3cm]{structure}%
|
2014-07-08 14:39:53 +02:00
|
|
|
|
\usebeamerfont{page number in head/foot}%
|
|
|
|
|
\hfill\insertframenumber%
|
2013-05-16 15:16:01 +02:00
|
|
|
|
\end{beamercolorbox}%
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
% Captions
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
\setbeamertemplate{caption label separator}{: }
|
|
|
|
|
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
% Blocks
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
\setbeamertemplate{block begin}
|
|
|
|
|
{
|
|
|
|
|
\setbeamercolor{item}{parent=block body}
|
|
|
|
|
\par\vskip\medskipamount%
|
|
|
|
|
\begin{beamercolorbox}[sep=.5ex,dp=0.6ex,leftskip=0.5ex,rightskip=0.5ex]{block title}
|
|
|
|
|
\usebeamerfont*{block title}\insertblocktitle%
|
|
|
|
|
\end{beamercolorbox}%
|
|
|
|
|
{\parskip0pt\par}%
|
|
|
|
|
{\nointerlineskip\vskip-0.5pt}%
|
|
|
|
|
\usebeamerfont{block body}%
|
|
|
|
|
\begin{beamercolorbox}[sep=.5ex,dp=0.6ex,leftskip=0.5ex,rightskip=0.5ex,vmode]{block body}%
|
|
|
|
|
}
|
|
|
|
|
\setbeamertemplate{block end}
|
|
|
|
|
{\end{beamercolorbox}\vskip\smallskipamount}
|
|
|
|
|
|
|
|
|
|
\setbeamertemplate{block alerted begin}
|
|
|
|
|
{
|
|
|
|
|
\setbeamercolor{item}{parent=block body alerted}
|
|
|
|
|
\par\vskip\medskipamount%
|
|
|
|
|
\begin{beamercolorbox}[sep=.5ex,dp=0.6ex,leftskip=0.5ex,rightskip=0.5ex]{block title alerted}
|
|
|
|
|
\usebeamerfont*{block title alerted}\insertblocktitle%
|
|
|
|
|
\end{beamercolorbox}%
|
|
|
|
|
{\parskip0pt\par}%
|
|
|
|
|
{\nointerlineskip\vskip-0.5pt}%
|
|
|
|
|
\usebeamerfont{block body alerted}%
|
|
|
|
|
\begin{beamercolorbox}[sep=.5ex,dp=0.6ex,leftskip=0.5ex,rightskip=0.5ex,vmode]{block body alerted}%
|
|
|
|
|
}
|
|
|
|
|
\setbeamertemplate{block alerted end}
|
|
|
|
|
{\end{beamercolorbox}\vskip\smallskipamount}
|
|
|
|
|
|
|
|
|
|
\setbeamertemplate{block example begin}
|
|
|
|
|
{
|
|
|
|
|
\par\vskip\medskipamount%
|
|
|
|
|
\begin{beamercolorbox}[sep=.5ex,dp=0.6ex,leftskip=0.5ex,rightskip=0.5ex]{block title example}
|
|
|
|
|
\usebeamerfont*{block title example}\insertblocktitle%
|
|
|
|
|
\end{beamercolorbox}%
|
|
|
|
|
{\parskip0pt\par}%
|
|
|
|
|
{\nointerlineskip\vskip-0.5pt}%
|
|
|
|
|
\usebeamerfont{block body example}%
|
|
|
|
|
\begin{beamercolorbox}[sep=.5ex,dp=0.6ex,leftskip=0.5ex,rightskip=0.5ex,vmode]{block body example}%
|
|
|
|
|
}
|
|
|
|
|
\setbeamertemplate{block example end}
|
|
|
|
|
{\end{beamercolorbox}\vskip\smallskipamount}
|
|
|
|
|
|
2016-02-15 17:39:00 +01:00
|
|
|
|
%%%%%%%%%%%%%%%%%%%%%%%%%% Syntax coloring with minted %%%%%%%%%%%%%%%%%%%%
|
|
|
|
|
\RequirePackage[cache]{minted}
|
|
|
|
|
\renewcommand{\theFancyVerbLine}{
|
|
|
|
|
\sffamily\textcolor[rgb]{0.5,0.5,0.5}{\scriptsize\arabic{FancyVerbLine}}}
|
|
|
|
|
|
|
|
|
|
\newminted{cpp}{frame=lines,
|
|
|
|
|
linenos=false,
|
|
|
|
|
fontsize=\small,
|
|
|
|
|
xleftmargin=1.8em}
|
|
|
|
|
|
|
|
|
|
\newmintinline[cpp]{cpp}{fontsize=\small}
|
|
|
|
|
|
|
|
|
|
\newminted{python}{frame=lines,
|
|
|
|
|
linenos=false,
|
|
|
|
|
fontsize=\small,
|
|
|
|
|
xleftmargin=1.8em}
|
|
|
|
|
|
|
|
|
|
\newmintinline[python]{python}{fontsize=\small}
|
|
|
|
|
|
|
|
|
|
\newminted{sh}{frame=lines,
|
|
|
|
|
linenos=false,
|
|
|
|
|
fontsize=\small,
|
|
|
|
|
xleftmargin=1.8em}
|
|
|
|
|
|
|
|
|
|
\newmintinline[sh]{sh}{fontsize=\small}
|
|
|
|
|
|
|
|
|
|
\newminted{xml}{frame=lines,
|
|
|
|
|
linenos=false,
|
|
|
|
|
fontsize=\small,
|
|
|
|
|
xleftmargin=1.8em}
|
|
|
|
|
|
|
|
|
|
\newmintinline[xml]{xml}{fontsize=\small}
|
|
|
|
|
|
|
|
|
|
|
2013-05-16 15:16:01 +02:00
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
% Images
|
|
|
|
|
%---------------------------------------------------------------------
|
|
|
|
|
|
2014-07-08 14:39:53 +02:00
|
|
|
|
|
2013-05-16 15:16:01 +02:00
|
|
|
|
\newbox\mytempbox
|
|
|
|
|
\newdimen\mytempdimen
|
|
|
|
|
|
|
|
|
|
\newcommand\includegraphicscopyright[3][]{%
|
|
|
|
|
\leavevmode\vbox{\vskip3pt\raggedright\setbox\mytempbox=\hbox{\includegraphics[#1]{#2}}%
|
|
|
|
|
\mytempdimen=\wd\mytempbox\box\mytempbox\par\vskip1pt%
|
|
|
|
|
\usebeamerfont{copyright text}{\usebeamercolor[fg]{copyright text}{\vbox{\hsize=\mytempdimen#3}}}\vskip3pt%
|
|
|
|
|
}}
|
|
|
|
|
|
2014-06-27 23:12:46 +02:00
|
|
|
|
\newcommand\fullbackground[1]{%
|
|
|
|
|
\setbeamertemplate{background}{
|
2016-02-15 17:53:17 +01:00
|
|
|
|
\includegraphics[width=\paperwidth, height=\paperheight,keepaspectratio]{#1}
|
2014-06-27 23:12:46 +02:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2016-02-15 17:53:17 +01:00
|
|
|
|
\newcommand\imageframe[3][]{%
|
2014-07-08 14:39:53 +02:00
|
|
|
|
{
|
2014-10-07 10:10:11 +02:00
|
|
|
|
\setbeamertemplate{background canvas}{
|
2016-02-15 17:53:17 +01:00
|
|
|
|
\ifstrempty{#1}{
|
|
|
|
|
\colorlet{bgcolor}{white}%
|
|
|
|
|
}{
|
|
|
|
|
\colorlet{bgcolor}{#1}%
|
|
|
|
|
}
|
|
|
|
|
\begin{tikzpicture}[remember picture, overlay,background
|
|
|
|
|
rectangle/.style={fill=bgcolor}, show background rectangle]
|
|
|
|
|
\useasboundingbox (current page.north east) rectangle (current page.south west);
|
|
|
|
|
|
|
|
|
|
\node at (current page.center) {\includegraphics[width=\paperwidth,height=\paperheight,keepaspectratio]{#3}};
|
|
|
|
|
\end{tikzpicture}
|
|
|
|
|
|
2014-10-07 10:10:11 +02:00
|
|
|
|
}
|
|
|
|
|
\setbeamertemplate{background}{}
|
2016-02-15 17:53:17 +01:00
|
|
|
|
|
2014-10-07 10:10:11 +02:00
|
|
|
|
\begin{frame}[plain]
|
2016-02-15 17:53:17 +01:00
|
|
|
|
\ifstrempty{#2}{
|
2014-10-07 10:10:11 +02:00
|
|
|
|
% #1 is empty
|
|
|
|
|
}{
|
|
|
|
|
\begin{tikzpicture}[remember picture,overlay]
|
|
|
|
|
\node at (-1, -4.5) [anchor=south west,shape=rectangle,fill=hriSec3Dark, opacity=0.7, align=right, text width=0.6\paperwidth]
|
2016-02-15 17:53:17 +01:00
|
|
|
|
{\usebeamerfont{subtitle}\usebeamercolor[bg]{subtitle}#2\par};
|
2014-10-07 10:10:11 +02:00
|
|
|
|
\end{tikzpicture}
|
2014-07-08 14:39:53 +02:00
|
|
|
|
}
|
2014-10-07 10:10:11 +02:00
|
|
|
|
\end{frame}
|
2014-07-08 14:39:53 +02:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2016-02-15 17:53:17 +01:00
|
|
|
|
\newcommand\grid{
|
|
|
|
|
\draw[help lines] (current page.south west) grid (14,10);
|
|
|
|
|
\foreach \x in {-5,...,5} {
|
|
|
|
|
\foreach \y in {-5,...,5} {
|
|
|
|
|
\node at (\x,\y) [anchor=south west,gray]{{\fontsize{1.2mm}{0.1em}\selectfont (\x,\y)}};
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
\newcommand\bgframe[2][]{%
|
|
|
|
|
{
|
|
|
|
|
\setbeamertemplate{background canvas}{
|
|
|
|
|
\noindent\colorbox{black}{%
|
|
|
|
|
\parbox[c][\paperheight][c]{\paperwidth}{%
|
|
|
|
|
\ifstrempty{#1}{
|
|
|
|
|
% #1 is empty
|
|
|
|
|
}{
|
|
|
|
|
\centering
|
|
|
|
|
\includegraphics[width=\paperwidth,height=\paperheight,keepaspectratio]{#1}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
\setbeamertemplate{background}{}
|
|
|
|
|
|
|
|
|
|
\begin{frame}[plain]
|
|
|
|
|
#2
|
|
|
|
|
\end{frame}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
2014-07-08 14:39:53 +02:00
|
|
|
|
% for a video like: figs/video1.mpg, an image called figs/video1_thumb.jpg
|
|
|
|
|
% exists, it is used to preview the video. Otherwise a blank object is returned.
|
|
|
|
|
\newcommand{\includepreview}[1]{{
|
2016-02-15 17:53:17 +01:00
|
|
|
|
\makeatletter
|
|
|
|
|
\filename@parse{#1}
|
|
|
|
|
\edef\videoThumb{\filename@area\filename@base_thumb.jpg}%
|
|
|
|
|
\makeatother
|
|
|
|
|
\IfFileExists{\videoThumb}{
|
|
|
|
|
\begin{tikzpicture}
|
|
|
|
|
\node at (0, 0) {\includegraphics{\videoThumb}};
|
|
|
|
|
\node[circle] at (1,5) {};
|
|
|
|
|
\end{tikzpicture}
|
|
|
|
|
}{\phantom{a}}
|
2014-07-08 14:39:53 +02:00
|
|
|
|
}}
|
|
|
|
|
|
|
|
|
|
% the optional argument is the aspect ratio
|
2014-10-07 10:10:11 +02:00
|
|
|
|
% (default to full-screen, ie 4:3 for Beamer)
|
2014-07-08 14:39:53 +02:00
|
|
|
|
% for instance, for 16:9 (9/16 = 0.56): \videoframe[0.56]{myvideo.webm}
|
|
|
|
|
\newcommand\videoframe[2][]{%
|
2014-10-07 10:10:11 +02:00
|
|
|
|
{
|
|
|
|
|
\setbeamertemplate{background canvas}{
|
|
|
|
|
\ifstrempty{#1}{
|
|
|
|
|
% #1 is empty
|
2016-02-15 17:53:17 +01:00
|
|
|
|
\noindent\colorbox{black}{%
|
|
|
|
|
\parbox[c][\paperheight][c]{\paperwidth}{%
|
2014-10-07 10:10:11 +02:00
|
|
|
|
\href{run:#2}{\resizebox{\paperwidth}{\paperheight}{\includepreview{#2}}}
|
2016-02-15 17:53:17 +01:00
|
|
|
|
}
|
|
|
|
|
}
|
2014-10-07 10:10:11 +02:00
|
|
|
|
}{
|
2014-07-08 14:39:53 +02:00
|
|
|
|
\noindent\colorbox{black}{%
|
|
|
|
|
\parbox[c][\paperheight][c]{\paperwidth}{%
|
2014-10-07 10:10:11 +02:00
|
|
|
|
\href{run:#2}{\resizebox{\paperwidth}{#1\paperwidth}{\includepreview{#2}}}
|
|
|
|
|
}
|
2014-07-08 14:39:53 +02:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
2014-10-07 10:10:11 +02:00
|
|
|
|
\setbeamertemplate{background}{}
|
|
|
|
|
\begin{frame}[plain]
|
|
|
|
|
\end{frame}
|
|
|
|
|
}
|
2014-07-08 14:39:53 +02:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
\newcommand\video[3][]{%
|
2014-10-07 10:10:11 +02:00
|
|
|
|
\ifstrempty{#1}{
|
|
|
|
|
% #1 is empty, we assume an aspect ratio of 16:9
|
|
|
|
|
\href{run:#3}{\resizebox{#2}{#2*\real{0.56}}{\includepreview{#3}}}
|
|
|
|
|
}{
|
|
|
|
|
\href{run:#3}{\resizebox{#2}{#2*\real{#1}}{\includepreview{#3}}}
|
|
|
|
|
}
|
2014-06-27 23:12:46 +02:00
|
|
|
|
}
|
2014-07-08 14:39:53 +02:00
|
|
|
|
|
|
|
|
|
\newcommand\paper[1]{%
|
|
|
|
|
\setbeamertemplate{footline}
|
|
|
|
|
{%
|
|
|
|
|
\begin{beamercolorbox}[wd=\textwidth,ht=3ex,dp=1.5ex,leftskip=0.3cm,rightskip=0.3cm]{structure}%
|
|
|
|
|
\usebeamerfont{page number in head/foot}%
|
|
|
|
|
[#1]\mbox{}\hfill\insertframenumber%
|
|
|
|
|
\end{beamercolorbox}%
|
|
|
|
|
}
|
2014-06-27 23:12:46 +02:00
|
|
|
|
}
|
|
|
|
|
|
2016-02-15 17:34:59 +01:00
|
|
|
|
\newcommand\licenseframe[1]{%
|
|
|
|
|
\begin{frame}[plain]
|
|
|
|
|
\centering
|
|
|
|
|
\vfill
|
|
|
|
|
\includegraphics[width=0.3\paperwidth]{by-sa}
|
|
|
|
|
|
|
|
|
|
This presentation is released under the terms of the\\
|
|
|
|
|
{\Medium \href{http://creativecommons.org/licenses/by-sa/4.0/}{Creative Commons Attribution-Share Alike}} license.
|
|
|
|
|
|
|
|
|
|
\vspace{1em}
|
|
|
|
|
\small You are free to reuse it and modify it as much as you want as long as\\
|
|
|
|
|
\small (1) you mention me as being the original author,\\
|
|
|
|
|
\small (2) you re-share your presentation under the same terms.\\
|
|
|
|
|
|
|
|
|
|
\normalsize\vspace{1em}
|
|
|
|
|
You can download the sources of this presentation here:\\
|
|
|
|
|
{\Medium\url{#1}}
|
|
|
|
|
\end{frame}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
2014-06-27 23:12:46 +02:00
|
|
|
|
|
2013-05-16 15:16:01 +02:00
|
|
|
|
\mode
|
|
|
|
|
<all>
|