summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/mycv/mycv_style.sty
blob: 26e4a1108708cf2d77ad804cb0bc0d178dbac8d9 (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
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
% -------------------------------------------------------
% Copyright 2012 Ghersi Andrea (ghanhawk@gmail.com).
% This work may be distributed and/or modified under the
% conditions of the LaTeX Project Public License version
% 1.3c, available at 'http://www.latex-project.org/lppl'.
% -------------------------------------------------------

\RequirePackage{svn-prov}
\input{mycv_version.def}

\ProvidesPackageSVN
   {$Id: mycv_style.sty 85 2012-05-12 17:07:42Z ghangenit $}
   [v\@versionstr][Default style file]

\RequirePackage{titlesec}  % for title format and spacing
\RequirePackage{fancyhdr}  % for custom headers and footers
\RequirePackage{xcolor}    % for colors
\RequirePackage{calligra}  % for the calligra font 
\RequirePackage{times}     % for times font
\RequirePackage{pifont}    % for the ’ding’ style (itemize environment)
\RequirePackage{marvosym}  % symbols - phone
\RequirePackage{amssymb}   % symbols - email
\RequirePackage{hyperref}  % for hypertext links and other stuff
\RequirePackage{xparse}    % for commands with multiple default arguments

%%%%%%%%%%%
%         %
% Layout  %
%         %
%%%%%%%%%%%

% -----------------------------------------------------
% passing the option 'showframe' to the package permits
% to see the page margins: that may be useful for debug
% -----------------------------------------------------
\RequirePackage[
   paperwidth=210mm,
   paperheight=297mm,
   textwidth=495pt,
   vmargin=1.5cm,
   columnsep=18pt
]{geometry}

%%%%%%%%%%%%%%%%%%%%%
%                   %
% Header and footer %
%                   %
%%%%%%%%%%%%%%%%%%%%%

\renewcommand{\headrulewidth}{0.0pt}

\fancyhf{}

\DeclareRobustCommand{\mycfoot}[1]{%
   \cfoot{\color{myheadingscolor}{{\sffamily\tiny{#1}}}}%
}

\pagestyle{fancy}

%%%%%%%%%%%%%%%%%%%%%%%%
%                      %
% Hyperref and colours %
%                      %
%%%%%%%%%%%%%%%%%%%%%%%%

% ------------------------------------------
% setup colours for links, text and headings
% ------------------------------------------
\definecolor{mylinkcolour}{HTML}{0000FF}     % {FF0080} %light purple link for the email
\definecolor{myshadecolor}{HTML}{F0F0F0}     % {E4E3E3}%{D4D7FE} %light blue shade
\definecolor{mytextcolor}{HTML}{2b2b2b}      % text is almost black
\definecolor{myheadingscolor}{HTML}{701112}  % dark red

% ----------------------
% setup hyperref package
% ----------------------
\hypersetup{%
   colorlinks,breaklinks,%
   urlcolor=mylinkcolour,%
   linkcolor=mylinkcolour,%
}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%                                  %
% Section title format and spacing %
%                                  %
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

\DeclareDocumentCommand{\mysectionTitleFormat}%
   {O{myheadingscolor} O{myheadingscolor}}%
{%
   \titleformat{\section}%
      {\bigskip\color{#1}\titlerule\scshape\Large\raggedright}%
      {}{0em}{}[\color{#2}\titlerule\medskip]
}

\DeclareDocumentCommand{\mysectionTitleSpacing}%
   {O{0pt} O{0pt} O{5pt}}%
{%
   \titlespacing{\section}{#1}{#2}{#3}%
}

\mysectionTitleFormat
\mysectionTitleSpacing

%%%%%%%%%%%%%%%%%%%
%                 %
% Customized list %
%                 %
%%%%%%%%%%%%%%%%%%%

\newenvironment{myitemize}%
   {\renewcommand{\labelitemi}{\ding{43}}\begin{itemize}}%
   {\end{itemize}}

%%%%%%%%%%%%%%%
%             %
% Other stuff %
%             %
%%%%%%%%%%%%%%%

% --------------------------------
% set text color for the whole doc
% --------------------------------
\color{mytextcolor}