-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathpreamble.tex
196 lines (167 loc) · 7.09 KB
/
preamble.tex
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
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
% ------------------------------------------------------------ %
% TIPO Y PAQUETES %
% ------------------------------------------------------------ %
\documentclass[11pt, a4paper]{report}
\usepackage[spanish, es-tabla, activeacute]{babel}
% \usepackage[utf8]{inputenc}
\usepackage[pagestyles]{titlesec}
\usepackage{hyperref}
\usepackage{graphicx}
\usepackage{geometry}
\usepackage{indentfirst}
\usepackage{xcolor}
\usepackage{verbatim}
\usepackage{keyval}
\usepackage{etoolbox}
\usepackage{fontspec}
\usepackage{titling}
\usepackage{tikz}
\usepackage{caption}
\usepackage{chngcntr}
\usepackage[bottom]{footmisc}
\usetikzlibrary{positioning}
\definecolor{eus-color}{gray}{0.4}
\definecolor{eng-color}{gray}{0.5}
\newcommand*{\noaddvspace}{\renewcommand*{\addvspace}[1]{}}
\addtocontents{lof}{\protect\noaddvspace}
\addtocontents{lot}{\protect\noaddvspace}
% ------------------------------------------------------------ %
% NUMERACIÓN CONTINUA DE FIGURAS Y TABLAS %
% ------------------------------------------------------------ %
\counterwithout{figure}{chapter}
\counterwithout{table}{chapter}
% ------------------------------------------------------------ %
% PARTICIÓN DE PALABRAS AL FINAL DE LÍNEA %
% ------------------------------------------------------------ %
\pretolerance=2000
\tolerance=3000
% ------------------------------------------------------------ %
% FUENTES DEL DOCUMENTO %
% ------------------------------------------------------------ %
\setmainfont[
Path = fonts/,
Ligatures = TeX,
UprightFont = EHUSans-Light.otf,
BoldItalicFont= EHUSans-BoldItalic.otf,
BoldFont = EHUSans-Bold.otf,
ItalicFont = EHUSans-LightItalic.otf
]{EHUSans}
\newfontfamily{\sansthick}[
Path = fonts/,
BoldFont = EHUSans-Bold.otf,
UprightFont = EHUSans-Regular.otf
]{EHUSans}
\newfontfamily{\sansblack}[
Path = fonts/,
UprightFont = EHUSans-Black.otf
]{EHUSans}
\newfontfamily{\serif}[
Path = fonts/,
Ligatures = TeX,
UprightFont = EHUSerif-Light.otf,
BoldItalicFont= EHUSerif-BoldItalic.otf,
BoldFont = EHUSerif-Bold.otf,
ItalicFont = EHUSerif-LightItalic.otf
]{EHUSerif}
\newfontfamily{\serifthick}[
Path = fonts/,
BoldFont = EHUSerif-Bold.otf,
UprightFont = EHUSerif-Regular.otf
]{EHUSerif}
\newfontfamily{\serifblack}[
Path = fonts/,
UprightFont = EHUSerif-Black.otf
]{EHUSerif}
% ------------------------------------------------------------ %
% ETIQUETAS EN LAS TABLAS Y FIGURAS %
% ------------------------------------------------------------ %
\DeclareCaptionFont{ehu}{\fontsize{9}{10}\mdseries}
\usepackage[font={ehu}, labelfont={bf}]{caption}
% ------------------------------------------------------------ %
% AÑADIR CUARTO NIVEL DE TÍTULO %
% ------------------------------------------------------------ %
\setcounter{secnumdepth}{4}
\titleformat{\paragraph}
{\normalfont\normalsize\bfseries}{\theparagraph}{1em}{}
\titlespacing*{\paragraph}
{0pt}{3.25ex plus 1ex minus .2ex}{1.5ex plus .2ex}
% ------------------------------------------------------------ %
% ELIMINAR CABECERA DE CAPÍTULOS %
% ------------------------------------------------------------ %
\titleformat{\chapter}%
{\normalfont\bfseries\Huge}{\thechapter.}{10pt}{}
\newpagestyle{mystyle}{
\sethead[][\thechapter.\enspace\chaptertitle][]{}{\thesection~\sectiontitle}{}
\setfoot{}{\thepage}{}}
% ------------------------------------------------------------ %
% MÁRGENES Y DISTANCIA ENTRE PÁRRAFOS %
% ------------------------------------------------------------ %
\geometry{top=2.5cm,left=3cm,right=3cm,bottom=2.5cm}
\setlength{\parskip}{8pt}
% ------------------------------------------------------------ %
% TÍTULO DEL ÍNDICE %
% ------------------------------------------------------------ %
\addto\captionsspanish{
\renewcommand{\contentsname}{Índice}
\renewcommand{\listtablename}{Lista de tablas}
\renewcommand{\listfigurename}{Lista de figuras}
}
% ------------------------------------------------------------ %
% DIRECTORIO DE IMÁGENES %
% ------------------------------------------------------------ %
\graphicspath{{images/}}
% ------------------------------------------------------------ %
% FORMATO DEL TÍTULO %
% El documento principal debe incluir este código: %
%% Título:
%\newcommand{\titulo}{<Título del trabajo>}
%% Curso académico:
%\newcommand{\curso}{<XXXX-XXXX>}
%% Carrera:
%\newcommand{\carrera}{Grado en XXXXXXXX}
%% Alumno/Alumna:
%\newcommand{\alumno}{<apellido 1, apellido 2, nombre>}
%% Dirección 1 del TFG:
%\newcommand{\direccionA}{<apellido 1, apellido 2, nombre>}
%% Dirección 2 del TFG (si no la hay, comentar la línea aquí y también en preamble.tex):
%\newcommand{\direccionB}{<apellido 1, apellido 2, nombre>}
%% Fecha:
%\newcommand{\fecha}{<XXXX, día, mes, año>}
% ------------------------------------------------------------ %
\newcommand{\portada}{
{\raggedleft\includegraphics[width=8cm]{corp/ehu}}
\\[3\baselineskip]
\begin{center}
\LARGE{\MakeUppercase{\carrera}}
\Huge{\textbf{\MakeUppercase{Trabajo de fin de grado}}}
\\[1\baselineskip]
\begin{tikzpicture}
\renewcommand{\baselinestretch}{0.75}
\node (A) at (0.03cm,-0.03cm) [inner sep=20pt, draw, minimum width=\linewidth, text width=13cm, minimum height=104pt, fill=black, align=center]
{\huge{\MakeUppercase{\textbf{\textit{\titulo}}}}};
\node (B) at (0,0) [inner sep=20pt, draw, minimum width=\linewidth, text width=13cm, minimum height=104pt, fill=white, align=center]
{\huge{\MakeUppercase{\textbf{\textit{\titulo}}}}};
\end{tikzpicture}
\end{center}
\renewcommand{\baselinestretch}{1.25}
\begin{tikzpicture}[remember picture, overlay]
\node (C) at ([yshift=-6.95cm, xshift=9.7cm]current page.west) [inner sep=10pt, draw, thick, minimum width=13.34cm, minimum height=64pt, align=left, fill=white]{};
\node (D) [right=0.2cm of C.west, anchor=west, align=left]
{\small{\textbf{Alumno: }\alumno}\\
\small{\textbf{Directora: }\direccionA}
% Comentar la siguiente línea si sólo hay una direcicón del TFG. Eliminar también de la anterior el (1).
%\\\small{\textbf{Director/Directora (2): }\direccionB}
};
\end{tikzpicture}
\renewcommand{\baselinestretch}{1}
\begin{tikzpicture}[remember picture, overlay]
\node (E) at ([yshift=-9.4cm, xshift=8.5cm]current page.west) [inner sep=10pt, draw, thick, minimum width=13.34cm, minimum height=27pt, align=left, fill=white]{};
\node (F) [right=1.4cm of E.west, anchor=west]
{\small{\textbf{Curso: }\curso}};
\end{tikzpicture}
\begin{tikzpicture}[remember picture, overlay]
\node (G) at ([yshift=-11.6cm, xshift=13.4cm]current page.west) [inner sep=10pt, draw, thick, minimum width=7.93cm, minimum height=27pt, align=left, fill=white]{};
\node (H) [left=0.2cm of G.east, anchor=east]
{\small{\textbf{Fecha: }\fecha}};
\end{tikzpicture}
}