[222] | 1 | %% start of file `moderncvthemeclassic.sty'.
|
---|
| 2 | %% Copyright 2006-2010 Xavier Danaux (xdanaux@gmail.com).
|
---|
| 3 | %
|
---|
| 4 | % This work may be distributed and/or modified under the
|
---|
| 5 | % conditions of the LaTeX Project Public License version 1.3c,
|
---|
| 6 | % available at http://www.latex-project.org/lppl/.
|
---|
| 7 |
|
---|
| 8 |
|
---|
| 9 | %-------------------------------------------------------------------------------
|
---|
| 10 | % identification
|
---|
| 11 | %-------------------------------------------------------------------------------
|
---|
| 12 | \NeedsTeXFormat{LaTeX2e}
|
---|
| 13 | \ProvidesPackage{moderncvthemeclassic}[2010/08/03 v0.12 modern curriculum vitae style: classic]
|
---|
| 14 |
|
---|
| 15 |
|
---|
| 16 | %-------------------------------------------------------------------------------
|
---|
| 17 | % required packages
|
---|
| 18 | %-------------------------------------------------------------------------------
|
---|
| 19 |
|
---|
| 20 |
|
---|
| 21 | %-------------------------------------------------------------------------------
|
---|
| 22 | % package options
|
---|
| 23 | %-------------------------------------------------------------------------------
|
---|
| 24 | % color options
|
---|
| 25 | % blue (default option)
|
---|
| 26 | \DeclareOption{blue}{}
|
---|
| 27 | % orange
|
---|
| 28 | \newif\if@colororange\@colororangefalse
|
---|
| 29 | \DeclareOption{orange}{\@colororangetrue}
|
---|
| 30 | % green
|
---|
| 31 | \newif\if@colorgreen\@colorgreenfalse
|
---|
| 32 | \DeclareOption{green}{\@colorgreentrue}
|
---|
| 33 | % red
|
---|
| 34 | \newif\if@colorred\@colorredfalse
|
---|
| 35 | \DeclareOption{red}{\@colorredtrue}
|
---|
| 36 | % grey
|
---|
| 37 | \newif\if@colorgrey\@colorgreyfalse
|
---|
| 38 | \DeclareOption{grey}{\@colorgreytrue}
|
---|
| 39 |
|
---|
| 40 | % roman option
|
---|
| 41 | \newif\if@roman\@romanfalse
|
---|
| 42 | \DeclareOption{roman}{\@romantrue}
|
---|
| 43 |
|
---|
| 44 | % unused options
|
---|
| 45 | \DeclareOption*{
|
---|
| 46 | \PackageWarning{moderncvthemeclassic}{Unknown option â\CurrentOptionâ}}
|
---|
| 47 |
|
---|
| 48 | % execute default options
|
---|
| 49 | \ExecuteOptions{color}
|
---|
| 50 |
|
---|
| 51 | % process given options
|
---|
| 52 | \ProcessOptions\relax
|
---|
| 53 |
|
---|
| 54 |
|
---|
| 55 | %-------------------------------------------------------------------------------
|
---|
| 56 | % style definition
|
---|
| 57 | %-------------------------------------------------------------------------------
|
---|
| 58 | % symbols used
|
---|
| 59 |
|
---|
| 60 | % colors
|
---|
| 61 | \definecolor{firstnamecolor}{rgb}{0,0,0}
|
---|
| 62 | \definecolor{familynamecolor}{rgb}{0,0,0}
|
---|
| 63 | \definecolor{titlecolor}{rgb}{0.35,0.35,0.35}
|
---|
| 64 | \definecolor{quotecolor}{rgb}{0.35,0.35,0.35}
|
---|
| 65 | % default blue color
|
---|
| 66 | \definecolor{addresscolor}{rgb}{0.25,0.5,0.75}
|
---|
| 67 | \definecolor{sectionrectanglecolor}{rgb}{0.25,0.5,0.75}
|
---|
| 68 | \definecolor{sectiontitlecolor}{rgb}{0.2,0.4,0.65}
|
---|
| 69 | \definecolor{subsectioncolor}{rgb}{0.2,0.4,0.65}
|
---|
| 70 | \if@colororange
|
---|
| 71 | \definecolor{addresscolor}{rgb}{0.95,0.55,0.15}
|
---|
| 72 | \definecolor{sectionrectanglecolor}{rgb}{1,0.65,0.20}
|
---|
| 73 | \definecolor{sectiontitlecolor}{rgb}{0.95,0.55,0.15}
|
---|
| 74 | \definecolor{subsectioncolor}{rgb}{0.95,0.55,0.15}\fi
|
---|
| 75 | \if@colorgreen
|
---|
| 76 | \definecolor{addresscolor}{rgb}{0.30,0.65,0.15}
|
---|
| 77 | \definecolor{sectionrectanglecolor}{rgb}{0.55,0.85,0.35}
|
---|
| 78 | \definecolor{sectiontitlecolor}{rgb}{0.30,0.65,0.15}
|
---|
| 79 | \definecolor{subsectioncolor}{rgb}{0.30,0.65,0.15}\fi
|
---|
| 80 | \if@colorred
|
---|
| 81 | \definecolor{addresscolor}{rgb}{0.95,0.20,0.20}
|
---|
| 82 | \definecolor{sectionrectanglecolor}{rgb}{1.00,0.30,0.30}
|
---|
| 83 | \definecolor{sectiontitlecolor}{rgb}{0.95,0.20,0.20}
|
---|
| 84 | \definecolor{subsectioncolor}{rgb}{0.95,0.20,0.20}\fi
|
---|
| 85 | \if@colorgrey
|
---|
| 86 | \definecolor{addresscolor}{rgb}{0.35,0.35,0.35}
|
---|
| 87 | \definecolor{sectionrectanglecolor}{rgb}{0.75,0.75,0.75}
|
---|
| 88 | \definecolor{sectiontitlecolor}{rgb}{0.35,0.35,0.35}
|
---|
| 89 | \definecolor{subsectioncolor}{rgb}{0.35,0.35,0.35}\fi
|
---|
| 90 |
|
---|
| 91 | % fonts
|
---|
| 92 | \if@roman
|
---|
| 93 | \AtBeginDocument{\rmfamily}
|
---|
| 94 | \else
|
---|
| 95 | \AtBeginDocument{\sffamily}\fi
|
---|
| 96 | \renewcommand*{\ttdefault}{pcr}
|
---|
| 97 | \renewcommand*{\firstnamefont}{\fontsize{34}{36}\sffamily\mdseries\upshape}
|
---|
| 98 | \renewcommand*{\titlefont}{\LARGE\sffamily\mdseries\slshape}
|
---|
| 99 | \renewcommand*{\addressfont}{\normalsize\rmfamily\mdseries\slshape}
|
---|
| 100 | \renewcommand*{\familynamefont}{\firstnamefont}
|
---|
| 101 | \renewcommand*{\quotefont}{\large\slshape}
|
---|
| 102 | \renewcommand*{\sectionfont}{\Large\sffamily\mdseries\upshape}
|
---|
| 103 | \renewcommand*{\subsectionfont}{\large\sffamily\mdseries\upshape}
|
---|
| 104 |
|
---|
| 105 | % styles
|
---|
| 106 |
|
---|
| 107 | % maketitle
|
---|
| 108 | % setmaketitlenamemaxwidth to the full name length, capped by \maketitlenamemaxwidth
|
---|
| 109 | \newlength{\maketitlenamemaxwidth}
|
---|
| 110 | \setlength{\maketitlenamemaxwidth}{.525\textwidth}
|
---|
| 111 | \newlength{\maketitlenamefullwidth}
|
---|
| 112 | \settowidth{\maketitlenamefullwidth}{\firstnamestyle{\@firstname~}\familynamestyle{\@familyname}}
|
---|
| 113 | \newlength{\maketitlenamewidth}
|
---|
| 114 | \ifnum\maketitlenamemaxwidth<\maketitlenamefullwidth\setlength{\maketitlenamewidth}{\maketitlenamemaxwidth}\else\setlength{\maketitlenamewidth}{\maketitlenamefullwidth}\fi
|
---|
| 115 | % other lengths
|
---|
| 116 | \newlength{\maketitlepicturewidth}
|
---|
| 117 | \setlength{\maketitlepicturewidth}{\@photowidth}
|
---|
| 118 | \newlength{\maketitledetailswidth}
|
---|
| 119 | % recompute theme-specific lengths, called by class to recompute all lengths
|
---|
| 120 | \renewcommand*{\recomputethemelengths}{%
|
---|
| 121 | \setlength{\maketitledetailswidth}{\textwidth}%
|
---|
| 122 | \addtolength{\maketitledetailswidth}{-\maketitlenamewidth}%
|
---|
| 123 | \ifthenelse{\lengthtest{\maketitlepicturewidth=0pt}}%
|
---|
| 124 | {}%
|
---|
| 125 | {\addtolength{\maketitledetailswidth}{-\separatorcolumnwidth}%
|
---|
| 126 | \addtolength{\maketitledetailswidth}{-\maketitlepicturewidth}}}
|
---|
| 127 | \recomputethemelengths
|
---|
| 128 | \newif\if@firstdetailselement\@firstdetailselementtrue
|
---|
| 129 | \newcommand*{\maketitledetailsnewline}{
|
---|
| 130 | \if@firstdetailselement%
|
---|
| 131 | \@firstdetailselementfalse%
|
---|
| 132 | \else%
|
---|
| 133 | \\[.2em]\fi}
|
---|
| 134 | \renewcommand*{\maketitle}{%
|
---|
| 135 | % name and title
|
---|
| 136 | \begin{minipage}[b]{\maketitlenamewidth}%
|
---|
| 137 | \firstnamestyle{\@firstname~}\familynamestyle{\@familyname}%
|
---|
| 138 | \ifthenelse{\equal{\@title}{}}{}{\\[1.25em]\titlestyle{\@title}}%
|
---|
| 139 | \end{minipage}%
|
---|
| 140 | % optional data
|
---|
| 141 | \begin{minipage}[b]{\maketitledetailswidth}%
|
---|
| 142 | \raggedleft\addressfont\color{addresscolor}%
|
---|
| 143 | \ifthenelse{\isundefined{\@addressstreet}}{}{%
|
---|
| 144 | \maketitledetailsnewline%
|
---|
| 145 | \addresssymbol~\@addressstreet%
|
---|
| 146 | \ifthenelse{\isundefined{\@addresscity}}{}{\\\@addresscity}}%
|
---|
| 147 | \ifthenelse{\isundefined{\@mobile}}{}{\maketitledetailsnewline\mobilesymbol~\@mobile}%
|
---|
| 148 | \ifthenelse{\isundefined{\@phone}}{}{\maketitledetailsnewline\phonesymbol~\@phone}%
|
---|
| 149 | \ifthenelse{\isundefined{\@fax}}{}{\maketitledetailsnewline\faxsymbol~\@fax}%
|
---|
| 150 | \ifthenelse{\isundefined{\@email}}{}{\maketitledetailsnewline\emailsymbol~\emaillink{\@email}}%
|
---|
| 151 | \ifthenelse{\isundefined{\@homepage}}{}{\maketitledetailsnewline\homepagesymbol~\httplink{\@homepage}}%
|
---|
| 152 | \ifthenelse{\isundefined{\@extrainfo}}{}{\maketitledetailsnewline\@extrainfo}%
|
---|
| 153 | \end{minipage}%
|
---|
| 154 | % optional photo
|
---|
| 155 | \ifthenelse{\isundefined{\@photo}}%
|
---|
| 156 | {}%
|
---|
| 157 | {%
|
---|
| 158 | \hspace*{\separatorcolumnwidth}%
|
---|
| 159 | \begin{minipage}[b]{\maketitlepicturewidth}%
|
---|
| 160 | \raggedleft{}\addressfont\color{addresscolor}% required to correctly align content
|
---|
| 161 | \framebox{\includegraphics[width=\maketitlepicturewidth]{\@photo}}%
|
---|
| 162 | \end{minipage}}\\[3em]%
|
---|
| 163 | % optional quote
|
---|
| 164 | \ifthenelse{\isundefined{\@quote}}%
|
---|
| 165 | {}%
|
---|
| 166 | {{\centering{}\begin{minipage}{\quotewidth}\centering\quotestyle{\@quote}\end{minipage}\\[2.5em]}}%
|
---|
| 167 | }
|
---|
| 168 |
|
---|
| 169 |
|
---|
| 170 | \endinput
|
---|
| 171 |
|
---|
| 172 |
|
---|
| 173 | %% end of file `moderncvthemeclassic.sty'.
|
---|