summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/pas-cv/macro-neptune.tex
blob: 7721802cd6f6ee5d7cafc5a459f27948588af574 (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
77
78
79
80
81
82
83
84
85
\def\modele@neptune{neptune}
\def\cv@h@neptune{4}

% =============== FOND ===============
\newcommand*\fond@neptune{%
	% Colonne du milieu
	\fill[top color=\cmdPAS@bg@bgcolor!30,bottom color=white] ($(.5\paperwidth,0)+(-1,0)$) rectangle+(2,-\paperheight);
	% Rectangle haut
	\fill[\cmdPAS@bg@bgcolor] (0,-\cv@h@neptune) rectangle+(\paperwidth,-2.5);
	\foreach \x in {.5,1,...,30}
	{
		\draw[color=\cmdPAS@bg@bgcolor!40!white,opacity=.5] (\x,-\cv@h@neptune) -- (\x,-\cv@h@neptune-2.5);
	}
	\foreach \y in {-4.5,-5,...,-6}
	{
		\draw[color=\cmdPAS@bg@bgcolor!40!white,opacity=.5] (0,\y) -- (30,\y);
	}
	\fill[\cmdPAS@bg@bordercolor] (0,-\cv@h@neptune-1.75) rectangle+(\paperwidth,-.5);
	\fill[\cmdPAS@bg@bgcolor!30!white] (0,-\cv@h@neptune-1.75) rectangle +(\paperwidth,.05);
	\fill[opacity=.8,color=\cmdPAS@bg@bgcolor!30!white] (.7\paperwidth,-\cv@h@neptune-2.5) .. controls (.9\paperwidth,-\cv@h@neptune-2) and (.9\paperwidth,-\cv@h@neptune-1) .. (.95\paperwidth,-\cv@h@neptune) -- (\paperwidth,-\cv@h@neptune) -- (\paperwidth,-\cv@h@neptune-2.5) -- cycle;
	\fill[opacity=.8,color=\cmdPAS@bg@bgcolor!30!white] (.1\paperwidth,-\cv@h@neptune-2.5) .. controls (.1\paperwidth,-\cv@h@neptune-2) and (.15\paperwidth,-\cv@h@neptune-1) .. (.25\paperwidth,-\cv@h@neptune) -- (.05\paperwidth,-\cv@h@neptune) -- (.05\paperwidth,-\cv@h@neptune-2.5) -- cycle;
	\ifx\cmdPAS@bg@pic\@empty%
	\else
		\ifx\cmdPAS@bg@borderpic\@empty
			\node (photo) at (.08\paperwidth,-\cv@h@neptune-1.25) {\includegraphics[scale=\cmdPAS@bg@scalepic]{\cmdPAS@bg@pic}};
		\else
			\node[draw=\cmdPAS@bg@borderpic,very thick,inner sep=1pt] (photo) at (.08\paperwidth,-\cv@h@neptune-1.25) {\includegraphics[scale=\cmdPAS@bg@scalepic]{\cmdPAS@bg@pic}};
		\fi
	\fi
	\node[color=\cmdPAS@bg@postecolor] at (.54\paperwidth,-\cv@h@neptune-1) {\scshape\cmdPAS@bg@postesize\bfseries\cmdPAS@bg@poste};
	\fill[\cmdPAS@bg@bgcolor] (0,-.94\paperheight) rectangle+(\paperwidth,-.01);
}

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

%=============== INFO DROITE ===============
\newcommand*\infoRight@neptune[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@neptune[1]{%
	\noindent
	\begin{tikzpicture}
		\node[text=\cmdPAS@title@color] (title) {\scshape\bfseries #1};
		\fill[left color=\cmdPAS@title@bordercolor,right color=white] ($(title.south)+(0,-.1)$) rectangle+(4,-.025);
		\fill[right color=\cmdPAS@title@bordercolor,left color=white] ($(title.south)+(0,-.1)$) rectangle+(-4,-.025);
	\end{tikzpicture}
}

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

%=============== CLEARPAGE ===============
\newcommand*\clearpage@neptune{%
	% Colonne du milieu
	\fill[top color=\cmdPAS@bg@bgcolor!30,bottom color=white] ($(.5\paperwidth,0)+(-1,0)$) rectangle+(2,-\paperheight);
	\fill[\cmdPAS@bg@bgcolor] (0,-.94\paperheight) rectangle+(\paperwidth,-.01);
}
\newcommand*\clearmargins@neptune{%
	\newgeometry{tmargin=2cm,bmargin=2cm,lmargin=1.5cm,rmargin=1.5cm}
}