summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/pas-cv/macro-venus.tex
blob: 95b858a04f2365c655775ff784fa1f41cf939a29 (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
86
87
88
89
90
91
92
93
\def\modele@venus{venus}
\def\cv@h@venus{4}

% =============== FOND ===============
\newcommand*\fond@venus{%
	% dégradé haut
	\fill[top color=\cmdPAS@bg@bgcolor,bottom color=white] (0,0) rectangle +(\paperwidth,-\cv@h@venus);
	% dégradé bas
	\fill[bottom color=\cmdPAS@bg@bgcolor,top color=white] (0,-\paperheight*.97) rectangle +(\paperwidth,-1);
	% Rayures haut
	\foreach \x in {0.4,0.8,...,23}
	{
		\draw[white,very thick] (\x,0) -- (\x-.5,-\cv@h@venus+1);
		\draw[white,very thick] (\x,-28) -- (\x+.5,-27);
	}
	\fill[left color=\cmdPAS@bg@bordercolor,right color=white] (0,-\cv@h@venus) rectangle +(\paperwidth,-.25);
	\fill[right color=\cmdPAS@bg@bgcolor,left color=white] (0,-\cv@h@venus-.25) rectangle +(\paperwidth,-1);
	\ifx\cmdPAS@bg@pic\@empty%
	\else
		\ifx\cmdPAS@bg@borderpic\@empty
			\node[above] (photo) at (2,-\cv@h@venus-1) {\includegraphics[scale=\cmdPAS@bg@scalepic]{\cmdPAS@bg@pic}};
		\else
			\node[above,draw=\cmdPAS@bg@borderpic,very thick,inner sep=1pt] at (2,-1-\cv@h@venus) {\includegraphics[scale=\cmdPAS@bg@scalepic]{\cmdPAS@bg@pic}};
		\fi
	\fi
	\node[color=\cmdPAS@bg@postecolor,left] at (.98\paperwidth,-.75-\cv@h@venus) {\scshape\cmdPAS@bg@postesize\bfseries\cmdPAS@bg@poste};
}

%=============== INFO GAUCHE ===============
\newcommand*\infoLeft@venus[1]{%
	\AddToShipoutPicture{%
		\ifx\cmdPAS@bg@pic\empty
			\put(\LenToUnit{1cm},\LenToUnit{.97\paperheight})
			{%
				\rlap{
					\begin{minipage}[t]{0.5\paperwidth}
						#1
					\end{minipage}
				}
			}
		\else
			\put(\LenToUnit{4.5cm},\LenToUnit{.97\paperheight})
			{%
				\rlap{
					\begin{minipage}[t]{0.5\paperwidth}
						#1
					\end{minipage}
				}
			}
		\fi
	}
}

%=============== INFO DROITE ===============
\newcommand*\infoRight@venus[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@venus[1]{%
	\noindent
	\begin{tikzpicture}
		\fill[\cmdPAS@title@color] (0,.1) rectangle+(.2,-.2);
		\draw[\cmdPAS@title@bordercolor,very thick] (.2,-.15) -- (-2,-.15);
		\node[right,text=\cmdPAS@title@color] at (.4,0) {\scshape\bfseries #1};
	\end{tikzpicture}
}

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

%=============== CLEARPAGE ===============
\newcommand*\clearpage@venus{%
	\fill[bottom color=\cmdPAS@bg@bgcolor,top color=white] (0,-\paperheight*.97) rectangle +(\paperwidth,-1);
	\foreach \x in {0.4,0.8,...,23}
	{
		\draw[white,very thick] (\x,-28) -- (\x+.5,-27);
	}
}
\newcommand*\clearmargins@venus{%
	\newgeometry{tmargin=2cm,bmargin=2cm,lmargin=1.5cm,rmargin=1.5cm}
}