summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/pas-cv/latex/macro-saturne.tex
blob: 86a315794cfd1eabf0d00bd8f3f4f8ae3991d2c7 (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
76
\def\modele@saturne{saturne}
\def\cv@h@saturne{5}

% =============== FOND ===============
\newcommand*\fond@saturne{%
	% Création d'un dégradé dans la colonne de gauche
	\shade[right color=gray!20,left color=white] (7,0) rectangle +(-7,-\paperheight);
	\draw[color=gray,thick] (7,0) -- (7,-\paperheight);
	% Création du rectangle et des traits
	\draw[very thick,color=\cmdPAS@bg@bordercolor] (0,-\cv@h@saturne+.15) -- (\paperwidth,-\cv@h@saturne+.15);
	\draw[very thick,color=\cmdPAS@bg@bordercolor] (0,-2.15-\cv@h@saturne) -- (\paperwidth,-2.15-\cv@h@saturne);
	\fill[fill=\cmdPAS@bg@bgcolor] (0,-\cv@h@saturne) rectangle +(\paperwidth,-2);
	\ifx\cmdPAS@bg@pic\@empty%
	\else
		\ifx\cmdPAS@bg@borderpic\@empty
			\node at (2.5,-1-\cv@h@saturne) {\includegraphics[scale=\cmdPAS@bg@scalepic]{\cmdPAS@bg@pic}};
		\else
			\node[draw=\cmdPAS@bg@borderpic,very thick,inner sep=1pt] at (2.5,-1-\cv@h@saturne) {\includegraphics[scale=\cmdPAS@bg@scalepic]{\cmdPAS@bg@pic}};
		\fi
	\fi
	\clip (0,-\cv@h@saturne) rectangle +(\paperwidth,-2);
	\shade[bottom color=\cmdPAS@bg@bgcolor!80!white,top color=\cmdPAS@bg@bgcolor,rotate=10,opacity=.2] (.5\paperwidth,-2-\cv@h@saturne) ellipse (5 and 1.5);
	\node[left,color=\cmdPAS@bg@postecolor] at (.97\paperwidth,-1-\cv@h@saturne) {\scshape\cmdPAS@bg@postesize\bfseries\cmdPAS@bg@poste};
}

%=============== INFO GAUCHE ===============
\newcommand*\infoLeft@saturne[1]{%
	\AddToShipoutPicture{%
		\put(\LenToUnit{1cm},\LenToUnit{.97\paperheight})
			{%
				\rlap{
					\begin{minipage}[t]{0.5\paperwidth}
						#1
					\end{minipage}
				}
			}
	}
}

%=============== INFO DROITE ===============
\newcommand*\infoRight@saturne[1]{%
	\AddToShipoutPicture{%
		\put(\LenToUnit{.97\paperwidth},\LenToUnit{.97\paperheight}){%
			\llap{%
			\begin{minipage}[t]{.5\paperwidth}
				\begin{flushright}#1\end{flushright}
			\end{minipage}
			}
		}
	}
}

%=============== TITRE ===============
\newcommand*\title@saturne[1]{%
	\noindent
	\begin{tikzpicture}
		\fill[color=\cmdPAS@title@bordercolor,rotate=10] (0,-.25) ellipse (.25 and .125);
		\node[below right,text=\cmdPAS@title@color] (title) at (.33,0) {\begin{minipage}{5cm}\scshape\bfseries #1\end{minipage}};
	\end{tikzpicture}
}

%=============== MARGES ===============
\newcommand*\margins@saturne{%
\FPeval\result{clip(\cv@h@saturne+3)}
\newgeometry{tmargin=\result cm,bmargin=1.5cm,lmargin=1cm,rmargin=1cm}
}

%=============== CLEARPAGE ===============
\newcommand*\clearpage@saturne{%
	% Création d'un dégradé dans la colonne de droite
	\shade[right color=gray!20,left color=white] (7,0) rectangle +(-7,-\paperheight);
	\draw[color=gray,thick] (7,0) -- (7,-\paperheight);
}
\newcommand*\clearmargins@saturne{%
	\newgeometry{tmargin=2cm,bmargin=1.5cm,lmargin=1cm,rmargin=1cm}
}