blob: d87f1120149b9323af6d3653f7fc715ce4c8ab6f (
plain)
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
|
\makeatletter
\def\@dottedtocline#1#2#3#4#5{%
\ifnum #1>\c@tocdepth \else
\vskip \z@ \@plus.2\p@
{\leftskip #2\relax \rightskip \@tocrmarg \parfillskip -\rightskip
\parindent #2\relax\@afterindenttrue
\interlinepenalty\@M
\leavevmode
\@tempdima #3\relax
\advance\leftskip \@tempdima \null\nobreak\hskip -\leftskip
{#4}\nobreak
\leaders\hbox{$\m@th
\mkern \@dotsep mu\hbox{.}\mkern \@dotsep
mu$}\hfill
\nobreak
\hb@xt@\@pnumwidth{\hfil\helvbx #5}%
\par}%
\fi}
\renewcommand*\l@section
{%
\helvbx\color{red!50!black}\bfseries
\def\@linkcolor{red!50!black}\@dottedtocline{1}{1.5em}{1.5em}
}
\renewcommand*\l@subsection
{%
\helvbx\color{green!50!black}
\def\@linkcolor{green!50!black}
\@dottedtocline{1}{2.3em}{2.6em}
}
\renewcommand*\l@subsubsection
{%
\helvbx\color{orange!80!black}
\def\@linkcolor{orange!80!black}
\@dottedtocline{1}{3em}{3.3em}
}
\def\contentsline#1#2#3#4{%
\ifx\\#4\\%
\csname l@#1\endcsname{#2}{#3}%
\else
\csname l@#1\endcsname{\hyper@linkstart{link}{#4}{#2}\hyper@linkend}{%
\hyper@linkstart{link}{#4}{#3}\hyper@linkend
}%
\fi
}
% --------------------
% TITRES DES SECTIONS
% --------------------
\titleformat{\section}[block]
{\helvbx\Large\color{red!50!black}}
{\fcolorbox{red!50!black}{red!50!black}{\textcolor{white}{\bfseries\thesection}}}
{1em}
{\helvbx}
\titleformat{\subsection}[block]
{\helvbx\large\color{green!50!black}}
{\thesubsection}
{1em}
{\helvbx}
\titleformat{\subsubsection}[block]
{\helvbx\large\color{orange!50!black}}
{\thesubsubsection}
{1em}
{\helvbx}
\makeatother
\newcommand{\helvbx}{\usefont{T1}{phv}{m}{n}}
|