-
Notifications
You must be signed in to change notification settings - Fork 0
/
beamerthemeudec.sty
123 lines (113 loc) · 3.07 KB
/
beamerthemeudec.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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
\mode<presentation>
\setbeamercolor*{transparent}{fg=, bg=}
\setbeamerfont{title}{size=\LARGE,parent=structure,series=\bfseries}
\setbeamerfont{title in head/foot}{series=\bfseries}
\setbeamerfont{institute}{size=\normalsize}
\setbeamerfont{date}{size=\normalsize}
\setbeamertemplate{navigation symbols}{}
\setbeamerfont{footnote}{size=\tiny}
\setbeamertemplate{caption}{\raggedright\insertcaption\par}
\AtBeginEnvironment{frame}{\setcounter{footnote}{0}}
% Texto en filas
\defbeamertemplate*{first row}{udec}{
\usebeamerfont{title}
\usebeamercolor{title}
\raggedright\inserttitle
\vspace{1cm}
}
\defbeamertemplate*{second row}{udec}{
\usebeamerfont{author}
\usebeamercolor{author}
\insertauthor
}
\defbeamertemplate*{third row}{udec}{
\parbox[c]{0.7\textwidth}{
\usebeamerfont{institute}
\usebeamercolor{institute}
\insertinstitute
}
\hfill
\usebeamerfont{date}
\usebeamercolor{date}
\insertdate
}
% Macro para cuadros con texto centrado
% Argumentos
% #1 Ancho de caja
% #2 Ancho de texto dentro de caja
% #3 Altura de caja
% #4 Color
% #5 Ajuste vertical del texto
\newenvironment{colorparbox}[5][\paperwidth]{
\begin{beamercolorbox}[wd=#1,ht=#3]{#4}
\centering
\begin{minipage}[b][#3][#5]{#2}
}
{
\end{minipage}
\end{beamercolorbox}
}
% Portada
\defbeamertemplate*{title page}{udec}{
\vspace{-\headheight}
\offinterlineskip
\begin{colorparbox}{\textwidth}{0.55\paperheight}{palette primary}{b}
\usebeamertemplate{first row}
\end{colorparbox}
\vspace{-0.55\paperheight}
\begin{colorparbox}{\paperwidth}{0.55\paperheight}{transparent}{t}
\vspace{0.1cm}
\hfill%
\includegraphics[width=3cm]{udec.png}
\end{colorparbox}
\begin{colorparbox}{\textwidth}{0.15\paperheight}{palette secondary}{c}
\usebeamertemplate{second row}
\end{colorparbox}
\begin{colorparbox}{\textwidth}{0.25\paperheight}{normal text}{c}
\usebeamertemplate{third row}
\end{colorparbox}
}
% Pie de página
\defbeamertemplate*{footline}{udec}{
\begin{colorparbox}{0.9\paperwidth}{0.05\paperheight}{palette primary}{c}
\usebeamerfont{title in head/foot}%
\usebeamercolor{title in head/foot}%
\insertsubtitle
\hfill
\ifbeamer@noframenumbering\else%
\usebeamerfont{page number in head/foot}%
\usebeamerfont{page number in head/foot}%
\insertframenumber%
\fi
\end{colorparbox}
}
% Fondo
\defbeamertemplate*{background}{udec}{
\makebox[\paperwidth][r]{
\includegraphics[width=2cm]{dim.png}
}
}
% Título de sección
\defbeamertemplate*{section page}{udec}[1][]{
\begingroup
\centering
{\usebeamerfont{section name}\usebeamercolor[fg]{section name}\phantom{\sectionname~\insertsectionnumber}}
\vskip1em\par
\begin{beamercolorbox}[sep=12pt,center,#1]{section title}
\usebeamerfont{section title}\insertsection\par
\end{beamercolorbox}
\endgroup
}
% Título de subsección
\defbeamertemplate*{subsection page}{udec}[1][]{
\begingroup
\centering
{\usebeamerfont{subsection name}\usebeamercolor[fg]{subsection name}\phantom{\subsectionname~\insertsubsectionnumber}}
\vskip1em\par
\begin{beamercolorbox}[sep=8pt,center,#1]{subsection title}
\usebeamerfont{subsection title}\insertsubsection\par
\end{beamercolorbox}
\endgroup
}
\mode
<all>