From 6aa206aa3f06732b80b25fb9ffef20ae8bd6fe9a Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Wed, 8 Dec 2010 23:12:25 +0000 Subject: koma-moderncvclassic (8dec10) git-svn-id: svn://tug.org/texlive/trunk@20696 c570f23f-e606-0410-a88d-b1316a301751 --- .../koma-moderncvclassic/koma-moderncvclassic.sty | 48 ++++++++++++---------- 1 file changed, 27 insertions(+), 21 deletions(-) (limited to 'Master/texmf-dist/tex/latex/koma-moderncvclassic') diff --git a/Master/texmf-dist/tex/latex/koma-moderncvclassic/koma-moderncvclassic.sty b/Master/texmf-dist/tex/latex/koma-moderncvclassic/koma-moderncvclassic.sty index 7922c6138bc..db807cceb7d 100644 --- a/Master/texmf-dist/tex/latex/koma-moderncvclassic/koma-moderncvclassic.sty +++ b/Master/texmf-dist/tex/latex/koma-moderncvclassic/koma-moderncvclassic.sty @@ -1,5 +1,6 @@ %% start of file `koma-moderncvclassic.sty'. %% Copyright 2010 Salome Södergran (salome.soedergran@gmx.ch) +%% Thanks to Dominik Wassenhoven for helpful suggestions! %% %% Adaption of moderncv, theme classic %% (Copyright 2006-2008 Xavier Danaux (xdanaux@gmail.com)) @@ -13,7 +14,7 @@ % IDENTIFICATION % ============================== -\ProvidesPackage{koma-moderncvclassic}[2010/10/11 v0.1] +\ProvidesPackage{koma-moderncvclassic}[2010/12/03 v0.2] \NeedsTeXFormat{LaTeX2e} % ============================== @@ -186,21 +187,20 @@ marvosym% for symbols like \Telefon, \Letter, \Email \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} +% other lengths +\newlength{\photowidth} +\newcommand{\photo}[3][frame]{% + \newcommand{\pictureframe}{#1}% + \setlength{\photowidth}{#2}% + \newcommand{\photoname}{#3}} \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 + \addtolength{\maketitledetailswidth}{-\separatorcolumnwidth}% + \AtBeginDocument{% + \addtolength{\maketitledetailswidth}{-\photowidth}} \newif\if@firstdetailselement\@firstdetailselementtrue \newcommand*{\maketitledetailsnewline}{ @@ -212,15 +212,15 @@ marvosym% for symbols like \Telefon, \Letter, \Email \renewcommand*{\maketitle}{% % name and title \begin{minipage}[b]{\maketitlenamewidth}% - \firstnamestyle{%\@ -\firstname~}\familynamestyle{%\@ + \firstnamestyle{% +\firstname~}\familynamestyle{% \familyname}% - \ifthenelse{\equal{%\@ -\acadtitle}{}}{}{\\[1.25em]\acadtitlestyle{%\@ + \ifthenelse{\equal{% +\acadtitle}{}}{}{\\[1.25em]\acadtitlestyle{% \acadtitle}}% \end{minipage}% % optional data - \begin{minipage}[b]{\maketitledetailswidth}% +\begin{minipage}[b]{\maketitledetailswidth}% \raggedleft\addressfont\color{addresscolor}% \ifthenelse{\isundefined{\addressstreet}}{}{% \maketitledetailsnewline% @@ -232,12 +232,18 @@ marvosym% for symbols like \Telefon, \Letter, \Email \ifthenelse{\isundefined{\email}}{}{\maketitledetailsnewline\emailsymbol~\emaillink{\email}}% \ifthenelse{\isundefined{\extrainfo}}{}{\maketitledetailsnewline\extrainfo}% \end{minipage}% - % optional photo - \ifthenelse{\isundefined{\@photo}}% +% optional photo + \ifthenelse{\isundefined{\photoname}}% {}% -{\hspace*{\separatorcolumnwidth}\color{firstnamecolor}\framebox{\includegraphics[width=\maketitlepicturewidth]{\@photo}}}\\[3em]% - % optional quote - \ifthenelse{\isundefined{%\@ + {\hspace*{\separatorcolumnwidth}% + \ifthenelse{\equal{\pictureframe}{noframe}} + {\begin{minipage}[b]{\photowidth} + \includegraphics[width=\photowidth]{\photoname} + \end{minipage}} + {\color{firstnamecolor}% + \framebox{\includegraphics[width=\photowidth]{\photoname}}}} +% optional quote + \ifthenelse{\isundefined{% \quote}}% {}% {\centering{\begin{minipage}{\quotewidth}\centering\quotestyle{\quote}\end{minipage}}%\\[2.5em] -- cgit v1.2.3