-
Notifications
You must be signed in to change notification settings - Fork 1
/
beamerthemelu.sty
80 lines (71 loc) · 2.42 KB
/
beamerthemelu.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
70
71
72
73
74
75
76
77
78
79
80
%% beamerthemelu.sty
%% Copyright 2023 J.P. van Leenen
%
% This work may be distributed and/or modified under the
% conditions of the LaTeX Project Public License, either version 1.3
% of this license or (at your option) any later version.
% The latest version of this license is in
% https://www.latex-project.org/lppl.txt
% and version 1.3c or later is part of all distributions of LaTeX
% version 2008 or later.
%
% This work has the LPPL maintenance status `maintained'.
%
% The Current Maintainer of this work is J.P. van Leenen.
\mode<presentation>
% Requirement
\RequirePackage{tikz}
\RequirePackage{babel}
\RequirePackage{fontspec}
\RequirePackage{listings}
% Options
\DeclareOptionBeamer{style}{\PassOptionsToPackage{style=#1}{beamercolorthemelu}}
\DeclareOptionBeamer{footer}{\PassOptionsToPackage{footer=#1}{beamerouterthemelu}}
\DeclareOptionBeamer{styleslidenumbering}{\PassOptionsToPackage{styleslidenumbering=#1}{beamercolorthemelu}}
\DeclareOptionBeamer{addstandoutfootline}{\PassOptionsToPackage{addstandoutfootline=#1}{beamerinnerthemelu}}
\DeclareOptionBeamer{accentdefault}{\def\beamer@lu@accentdefault{#1}}
\ProcessOptionsBeamer
% Themes
\useinnertheme{lu}
\useoutertheme{lu}
\usecolortheme{lu}
\usecolortheme{rose}
\setbeamertemplate{navigation symbols}{}
% Font-related
\IfFontExistsTF{Minion Pro Regular.ttf}{%
\setsansfont{Minion Pro}[
Extension = .ttf,
UprightFont = * Regular,
BoldFont = * Bold,
ItalicFont = * Italic,
BoldItalicFont = * Bold Italic
]}{}
\usefonttheme{professionalfonts}
\setbeamerfont{frametitle}{series=\bfseries, size=\LARGE}
\setbeamerfont{framesubtitle}{series=\mdseries}
\setbeamerfont{title}{series=\bfseries,size=\huge}
\setbeamerfont{subtitle}{series=\mdseries}
\setbeamerfont{footline}{size=\scriptsize}
% Custom Commands
\def\beamer@lu@lu{LU}
\newcommand<>{\accent}[2][orange]{%
{\setbeamercolor{alerted text}{fg=#1\beamer@lu@lu}%
\begin{alertenv}
#3\relax#2%
\end{alertenv}}%
}
% Custom Styles
% This Listings style is primarily focused on usage with Python due to its popularity
\lstdefinestyle{lu}{
showstringspaces=false,
upquote=true,
numbers=left,
numberstyle=\tiny,
frame=Ltb,
basicstyle=\normalsize\ttfamily,
keywordstyle=\color{orangeLU}, % core keywords
keywordstyle={[2]\color{violetLU}}, % built-ins
stringstyle=\color{darkgreenLU},
commentstyle=\color{turquoiseLU},
}
\mode<all>