-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpreambuleInfoBR.sty
256 lines (205 loc) · 7.97 KB
/
preambuleInfoBR.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
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
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
\ProvidesPackage{preambuleInfoBR}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%Les extensions utilisées
%version 2k12 : j'ai comment\'e tous les packages de maths. Ils n'�taient pas n\'ecessaires \`a la compilation. Si \c{c}a compile sans c'est que ce n'\'etait pas n\'ec\'essaire.
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage[french]{babel}
\usepackage{fancyhdr}
\usepackage{xspace}
\usepackage[ec]{aeguill}
\usepackage{amsfonts}
\usepackage{amsmath}
\usepackage{amssymb}
\usepackage{eurosym}
\usepackage{watermark}
\usepackage{wrapfig}
\usepackage{multirow}
\usepackage{graphicx}
\usepackage{subfig}
\usepackage{array}
\usepackage{color}
\usepackage{microtype}
\usepackage{ifthen}
\usepackage[bookmarks=true,bookmarksnumbered=true,colorlinks=false,pdfborder={0 0 0}]{hyperref} %permet de cr\eer des ancres au niveau du sommaire
\usepackage{tabu}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Successful (so far) attempt by marteo to fix the "missing nonbreakable space before ':' in Figures captions" bug.
\makeatletter
\renewcommand{\fnum@figure}{\figurename~\thefigure~}
\makeatother
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%Mise en page
%On rend les fins de pages homogènes (par rapport aux marges)
\flushbottom
%Suppression veuves et orphelines
\clubpenalty=10000
\widowpenalty=10000
% En-têtes et pieds-de-page personalisés
\pagestyle{fancy}
\renewcommand{\sectionmark}[1]{\markboth{\MakeUppercase{#1}}{}}
\renewcommand{\subsectionmark}[1]{\markright{\thesubsection\ #1}}
\fancyhf{}
%Note du BR2k13 : Pas compris le coup de la page 11... supprimé la modif pour rétablir une bonne numérotation de pages
%Note du BR2k14 : Rétablissement d'une page 11, sur un sujet récurrent.
% Le compteur, � changer manuellement, garde en mémoire le numéro de la page contenant les informations sur les cross-posts.
% Il suffit de changer le numéro de la page, puis de lancer compil_finale
% Modif de marteo : provisoirement, c'est 37, c'est à dire n+1, vu qu'il n'y a plus rien sur les crossposts.
\newcounter{cptr}
\setcounter{cptr}{16}
% On prend en compte la modification pour la page 11
\fancyhead[LE,RO]{%\Large \thepage}%
\ifthenelse{\thepage=11}%
{\bfseries{\Large \thecptr}}% si test = vrai
{\ifthenelse{\thepage=\thecptr}%
{\bfseries{\Large 11}}% test vrai
{\Large \thepage}%test faux
}%
}
\fancyhead[LO]{\rightmark}
\fancyhead[RE]{\sc{\leftmark}}
\fancypagestyle{plain}{%
\fancyhead{} % get rid of headers
\renewcommand{\headrulewidth}{0pt} % and the line
}
%On agrandit les marges
\addtolength{\headwidth}{80pt}
\addtolength{\headheight}{3pt}
%% A very stupid attempt by marteo, history to make disappear un wild warning from the log.
%\addtolength{\headheight}{7pt}
\addtolength{\evensidemargin}{-60pt}
\addtolength{\voffset}{-24pt}
\addtolength{\textheight}{85pt}
\addtolength{\textwidth}{60pt}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Quelques couleurs perso
\definecolor{Blue}{cmyk}{0.6,0.0,0.05,0.0} %#66FFF2
\definecolor{Blue2}{cmyk}{0.6,0.2,0.0,0.0} %#66CCFF
\definecolor{DarkBlue}{cmyk}{0.95,0.8,0.0,0.0} %#0D33FF
\definecolor{BrightGreen}{cmyk}{0.8,0.,1.0,0.0} %#0D33FF
\definecolor{GreenApp}{cmyk}{0.7,0.0,1.0,0.8} %#0F0033
\definecolor{GreenPseudo}{cmyk}{0.8,0.1,1.0,0.1} %#2ECF00
\definecolor{DarkGreen}{cmyk}{0.8,0.1,0.9,0.4} %#1F8A0F
\definecolor{Orange}{cmyk}{0.,0.2,1.0,0.2} %#CCA300
\definecolor{DarkOrange}{cmyk}{0.,0.4,1.0,0.4} %#995C00
\definecolor{LightRed}{cmyk}{0.,0.1,0.15,0.0} %#FFE6D9
\definecolor{GrayMenu}{cmyk}{0.7,0.5,0.6,0.4} %#2E4D3D
\definecolor{light-gray}{gray}{0.95}
\definecolor{med-gray}{gray}{0.70}
\definecolor{dark-gray}{gray}{0.30}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%Gestion de l'iconographie
% pour les images de fond sous les en-têtes
\newcommand{\bghdr}[1]{
\leftwatermark{
\raisebox{-1.5cm}{ \hspace{-2.5cm} \includegraphics[width=3.5cm]{#1} }
}
\rightwatermark{
\raisebox{-1.5cm}{ \hspace{14.1cm} \includegraphics[width=3.5cm]{#1} }
}
}
% pour inclure des images: différentes possibilités
\newcommand{\image}[3]{ % arguments : path, largeur (entre 0 et 1), légende
\begin{figure*}
\begin{center}
\includegraphics[width=#2\textwidth]{#1}
\caption{#3}
\end{center}
\end{figure*}
}
\newcommand{\imagepos}[4]{ % arguments : path, largeur (entre 0 et 1), légende, positionnement
\begin{figure*}[#4]
\begin{center}
\includegraphics[width=#2\textwidth]{#1}
\caption{#3}
\end{center}
\end{figure*}
}
\newcommand{\imageref}[5]{ % arguments : path, largeur (entre 0 et 1), l\'egende, positionnement, label
\begin{figure*}[#4]
\begin{center}
\includegraphics[width=#2\textwidth]{#1}
\caption{#3} \label{#5}
\end{center}
\end{figure*}
}
\newcommand{\flimage}[3]{ % arguments : path, largeur (entre 0 et 1), position
\begin{wrapfigure}{#3}{0pt}
\includegraphics[width=#2\textwidth]{#1}
\end{wrapfigure}
}
% Les logos win, nux et mac
\newcommand{\nuxs}{\includegraphics{images/logo_Linux_s}}
\newcommand{\wins}{\includegraphics{images/logo_Windows_s}}
\newcommand{\macs}{\includegraphics{images/logo_Mac_s}}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%Environnement ligne de commande et exemples
\newcommand{\cmdline}[2][0.9]{
\vspace{2pt plus 1pt minus 1pt}
\noindent
\begin{center}
\colorbox{light-gray}{
\parbox[c]{#1\textwidth}{
\NoAutoSpaceBeforeFDP
\texttt{\footnotesize{\color{dark-gray}#2}}
\AutoSpaceBeforeFDP
}
}
\end{center}
\vspace{2pt plus 1pt minus 1pt}
}
\newcommand{\cmdlineshort}[1]{
\noindent
\colorbox{light-gray}{
\parbox{.2\textwidth}{
\NoAutoSpaceBeforeFDP
\texttt{\normalsize{\color{dark-gray}#1}}
\AutoSpaceBeforeFDP
}
}
\vspace{4pt}
}
\newcommand{\exemple}[1]{ \fcolorbox{black}{light-gray} {
\begin{minipage}{0.9\textwidth}
\emph{Exemple :} #1
\end{minipage}
}}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%Quelques styles prédéfinis
% texttt : ligne de commande, serveurs
% textsf : tout le reste : url, email, dossiers
% BR2012: passage en niveaux de gris
% pour les serveurs
\newcommand{\server}[1]{\texttt{\color{dark-gray}#1}\xspace}
% pour les URLs
\newcommand{\urllink}[1]{\NoAutoSpaceBeforeFDP\textsf{\color{dark-gray}#1}\AutoSpaceBeforeFDP\xspace}
% pour les mails
\newcommand{\mail}[1]{\textsf{\color{dark-gray}#1}\xspace}
% pour les newsgroups
\newcommand{\ngname}[1]{\textsf{\color{dark-gray}#1}\xspace}
% pour les applications
\newcommand{\app}[1]{\textbf{\color{dark-gray}#1}\xspace}
% pour les menus et les elements de menu
\newcommand{\menu}[1]{\textsf{\color{dark-gray}`#1'}\xspace}
% pour les repertoires
\newcommand{\rep}[1]{\textsf{\color{dark-gray}#1}\xspace}
% pour les fichiers
\newcommand{\file}[1]{\textsf{\color{dark-gray}#1}\xspace}
% pour les distributions Linux
\newcommand{\distrib}[1]{{\color{dark-gray}#1}}
% pour les liens (sous frankiz)
\newcommand{\lien}[1]{\textsf{\color{dark-gray}`#1'}\xspace}
% pour les pseudos
\newcommand{\mbr}[5]{\noindent#3 \bsc{\color{dark-gray}#1} (#4) \textbf{#2} : #5}
% Pour les commandes DOS
\newcommand{\cmd}[1]{\NoAutoSpaceBeforeFDP\guillemotleft~\texttt{#1}~\guillemotright \AutoSpaceBeforeFDP\xspace}
% divers
\newcommand{\fkz}{\server{Frankiz}}
\newcommand{\xshare}{la rubrique \menu{T\'el\'echarger} de \fkz}