summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/koma-moderncvclassic
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2010-10-24 23:33:47 +0000
committerKarl Berry <karl@freefriends.org>2010-10-24 23:33:47 +0000
commit919f85285a2f8bdf4ef6d7f5b49a4bc61d443a27 (patch)
treec24f3fbc8ffff9a0a1b429ec195bd1f76121ae71 /Master/texmf-dist/tex/latex/koma-moderncvclassic
parentd5a6a8d8af0b82fe3a52fa254c74de353c8d05d7 (diff)
new koma package koma-moderncvclassic (17oct10)
git-svn-id: svn://tug.org/texlive/trunk@20169 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/koma-moderncvclassic')
-rw-r--r--Master/texmf-dist/tex/latex/koma-moderncvclassic/koma-moderncvclassic.sty348
1 files changed, 348 insertions, 0 deletions
diff --git a/Master/texmf-dist/tex/latex/koma-moderncvclassic/koma-moderncvclassic.sty b/Master/texmf-dist/tex/latex/koma-moderncvclassic/koma-moderncvclassic.sty
new file mode 100644
index 00000000000..7922c6138bc
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/koma-moderncvclassic/koma-moderncvclassic.sty
@@ -0,0 +1,348 @@
+%% start of file `koma-moderncvclassic.sty'.
+%% Copyright 2010 Salome Södergran (salome.soedergran@gmx.ch)
+%%
+%% Adaption of moderncv, theme classic
+%% (Copyright 2006-2008 Xavier Danaux (xdanaux@gmail.com))
+%% for use with Komascript-classes.
+%
+% 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/.
+
+% ==============================
+% IDENTIFICATION
+% ==============================
+
+\ProvidesPackage{koma-moderncvclassic}[2010/10/11 v0.1]
+\NeedsTeXFormat{LaTeX2e}
+
+% ==============================
+% OPTIONS
+% ==============================
+\newcommand*{\mycolor}{}
+\DeclareOption{myblue}{\renewcommand*{\mycolor}{myblue}}
+\DeclareOption{blue}{\renewcommand*\mycolor{blue}}
+\DeclareOption{red}{\renewcommand*\mycolor{red}}
+\DeclareOption{green}{\renewcommand*\mycolor{green}}
+\DeclareOption{cyan}{\renewcommand*\mycolor{cyan}}
+\DeclareOption{magenta}{\renewcommand*\mycolor{magenta}}
+\DeclareOption{yellow}{\renewcommand*\mycolor{yellow}}
+\DeclareOption{black}{\renewcommand*\mycolor{black}}
+\DeclareOption{white}{\renewcommand*\mycolor{white}}
+\DeclareOption{gray}{\renewcommand*\mycolor{gray}}
+\DeclareOption{darkgray}{\renewcommand*\mycolor{darkgray}}
+\DeclareOption{lightgray}{\renewcommand*\mycolor{lightgray}}
+\ExecuteOptions{myblue} % execute default option
+\ProcessOptions\relax % execute given option
+
+% ==============================
+% PACKAGES
+% ==============================
+
+\RequirePackage{ifthen,%
+ifpdf,%
+xcolor,%
+lmodern,%
+marvosym% for symbols like \Telefon, \Letter, \Email
+}
+
+% % hyperrefs
+\RequirePackage{url}
+\ifpdf
+ \RequirePackage[pdftex,]{hyperref}
+\else
+ \RequirePackage[dvips]{hyperref}\fi
+\hypersetup{%
+ breaklinks,
+ baseurl = http://,%
+ pdfborder = 0 0 0,%
+ pdfpagemode = UseNone,%
+% pdfstartview = XYZ,%
+ pdfstartpage = 1,%
+ pdfcreator = \LaTeX{},%
+ pdfproducer = \LaTeX}
+\AtEndOfClass{%
+ \AtBeginDocument{%
+ \hypersetup{%
+ pdfauthor = \firstname~\familyname,%
+ pdftitle = \title~\firstname~\familyname,%
+% pdfsubject = %\firstname~\familyname,%
+ pdfkeywords = \firstname~\familyname{} curriculum vit\ae{}}}}
+\urlstyle{tt}
+
+% graphics
+\ifpdf
+ \RequirePackage[pdftex]{graphicx}
+\else
+ \RequirePackage[dvips]{graphicx}\fi
+
+% ==============================
+% DEFINITIONS
+% ==============================
+
+% SYMBOLS
+\newcommand*{\listitemsymbol}{\textbullet}
+\newcommand*{\addresssymbol}{}
+\newcommand*{\mobilesymbol}{\Mobilefone}
+\newcommand*{\phonesymbol}{\Telefon}
+\newcommand*{\faxsymbol}{\FAX}
+\newcommand*{\emailsymbol}{\Letter}
+
+% COLORS
+\xdefinecolor{myblue}{rgb}{0.2,0.3,0.65}
+% already predefined in xcolor:
+% red, green, blue, cyan, magenta, yellow, black, white, darkgray, gray, lightgray
+\colorlet{colortheme}{\mycolor}% color for mycolor is given in preamble as package option
+\colorlet{firstnamecolor}{black}
+\colorlet{familynamecolor}{firstnamecolor}
+\colorlet{acadtitlecolor}{firstnamecolor}
+\colorlet{addresscolor}{firstnamecolor}
+\colorlet{quotecolor}{firstnamecolor}
+\colorlet{sectionrectanglecolor}{colortheme}
+\colorlet{sectiontitlecolor}{colortheme}
+\colorlet{subsectiontitlecolor}{colortheme}
+\colorlet{hintcolor}{black}
+
+% FONTS
+\renewcommand*{\ttdefault}{pcr}
+\newcommand*{\firstnamefont}{\fontsize{34}{36}\sffamily\mdseries\upshape}
+\newcommand*{\familynamefont}{\firstnamefont}
+\newcommand*{\acadtitlefont}{\LARGE\sffamily\mdseries\slshape}
+\newcommand*{\addressfont}{\normalsize\rmfamily\mdseries\slshape}
+\newcommand*{\quotefont}{\large\slshape}
+\newcommand*{\hintfont}{\small\sffamily}
+\setkomafont{section}{\Large\sffamily\mdseries\upshape}
+\setkomafont{subsection}{\large\sffamily\mdseries\upshape}
+
+% LENGTHS
+\setlength\lineskip{1\p@}
+\setlength\normallineskip{1\p@}
+\renewcommand\baselinestretch{}
+\setlength{\parindent}{0pt}
+\setlength{\parskip}{0pt}
+\setlength\columnsep{10\p@}
+\setlength\columnseprule{0\p@}
+%
+% hintscolumnwidth
+\newlength{\hintscolumnwidth}
+%\setlength{\hintscolumnwidth}{0.15\textwidth}
+\setlength{\hintscolumnwidth}{2,79cm}
+% separatorcolumnwidth
+\newlength{\separatorcolumnwidth}
+\setlength{\separatorcolumnwidth}{0.025\textwidth}
+% maincolumnwidth
+\newlength{\maincolumnwidth}
+ \setlength{\maincolumnwidth}{\textwidth}%
+ \addtolength{\maincolumnwidth}{-\separatorcolumnwidth}%
+ \addtolength{\maincolumnwidth}{-\hintscolumnwidth}%
+% quotewidth
+\newlength{\quotewidth}
+% doubleitem lengths
+\newlength{\doubleitemmaincolumnwidth}
+ \setlength{\doubleitemmaincolumnwidth}{\maincolumnwidth}%
+ \addtolength{\doubleitemmaincolumnwidth}{-\hintscolumnwidth}%
+ \addtolength{\doubleitemmaincolumnwidth}{-\separatorcolumnwidth}%
+ \setlength{\doubleitemmaincolumnwidth}{0.5\doubleitemmaincolumnwidth}%
+% listitem lengths
+\newlength{\listitemsymbolwidth}
+\settowidth{\listitemsymbolwidth}{\listitemsymbol{}~}
+\newlength{\listitemmaincolumnwidth}
+ \setlength{\listitemmaincolumnwidth}{\maincolumnwidth}%
+ \addtolength{\listitemmaincolumnwidth}{-\listitemsymbolwidth}%
+% listdoubleitem lengths
+\newlength{\listdoubleitemmaincolumnwidth}
+ \setlength{\listdoubleitemmaincolumnwidth}{\maincolumnwidth}%
+ \addtolength{\listdoubleitemmaincolumnwidth}{-\listitemsymbolwidth}%
+ \setlength{\listdoubleitemmaincolumnwidth}{0.475\listdoubleitemmaincolumnwidth}%
+\newlength{\cvcompcolumnwidth}
+ \setlength{\cvcompcolumnwidth}{\textwidth}
+ \addtolength{\cvcompcolumnwidth}{-3\separatorcolumnwidth}
+ \addtolength{\cvcompcolumnwidth}{-2\hintscolumnwidth}
+ \setlength{\cvcompcolumnwidth}{.5\cvcompcolumnwidth}
+
+% ==============================
+% STYLES
+% ==============================
+
+\newcommand*{\firstnamestyle}[1]{{\firstnamefont\color{firstnamecolor}#1}}
+\newcommand*{\familynamestyle}[1]{{\familynamefont\color{familynamecolor}#1}}
+\newcommand*{\acadtitlestyle}[1]{{\acadtitlefont\color{acadtitlecolor}#1}}
+\newcommand*{\addresstyle}[1]{{\addressfont\color{addresscolor}#1}}
+\newcommand*{\quotestyle}[1]{{\quotefont\color{quotecolor}#1}}
+\newcommand*{\sectionstyle}[1]{\usekomafont{section}\color{sectiontitlecolor}#1}\newcommand*{\subsectionstyle}[1]{\usekomafont{subsection}\color{subsectiontitlecolor}#1}
+\newcommand*{\hintstyle}[1]{{\hintfont\color{hintcolor}#1}}
+
+% ==============================
+% TITLE
+% ==============================
+
+% \title{}% to avoid LaTeX complaining that \maketitle is a called without first a call to \title
+\renewcommand*{\maketitle}{}%
+
+% setmaketitlenamemaxwidth to the full name length, capped by \maketitlenamemaxwidth
+\newlength{\maketitlenamemaxwidth}
+\setlength{\maketitlenamemaxwidth}{.525\textwidth}
+\newlength{\maketitlenamefullwidth}
+\settowidth{\maketitlenamefullwidth}{\firstnamestyle{\firstname~}\familynamestyle{\familyname}}
+\newlength{\maketitlenamewidth}
+\ifnum\maketitlenamemaxwidth<\maketitlenamefullwidth\setlength{\maketitlenamewidth}{\maketitlenamemaxwidth}\else\setlength{\maketitlenamewidth}{\maketitlenamefullwidth}\fi
+% other lengths
+
+\def\@photowidth{0pt}
+\newcommand*{\photo}[2][64pt]{\def\@photowidth{#1}\def\@photo{#2}}
+\newlength{\maketitlepicturewidth}
+\setlength{\maketitlepicturewidth}{\@photowidth}
+
+\newlength{\maketitledetailswidth}
+% % recompute theme-specific lengths, called by class to recompute all lengths
+% \renewcommand*{\recomputethemelengths}{%
+ \setlength{\maketitledetailswidth}{\textwidth}%
+ \addtolength{\maketitledetailswidth}{-\maketitlenamewidth}%
+ \addtolength{\maketitledetailswidth}{-\separatorcolumnwidth}%
+ \addtolength{\maketitledetailswidth}{-\maketitlepicturewidth}
+% \recomputethemelengths
+
+\newif\if@firstdetailselement\@firstdetailselementtrue
+\newcommand*{\maketitledetailsnewline}{
+ \if@firstdetailselement%
+ \@firstdetailselementfalse%
+ \else%
+ \\[.2em]\fi}
+
+\renewcommand*{\maketitle}{%
+ % name and title
+ \begin{minipage}[b]{\maketitlenamewidth}%
+ \firstnamestyle{%\@
+\firstname~}\familynamestyle{%\@
+\familyname}%
+ \ifthenelse{\equal{%\@
+\acadtitle}{}}{}{\\[1.25em]\acadtitlestyle{%\@
+\acadtitle}}%
+ \end{minipage}%
+ % optional data
+ \begin{minipage}[b]{\maketitledetailswidth}%
+ \raggedleft\addressfont\color{addresscolor}%
+ \ifthenelse{\isundefined{\addressstreet}}{}{%
+ \maketitledetailsnewline%
+ \addresssymbol~\addressstreet%
+ \ifthenelse{\isundefined{\addresscity}}{}{\\\addresscity}}%
+ \ifthenelse{\isundefined{\mobile}}{}{\maketitledetailsnewline\mobilesymbol~\mobile}%
+ \ifthenelse{\isundefined{\phone}}{}{\maketitledetailsnewline\phonesymbol~\phone}%
+ \ifthenelse{\isundefined{\faxnr}}{}{\maketitledetailsnewline\faxsymbol~\faxnr}%
+ \ifthenelse{\isundefined{\email}}{}{\maketitledetailsnewline\emailsymbol~\emaillink{\email}}%
+ \ifthenelse{\isundefined{\extrainfo}}{}{\maketitledetailsnewline\extrainfo}%
+ \end{minipage}%
+ % optional photo
+ \ifthenelse{\isundefined{\@photo}}%
+ {}%
+{\hspace*{\separatorcolumnwidth}\color{firstnamecolor}\framebox{\includegraphics[width=\maketitlepicturewidth]{\@photo}}}\\[3em]%
+ % optional quote
+ \ifthenelse{\isundefined{%\@
+\quote}}%
+ {}%
+ {\centering{\begin{minipage}{\quotewidth}\centering\quotestyle{\quote}\end{minipage}}%\\[2.5em]
+}%
+}
+
+% ==============================
+% SECTIONS & ELEMENTS
+% ==============================
+
+% SECTIONS
+
+\renewcommand*{\section}[1]{%
+ \vspace*{3.5ex \@plus 1ex \@minus .2ex}%
+ \phantomsection{}% reset the anchor for hyperrefs
+ \addcontentsline{toc}{part}{#1}%
+\parbox[m]{\hintscolumnwidth}{\raggedleft\hintfont{\color{sectionrectanglecolor}\rule{\hintscolumnwidth}{1ex}}}%
+ \hspace{\separatorcolumnwidth}%
+ \parbox[m]{\maincolumnwidth}{\sectionstyle{#1}}\\[1ex]}
+
+% usage: \subsection{title}
+\renewcommand*{\subsection}[1]{%
+ \cvline[0.45em]{}{\subsectionstyle{#1}}\vspace{0.5ex}}
+
+% ELEMENTS
+
+% draws a colored rectangle
+% usage: \colorrule[optional height]{width}
+%\newcommand*{\colorrule}[2][1ex]{{\color{sectionrectanglecolor}{\rule{#2}{#1}}}}
+
+% usage: \cvline{margintext}{linetext}
+% aus moderncv.cls-Datei
+\newcommand*{\cvline}[3][.25em]{%
+\begin{tabular}{@{}p{\hintscolumnwidth}@{\hspace{\separatorcolumnwidth}}p{\maincolumnwidth}@{}}%
+ \raggedleft\hintfont{#2} &{#3}%
+ \end{tabular}\\[#1]}
+% aus modercvclassic.sty-Datei:
+% \cvline[1ex]{\color{sectionrectanglecolor}\rule[0]{\hintscolumnwidth}{1ex}}{\sectionstyle{#1}}}% gives bad alignment of rectangle; too bad m{width} columns seem not to work as a valid column definition for tabular environments
+
+% % usage: \cvlistdoubleitem[symbol]{point1}{point2}
+% \newcommand*{\cvlistdoubleitem}[3][\listitemsymbol{}]{%
+% \cvline[0pt]{}{#1~\begin{minipage}[t]{\listdoubleitemmaincolumnwidth}#2\end{minipage}%
+% \hfill%
+% \ifthenelse{\equal{#3}{}}%
+% {}%
+% {#1~\begin{minipage}[t]{\listdoubleitemmaincolumnwidth}#3\end{minipage}}}}
+
+% usage: \cvlistdoubleitem[symbol]{point1}{point2}
+\newcommand*{\cvlistdoubleitem}[3][\listitemsymbol{}]{%
+\cvline[0pt]{}{#1~\begin{minipage}[t]{\listdoubleitemmaincolumnwidth}#2\end{minipage}%
+ \hfill%
+ \ifthenelse{\equal{#3}{}}%
+ {}%
+ {#1~\begin{minipage}[t]{\listdoubleitemmaincolumnwidth}#3\end{minipage}}}}
+
+% usage: \cventry{years}{degree/job title}{institution/employer}{localization}{optionnal: grade/...}{optional: comment/job description}
+\newcommand*{\cventry}[6]{%
+ \cvline{#1}{%
+ {\bfseries#2}%
+ \ifx#3\else{, {\slshape#3}}\fi%
+ \ifx#4\else{, #4}\fi%
+ \ifx#5\else{, #5}\fi%
+ .%
+ \ifx#6\else{\newline{}\begin{minipage}[t]{\linewidth}\small#6\end{minipage}}\fi
+ }}%
+
+% usage (inside 'language' cvsection environment): \cvlanguage{name}{level}{comment}
+\newcommand*{\cvlanguage}[3]{%
+ \cvline{#1}{\begin{minipage}[t]{.225\maincolumnwidth}\textbf{#2}\end{minipage}\hfill\begin{minipage}[t]{0.725\maincolumnwidth}\raggedleft\footnotesize\itshape #3\end{minipage}}}
+
+% usage (inside 'computer skills' cvsection environment): \cvcomputer{category}{programs}{category}{programs}
+\newcommand*{\cvcomputer}[4]{%
+% \cvlistdoubleitem{#1}{\small#2}{#3}{\small#4}}
+% = ursrüngliche Definition in moderncv; ergibt hier merkwürdige Resultat;
+% deshalb Neuansatz:
+\begin{tabular*}{\textwidth}[t]{@{}p{\hintscolumnwidth}@{\hspace{\separatorcolumnwidth}}p{\cvcompcolumnwidth}@{\hspace{\separatorcolumnwidth}}p{\hintscolumnwidth}@{\hspace{\separatorcolumnwidth}}p{\cvcompcolumnwidth}
+}
+\raggedleft{#1} &\raggedright{#2} &\raggedleft{#3} &\raggedright{#4}
+\end{tabular*}}
+
+% usage: \link[optional text]{link}
+\newcommand*{\link}[2][]{%
+ \ifthenelse{\equal{#1}{}}%
+ {\href{#2}{#2}}%
+ {\href{#2}{#1}}}
+
+% usage: \httplink[optional text]{link}
+\newcommand*{\httplink}[2][]{%
+ \ifthenelse{\equal{#1}{}}%
+ {\href{http://#2}{#2}}%
+ {\href{http://#2}{#1}}}
+
+% usage: \emaillink[optional text]{link}
+\newcommand*{\emaillink}[2][]{%
+ \ifthenelse{\equal{#1}{}}%
+ {\href{mailto:#2}{#2}}%
+ {\href{mailto:#2}{#1}}}
+
+% ==============================
+% VARIA
+% ==============================
+
+\raggedbottom
+\onecolumn
+
+\endinput
+
+%% end of file `koma-moderncvclassic.sty'. \ No newline at end of file