%\iffalse
% ecv.dtx generated using makedtx version 0.91b (c) Nicola Talbot
% Command line args:
%   -macrocode ".*"
%   -src "(ecv.cls|ecvNLS.sty|ecvGerman.ldf|ecvEnglish.ldf)=>\1"
%   -author "Christoph P. Neumann & Bernd Haberstumpf"
%   -dir "src"
%   -usedir "tex/latex/ecv"
%   -setambles ".*=>\nopreamble"
%   -doc "doc/ecv.tex"
%   -silent "1"
%   ecv
% Created on 2011/4/23 10:03
%\fi
%\iffalse
%<*package>
%% \CharacterTable
%%  {Upper-case    \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
%%   Lower-case    \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
%%   Digits        \0\1\2\3\4\5\6\7\8\9
%%   Exclamation   \!     Double quote  \"     Hash (number) \#
%%   Dollar        \$     Percent       \%     Ampersand     \&
%%   Acute accent  \'     Left paren    \(     Right paren   \)
%%   Asterisk      \*     Plus          \+     Comma         \,
%%   Minus         \-     Point         \.     Solidus       \/
%%   Colon         \:     Semicolon     \;     Less than     \<
%%   Equals        \=     Greater than  \>     Question mark \?
%%   Commercial at \@     Left bracket  \[     Backslash     \\
%%   Right bracket \]     Circumflex    \^     Underscore    \_
%%   Grave accent  \`     Left brace    \{     Vertical bar  \|
%%   Right brace   \}     Tilde         \~}
%</package>
%\fi
% \iffalse
% Doc-Source file to use with LaTeX2e
% Copyright (C) 2011 Christoph P. Neumann & Bernd Haberstumpf, all rights reserved.
% \fi
% \iffalse
%<*driver>
%%
%% Copyright 2007-2011 Christoph P. Neumann, Bernd Haberstumpf
%%
%% This LaTeX class provides a simple interface for creating
%% a verfy fancy Curriculum Vitae. At the moment only CVs in
%% the german language are supported.
%%
%% This file is free property; as a special exception the author
%% gives unlimited permission to copy and/or distribute it, with
%% or without modifications, as long as this notice is 
%% preserved.
%%
%% This file is distributed in the hope that it will be useful, 
%% but WITHOUT ANY WARRANTY, to the extent permitted by law; 
%% without even the implied warranty of MERCHANTABILITY or 
%% FITNESS FOR A PARTICULAR PURPOSE.
%%

\documentclass{ltxdoc} 

\CodelineNumbered
\EnableCrossrefs 
%\DisableCrossrefs
\CodelineIndex 
%\PageIndex
\RecordChanges
%\OnlyDescription
\GetFileInfo{ecv.cls}

\parskip1.0ex
\parindent0.0ex

\begin{document} 
\DocInput{ecv.dtx}
\end{document}
%</driver>
%\fi
%
%\title{\textsf{ecv}\\
%A fancy Curriculum Vitae Class} 
%\author{Christoph P.\ Neumann \texttt{$<$c.p.neumann@web.de$>$}, \\
%Bernd Haberstumpf \texttt{$<$poldi@kabatrinker.de$>$}} 
%\maketitle 
%\PrintChanges
%
%\begin{abstract}
%The \texttt{ecv}--class provides a convenient environment for creating
%a fancy tabular currriculum vitae. The class is oriented at the europass
%(see: \texttt{http://europass.cedefop.eu.int}).
%\end{abstract}
%
%\section{Installation}
%
%The \texttt{zip} or \texttt{tar.gz} file comes with a \texttt{ecv.ins}
%and a \texttt{ecv.dtx} file included which contains the \LaTeX\ stuff.
%
%To extract the class files call:
%
%\begin{verbatim}
%  $ latex ecv.ins
%\end{verbatim}
%
%This call will extract all \LaTeX\ specific files to the current
%directory. You can either use the files for a single 
%cv project or you can integrate the files into your \TeX\ installation.
%
%If you just want to use \textsf{ecv} for a single curriculum vitae
%project, the simplest way is just to copy the generated files to the
%folder of the project.
%
%If you want to integrate \textsf{ecv} into  your \TeX\ installation,
%create a directory \texttt{tex/latex/ecv} beneath your \TeX\ installation
%(e.g.~beneath \texttt{/usr/share/texmf}) and copy all files from the
%current directory there. Now call:
%
%\begin{verbatim}
%  $ mktexlsr
%\end{verbatim}
%
%to update the file--cache of \LaTeX.
%
%Hint: The \textsf{ecv} distribution contains a sample docstrip configuration
%in \texttt{docstrip.cfg} via which files can be distributed
%automatically to their correct positions inside a \LaTeX\ installation.
%Feel free to adapt this file to your environment and afterwards call
%\texttt{latex ecv.ins} to install the package to its right place.
%
%\section{Linux and Windows}
%
%\textsf{Ecv} has been tested on Linux and also under Windows, using
%MiXTeX and TeXnicCenter.
%
%\section{Templates}
%
%For a quick start the \textsf{ecv} distribution contains document
%templates for a german and an english curriculum vitae. The templates
%can be found in the \texttt{template.zip} file.
%
%The \texttt{template} directory contains the templates
%
%\begin{itemize}
%\item \texttt{CV-template\_de.tex} for the german language
%\item \texttt{CV-template\_en.tex} for the english language
%\end{itemize}
%
%and a \texttt{Makefile} to build the pdf. Just call:
%
%\begin{verbatim}
%  $ make
%\end{verbatim}
%
%to build the pdf. The file \texttt{porttrait.eps} contains a dummy
%porttrait for the first page of the curriculum vitae.
%
%\section{Structure}
%
%The tex--file that contains the curriculum vitae will have roughly
%the following structure:
%
%\begin{verbatim}
%\% The languages english and german are supported
%\documentclass[german]{ecv}
%
%\% Portrait to be used on the first page
%\ecvPortrait{images/myPortrait}
%
%\% Name to be use for the footer line
%\ecvName{My Name}
%
%\begin{document}
%
%\% Start the tabular that contains the cv (this will print title 
%\% and portrait)
%\begin{ecv}
%
%\% Group entries with sections
%\ecvSec{\ecvPerson}
%
%\% Entries in the tabular
%\ecvEPR{Name}   {\textsc{Name}, My}
%\ecvEPR{Adresse}{Somewhere 13, Sometown}
%\ecvEPR{Telefon}{(555) 555 / 555}
%\ecvEPR{E-Mail} {\ecvHyperEMail{nobody@nowhere.com}}
%\ecvEPR{Staatsangeh"origkeit}
%                {Deutsch}
%\ecvEPR{Geburtsdatum}
%                {12.34.5678}
%\end{ecv}
%
%\ecvSig{Name, My}{Sometown}
%
%\end{verbatim}
%
%The example shows that some information is provided before the document
%start like the name for the footer line and the portrait. The actual
%cv is then written in the |ecv| environment. A curriculum vitae can be finialized with
%a signature where the issuer can sign by hand.
%
%\section{NLS support}
%
%As the example in the last chapter suggests curriculum vitaes can be
%written in either german or english language. Actually a curriculum
%vitae--tex--file can contain both a german version and an english version.
%Most commands of the class accept an optional parameter which defines
%to which language the command applies. If the language does not match
%the language define in the \texttt{documentclass} the command is ignored.
%
%Example:
%
%\begin{verbatim}
%\ecvERP[german]{Staatsangeh"origkeit}{Deutsch}
%\ecvERP[english]{nationality}{german}
%\end{verbatim}
%
%If the document is rendered with |\documentclass[german]{ecv}| the first
%line is used, if the document is rendered with |\documentclass[english]{ecv}|
%the second line is printed.
%
%The class also provides with its package |ecvNLS.sty| some macros for
%nationalized text--fragments like |ecvPerson| which prints |Zur Person|
%in the german version and |Personal Information| in the english version.
%
%\section{Documentclass}
%
%\DescribeMacro{documentclass ecv}
%This package provides the documentclass \texttt{ecv}. The documentclass
%supports the following options:
%
%
%\begin{itemize}
%\item |german| Select language german
%\item |english| Select language english
%\item |empty| Do not print footer or header
%\item |selinput| Use \texttt{selinput} package instead of \texttt{inputenc} if
%       you encounter encoding problems and if you have \texttt{selinput} installed.
%\end{itemize}
%
%\section{Header}
%
%Between the \texttt{documentclass} and the
%\texttt{document}--environment two commands are supported:
%
%\DescribeMacro{ecvName}
%\DescribeMacro{ecvPortrait}
%\begin{itemize}
%\item |\ecvName|\marg{name} Sets the name of the author of the cv.
%      The name is printed in the left--hand footer. If the name is not
%      set, the left hand footer (\texttt{Curriculum Vitae} or
%      \texttt{Lebenslauf}) is not printed.
%\item |ecvPortrait|\marg{image--name} Sets the name of the image
%      that should be used as the portrait right to the title of the
%      curriculum vitae.
%      A file--extension of \texttt{jpg} is appended to the
%      \texttt{image-name}. The image is printed 40mm x 60mm. If the
%      |ecvPortrait| command does not exist no image is shown.
%\end{itemize}
%
%\section{Footer}
%
%After the curriculum vitae a field for the signature can be added. This
%package provides the following command for this purpose:
%
%\DescribeMacro{ecvSig}
%\begin{itemize}
%\item |\ecvSig|\marg{name}\marg{town} Creates a signature field beneath the 
%      curriculum vitae.
%\end{itemize}
%
%A signature looks the following way:
%
%\noindent
%MyTown, \today \\[18pt]
%  
%Name, My
%
%\section{ecv Environment}
%
%\DescribeEnv{ecv}
%The |ecv| environment encloses the curriculum vitae. All entries of
%the curriculum vitae must be inside an |ecv| environment. The |ecv|
%environment prints a title (either |Lebenslauf| or |Curriculum Vitae|)
%and the portrait (if one is defined) prior to the entries.
%
%\DescribeEnv{ecv*}
%In addition to the |ecv| environment the |ecv*| envrionment is provided.
%This environment works exactly like the |ecv| environment but ommits the
%title and the pricture.
%
%\section{Entries}
%
%The curriculum vitae is composed of entries which are composed of a tag (left hand
%side) and a value (right hand side). Both tag and value can come in
%different flavours.
%
%For example you have different entries for a job:
%``period of time'', ``branch of trade'', ``job title'' and ``job description''.
%It is recommended to have the ``period of time'' entry with a special 
%preceeding symbol, like a blue triangle, and the other entries with
%a common preceeding symbol, like a small bullet.
%
%Note that in this example several jobs would be listed
%under a section ``jobs''. In the description below the term
%group relies to a single job with its several entries.
%
%\DescribeMacro{\ecvTP}
%\DescribeMacro{\ecvTF}
%\DescribeMacro{\ecvTN}
%Tags can be written with the following macros:
%
%\begin{itemize}
%\item |\ecvTF|\oarg{lang}\marg{text} or |\ecvTagFirst|\oarg{lang}\marg{text}
%      A tag that starts a group of tags. The \texttt{text} is preceeded
%      by a small blue triangle.
%\item |\ecvTN|\oarg{lang}\marg{text} or |\ecvTagNext|\oarg{lang}\marg{text}
%      A tag inside a group of tags. The \texttt{text} is preceeded
%      by a small circle.
%\item |\ecvTP|\oarg{lang}\marg{text} or |\ecvTagPlain|\oarg{lang}\marg{text}
%      The most simple form of a tag. Just prints \texttt{text}, without a
%      preceeded symbol.
%\end{itemize}
%
%
%\DescribeMacro{\ecvVR}
%\DescribeMacro{\ecvVB}
%Values can be written as ragged right or as justified text with the following macros:
%
%\begin{itemize}
%\item |\ecvVR|\oarg{lang}\marg{text} or |\ecvValueRagged|\oarg{lang}\marg{text}
%      A value with a ragged right.
%\item |\ecvVB|\oarg{lang}\marg{text} or |\ecvValueBlocked|\oarg{lang}\marg{text}
%      A value with justified text.
%\end{itemize}
%
%\bigskip
%Tags and values are separated by a \&:
%
%\begin{verbatim}
%\ecvTP{Name} & \ecvVR{Name, My}
%\end{verbatim}
%
%\DescribeMacro{\ecvEPR}
%\DescribeMacro{\ecvEPB}
%\DescribeMacro{\ecvEFR}
%\DescribeMacro{\ecvEFB}
%\DescribeMacro{\ecvENR}
%\DescribeMacro{\ecvENB}
%Normally we want to write whole entries. We do not want to separate tags 
%and values. Therefore, a convenient form for writing whole entries are 
%the following macros which are in fact a combination of the tag and value 
%macros. The name of the macros is composed of |ecvE| followed by the flavour 
%of the tag followed by the flavour of the value:
%
%\begin{itemize}
%\item |\ecvEPR|\oarg{lang}\marg{tag}\marg{value} writes a plain tag with
%      a value with a ragged right.
%\item |\ecvEPB|\oarg{lang}\marg{tag}\marg{value} writes a plain tag with
%      a value with a blocked right.
%\item |\ecvEFR|\oarg{lang}\marg{tag}\marg{value} writes a first tag with
%      a value with a ragged right.
%\item |\ecvEFB|\oarg{lang}\marg{tag}\marg{value} writes a first tag with
%      a value with a blocked right.
%\item |\ecvENR|\oarg{lang}\marg{tag}\marg{value} writes a next tag with
%      a value with a ragged right.
%\item |\ecvENB|\oarg{lang}\marg{tag}\marg{value} writes a next tag with
%      a value with a blocked right.
%\end{itemize}
%
%Of course also these macros have a long form 
%
%\begin{quote}
%|\ecvTagPlainValueRagged|\\
%|\ecvTagPlainValueBlocked| \\
%|\ecvTagFirstValueRagged|\\
%|\ecvTagFirstValueBlocked| \\
%|\ecvTagNextValueRagged|\\
%|\ecvTagNextValueBlocked|\\
%\end{quote}
%
%\DescribeMacro{\ecvOVR}
%\DescribeMacro{\ecvOnlyValueRagged}
%\DescribeMacro{\ecvOVB}
%\DescribeMacro{\ecvOnlyValueBlocked}
%Two special macros are provided to only print the value part:
%
%
%\begin{itemize}
%\item |\ecvOVR|\oarg{lang}\marg{text} or |\ecvOnlyValueRagged|\oarg{lang}\marg{text}
%      Print only the value with a ragged right.
%\item |\ecvOVB|\oarg{lang}\marg{text} or |\ecvOnlyValueBlocked|\oarg{lang}\marg{text}
%      Print only the value with a blocked right.
%\end{itemize}
%
%\section{Sections}
%
%Entries in the curriculum vitae can be grouped by sections and
%subsections. Sections are printed with blue letters in the left column in
%a slightly bigger font--face. Subsections are printed in capital letters.
%
%
%\DescribeMacro{\ecvSec}
%\DescribeMacro{\ecvSection}
%\DescribeMacro{\ecvBSec}
%\DescribeMacro{\ecvBreakSection}
%The Section command comes in two flavours: with and without additional
%vertical space (6pt) beforehand:
%
%
%\begin{itemize}
%\item |\ecvSec|\oarg{lang}{text} or |\ecvSection|\oarg{lang}{text} 
%      Prints a section tag without additional vertical space beforehand.
%\item |\ecvBSec|\oarg{lang}{text} or  |\ecvBreakSection|\oarg{lang}{text}  
%      Prints a section tag with additional vertical space beforehand.
%\end{itemize}
%
%At the moment we did not to try any automatization of the vertical space 
%insertion, but have just experienced the necessity to add them. 
%Feel free to eleminate the need for the \texttt{ecvB} commands by
%using fancy automization rules, and and don't forget to provide your 
%superior \LaTeX\ macro knowledge to us.
%
%\DescribeMacro{\ecvSub}
%\DescribeMacro{\ecvBSub}
%\DescribeMacro{\ecvERSub}
%\DescribeMacro{\ecvBERSub}
%\DescribeMacro{\ecvEBSub}
%\DescribeMacro{\ecvBEBSub}
%Subsections tags are printed like section tags in the first column
%but in another font. In contrast to sections they can have a value
%attached. Subsection commands therefore are provided in a version with
%and a version without a value:
%
%\begin{itemize}
%\item |\ecvSub|\oarg{lang}\marg{text} Standard subsection (without 
%      additional vertical space).
%\item |\ecvBSub|\oarg{lang}\marg{text} Subsection with additional
%      vertical space (smallskip).
%\end{itemize}
%\begin{itemize}
%\item |\ecvERSub|\oarg{lang}\marg{text}\marg{value} Subsection with a 
%      ragged right value (without additional vertical space).
%\item |\ecvBERSub|\oarg{lang}\marg{text}\marg{value} Subsection with a 
%      ragged right value and with additional vertical space.
%\end{itemize}
%\begin{itemize}
%\item |\ecvEBSub|\oarg{lang}\marg{text}\marg{value} Subsection with a 
%      blocked right value (without additional vertical space).
%\item |\ecvBEBSub|\oarg{lang}\marg{text}\marg{value} Subsection with a 
%      blocked right value and with additional vertical space.
%\end{itemize}
%
%Also these command come with verbose forms: 
%
%\begin{quote}
%|\ecvSubSection|\\
%|\ecvBreakSubSection|\\
%|\ecvEntryRaggedSubSection|\\
%|\ecvBreakEntryRaggedSubSection|\\
%|\ecvEntryBlockedSubSection|\\
%|\ecvBreakEntryBlockedSubSection|\\
%\end{quote}
%
%\section{Layouting}
%
%The ecv class provides some command to tweak the layout of the cv.
%
%
%\DescribeMacro{\ecvPageBreak}
%\DescribeMacro{\ecvNewPage}
%The following two commands can be used to control page--breaks:
%
%\begin{itemize}
%\item |ecvPageBreak| Suggest a page--break.
%\item |ecvNewPage| For a new page.
%\end{itemize}
%
%\DescribeMacro{\ecvBreakParagraphs}
%The |\ecvBreakParagraphs| command can be used to add vertical space
%between entries.
%
%\DescribeMacro{\ecvNewLine}
%The |\ecvNewLine| can be introduced to continue on a new--line.
%
%\DescribeMacro{\ecvNewPara}
%The |\ecvNewPara| begins a new paragraph with addtional vertical space
%(smallskip).
%
%\DescribeMacro{\ecvBold}
%The command |\ecvBold|\marg{text} can be used to create bold written
%text.
%
%\section{Hyperlinks}
%
%
%\DescribeMacro{\ecvURL}
%\DescribeMacro{\ecvEMail}
%\DescribeMacro{\ecvHyperLink}
%\DescribeMacro{\ecvHyperEMail}
%The curriculum vitae class provides some commands to render hyperlinks:
%
%\begin{itemize}
%\item |\ecvHyperLink|\marg{url} Format a clickable url.
%\item |\ecvHyperEMail|\marg{email} Format a clickable email.
%\end{itemize}
%
%The above commands are based on the following non-clickable 
%commands, which provide the formating and which can 
%be used likewise:
%
%\begin{itemize}
%\item |\ecvURL|\marg{url} Format an unclickable url.
%\item |\ecvEMail|\marg{email} Format an unclickable email.
%\end{itemize}
%
%\section{Localized Strings}
%
%The following localized strings are provided for the german and english
%languages:
%
%
%\begin{itemize}
%\item |\ecvPerson| Either |Zur Person| or |Personal Information|
%\DescribeMacro{ecvPerson}
%\item |\ecvProfession| Either |Beruf| or |Profession|
%\DescribeMacro{ecvProfession}
%\item |\ecvResearch| Either |Forschung| or |Research|
%\DescribeMacro{ecvResearch}
%\item |\ecvEducation| Either |Ausbildung| or |Scholarship|
%\DescribeMacro{ecvEducation}
%\item |\ecvPublications| Either |Publikationen| or |Publications|
%\DescribeMacro{ecvPublications}
%\item |\ecvAwards| Either |Auszeichungen| or |Awards|
%\DescribeMacro{ecvAwards}
%\item |\ecvScholarships| Either |Stipendien| or |Scholarships|
%\DescribeMacro{ecvScholarships}
%\item |\ecvJobs| Either |Arbeitserfahrung| or |Jobs|
%\DescribeMacro{ecvJobs}
%\item |\ecvLanguages| Either |Sprachen| or |Languages|
%\DescribeMacro{ecvLanguages}
%\item |\ecvLanguageTravels| Either |Sprachreisen| or |Language Travels|
%\DescribeMacro{ecvLanguageTravels}
%\item |\ecvAbilities| Either |F"ahigkeiten| or |Abilities|
%\DescribeMacro{ecvAbilities}
%\item |\ecvConferences| Either |Konferenzen| or |Conferences|
%\DescribeMacro{ecvConferences}
%\item |\ecvSpeeches| Either |Vortr"age| or |Speeches|
%\DescribeMacro{ecvSpeeches}
%\item |\ecvTraining| Either |Fortbildung| or |Trainig|
%\DescribeMacro{ecvTrainig}
%\item |\ecvAttachements| Either |Anh"ange| or |Attachements|
%\DescribeMacro{ecvAttachements}
%\end{itemize}
%
%\section{Requirements}
%
%We instrument several other \LaTeX\ packages for different purposes,
%which must be available under your installation.
%
%\begin{itemize}
%\item geometry
%\item longtable
%\item pgf
%\item paralist
%\item helvet
%\item color
%\item fancyhdr
%\item inputenc
%\item fontenc
%\item ae
%\item aecompl
%\item aeguill
%\item textcomp
%\item url
%\item hyperref
%\item babel
%\end{itemize}
%
%
%
%
%\StopEventually{}
%\section{The Code}
%\iffalse
%    \begin{macrocode}
%<*ecv.cls>
%    \end{macrocode}
%\fi
%    \begin{macrocode}
%%
%% Copyright 2006-2011 Christoph P. Neumann, Bernd Haberstumpf
%%
%% This LaTeX class provides a simple interface for creating
%% a verfy fancy Curriculum Vitae. At the moment only CVs in
%% the german language are supported.
%%
%% This file is free property; as a special exception the author
%% gives unlimited permission to copy and/or distribute it, with
%% or without modifications, as long as this notice is
%% preserved.
%%
%% This file is distributed in the hope that it will be useful,
%% but WITHOUT ANY WARRANTY, to the extent permitted by law;
%% without even the implied warranty of MERCHANTABILITY or
%% FITNESS FOR A PARTICULAR PURPOSE.
%%
%% SPECIAL THANKS to
%% Alexander von Gernler, who introduced me to the European Curriculum Vitae
%%

% \changes{v0.1}{2007/01/06}{Initial version}
% \changes{v0.2}{2009/08/25}{0.2}
% \changes{v0.3}{2011/04/18}{0.3}

\def\fileversion{0.3}
\def\filedate{2011/04/18}

\NeedsTeXFormat{LaTeX2e}

%
% Class definition
% 

\ProvidesClass{ecv}[\filedate %
  \space Version \fileversion\space by %
  Christoph P.\ Neumann & Bernd Haberstumpf %
]


%
% Option definition
%

\def\ecv@lang{german}
\def\ecv@german{german}
\def\ecv@english{english}
\DeclareOption{german}{\def\ecv@lang{\ecv@german}}
\DeclareOption{english}{\def\ecv@lang{\ecv@english}}
\DeclareOption{oneside}{\PassOptionsToClass{oneside}{scrartcl}}
\DeclareOption{twoside}{\PassOptionsToClass{twoside}{scrartcl}}
\DeclareOption{selinput}{\def\ecv@selinput{1}}
\DeclareOption{empty}{\def\ecv@empty{1}}
\ProcessOptions

%
% Load base class
% 



\LoadClass[a4paper,11pt]{article}

% define command to check for pdf
\RequirePackage{ifpdf}
  
\ifpdf
  \pdfcompresslevel=9           % compression level fortext and image;
\fi

%
% Load packages
%

% NLS
\RequirePackage[\ecv@lang]{ecvNLS}


% Provides an ifthenelse command
\RequirePackage{ifthen}


% Pagelayout
\ifpdf
  \RequirePackage[a4paper, pdftex]{geometry}
\else
  \RequirePackage[a4paper, dvips ]{geometry}
\fi


% For the table that makes the text spanning multiple pages
\RequirePackage{longtable}

% Grafix package for the portrait
\RequirePackage{pgf}

% compact listings/enumerate environments
\RequirePackage{paralist}

% Font
\RequirePackage{helvet}

% Colors for the sections
\RequirePackage{xcolor}

% Needed for the footline to redefine the footline
\RequirePackage{fancyhdr}

\ifx\ecv@empty\undefined
% Inputencoding (latin1 with euro sign)
\RequirePackage[latin9]{inputenc} % = latin1, but also with euro sign
% Better variant than inputenc:
\else
  \RequirePackage{selinput}
% SelectInputMappings seems not to be necessary? ...
% If it is used in the cls file it makes problems if used 
% in a Windows environment... ?!?
%\SelectInputMappings{
%	adieresis={ä},
%	germandbls={ß},
%	Euro={€},
%}
\fi

% Outputencoding
\RequirePackage[T1]{fontenc}

% Font tweaking
%\RequirePackage{ae}
%\RequirePackage{aecompl}
%\RequirePackage{aeguill}
% e.g. for \textcopyleft
%\RequirePackage{textcomp}

% Output of links
\RequirePackage{url}
\ifpdf
  \RequirePackage[pdftex]{hyperref} %,pdfstartpage=9
\else
  \RequirePackage[dvips]{hyperref} %ALT: colorlinks
\fi


%
% configuration (page setup, color setup etc.)
%

% page setup
\geometry{left=30mm, right=20mm, top=20mm, bottom=15mm}

% Footer
\ifx\ecv@empty\undefined
  \pagestyle{fancy}
\else
  \pagestyle{empty}
\fi

% Color setup (for the sections)
\definecolor{ecv@ColBlue}{rgb}{0.04,0.44,0.59}   % ANPA 732-0, but darker
\definecolor{ecv@ColRed}{rgb}{0.921,0.282,0.278} % ANPA 723-0

\ClassInfo{ecv}{used language is \ecv@lang}

% This variable holds the name set with ecvName
\newcommand{\ecv@name}{}

% \begin{document} preamble
\AtBeginDocument{%
  \sffamily
  \raggedbottom
  \fancyhead{}
  \fancyfoot{}
  \renewcommand{\headrulewidth}{0pt}
  \renewcommand{\footrulewidth}{0pt}
  \fancyfoot[R]{
    \begin{minipage}{5cm}\begin{flushright}
      \footnotesize{}\textsf{\ecvPage~\thepage}
    \end{flushright}\end{minipage}
  }
  \ifthenelse{\equal{\ecv@name}{}}{
    ~
  }{
    \fancyfoot[L]{
      \begin{minipage}{6cm}
        \footnotesize{}\textsf{\ecvTitle~\ecv@name}
      \end{minipage}
    }
  }
}

% Command to layout the portrait (must be 60mmx40mm) 
\newcommand\ecv@Portrait[1]{%
  %% A frame as placeholder (with  some 1mm inner padding):
  \pgfrect[stroke]{\pgfxy(6.85,0.65)}{\pgfxy(4.3,-6.3)}
  %% Actually a concrete digital image:
  \pgfdeclareimage[interpolate=true,height=60mm,width=40mm]{portrait}{#1}
  \pgfputat{\pgfxy(6.77,0.5)}{\pgfbox[left,top]{\pgfuseimage{portrait}}}
}

% This variable holds the name of the portrait image
\newcommand\ecv@img{}

% title with image
\newcommand{\ecv@Title}{%
  \ifthenelse{\equal{\ecv@img}{}}{ %
    \ecvLeft{\textsc{\LARGE{\ecvTitle}}%
      \bigskip\bigskip\bigskip%
    } & \tabularnewline %
  }{ %
    \ecvLeft{\textsc{\LARGE{\ecvTitle}}%
      \bigskip\bigskip\bigskip%
    } & \ecv@Portrait{\ecv@img} %
    \tabularnewline %
  } %
}


%
% Define new commands
% 

% Hyperlink commands
\newcommand\ecvURL{\begingroup \urlstyle{sf}\Url}
\newcommand\ecvEMail{\begingroup \urlstyle{sf}\Url}
\ifpdf
  \newcommand{\ecvHyperLink}[1]{%
    \href{#1}{\ecvURL{#1}}%
  }
  \newcommand{\ecvHyperEMail}[1]{%
    \href{mailto:#1}{\ecvEMail{#1}}%
  }
  \newcommand{\ecvHttp}[1]{%
    \href{http://#1}{\ecvURL{#1}}%
  }
\else
  \newcommand{\ecvHyperLink}[1]{%
    \ecvURL{#1}%
  }
  \newcommand{\ecvHyperEMail}[1]{%
    \ecvEMail{#1}%
  }
  \newcommand{\ecvHttp}[1]{%
    \ecvURL{#1}%
  }
\fi
\hypersetup{a4paper,pdfpagelayout={SinglePage},pdfstartview={Fit}}
\hyperbaseurl{http://}


% Name

% Defines the name of the issuer for the footline
\newcommand{\ecvName}[1]{\renewcommand{\ecv@name}{#1}}

% Portrait

% Defines the image (to be used before the \begin{ecv})
% \ecvPortrait{file-name}
\newcommand{\ecvPortrait}[1]{\renewcommand\ecv@img{#1}}


% Environment for layouting the cv

% Environment that prints title and portrait
\newenvironment{ecv}{%
  \begin{longtable}{p{.32\linewidth}|p{.68\linewidth}}
  \ecv@Title
}{%
  \end{longtable}
}
% Environment that skips title and portrait
\newenvironment{ecv*}{%
  \begin{longtable}{p{.32\linewidth}|p{.68\linewidth}}
}{%
  \end{longtable}
}

% Vertical Spacing to be used in left column

% begin new row: make an (optional) spacing before a section
\newcommand{\ecvBreaksections}[0]{& \tabularnewline[6pt]}
% begin new row: make a break before a subsection
\newcommand{\ecvBreaksubsections}[0]{& \tabularnewline\smallskip}
% begin new row: make a break inside a section (for subsub grouping of entries)
\newcommand{\ecvBreakparagraphs}[0]{& \tabularnewline}

% Vertical spacing to be used inside a column

% start text on a new line
\newcommand{\ecvNewLine}[0]{\\}
% start a new paragraph
\newcommand{\ecvNewPara}[0]{\smallskip}

% Newpage

% Force a page break
\newcommand{\ecvNewPage}{
  \newpage
}
% Suggest a page break
\newcommand{\ecvPageBreak}{
  \pagebreak
}

% emphasizings text
\newcommand{\ecvBold}[2][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \textbf{#2}%
  }{}%
}

% bullets for the left column entries
\newcommand{\ecvBulleted}[1]{$\circ$ #1}
\newcommand{\ecvBulletedFirst}[1]{%
  \textcolor{ecv@ColBlue}{$\triangleright$} #1%
}

% layout primitives for left and right column

% primitve for the left column
\newcommand{\ecvLeft}[1]{%
  \parbox[t]{\linewidth}{\raggedright #1}%
}
% primitive for the right column (raggedright)
\newcommand{\ecvRight}[1]{%
  %\parbox[t]{\linewidth}{
  {\raggedright #1}%
  \tabularnewline%
}
% primitive for the right column (block)
\newcommand{\ecvRightBlock}[1]{%
  \parbox[t]{0.9\linewidth}{#1}%
  \tabularnewline%
}


% left column commands

% tag without bullet (simple left column entry)
\newcommand{\ecvTP}[2][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvLeft{#2}%
  }{}%
}
\newcommand{\ecvTagPlain}[2][\ecv@lang]{\ecvTP[#1]{#2}}
% tag with first line mark (triange bullet left column entry)
\newcommand{\ecvTF}[2][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvBreakparagraphs
    \smallskip
    \ecvLeft{\ecvBulletedFirst{#2}}%
  }{}%
}
\newcommand{\ecvTagFirst}[2][\ecv@lang]{\ecvTF[#1]{#2}}
% tag with first line mark (triange bullet left column entry)
% but WITHOUT the line break!
\newcommand{\ecvTI}[2][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvLeft{\ecvBulletedFirst{#2}}%
  }{}%
}
\newcommand{\ecvTagIntermediate}[2][\ecv@lang]{\ecvTI[#1]{#2}}
% tag with first follow line mark (circle bullet left column entry)
\newcommand{\ecvTN}[2][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvLeft{\ecvBulleted{#2}}%
  }{}%
}
\newcommand{\ecvTagNext}[2]{\ecvTN[#1]{#2}}


% right column commands

% value with raggedright layout
\newcommand{\ecvVR}[2][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvRight{#2}%
  }{}%
}
\newcommand{\ecvValueRagged}[2][\ecv@lang]{\ecvVR[#1]{#2}}
% value with block layout
\newcommand{\ecvVB}[2][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvRightBlock{#2}%
  }{}%
}
\newcommand{\ecvValueBlocked}[2][\ecv@lang]{\ecvVB[#1]{#2}}


% Compound commands tag+value

% Plain tag with ragged value
\newcommand{\ecvEPR}[3][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvTP[#1]{#2} & \ecvVR[#1]{#3} %
  }{}%
}
\newcommand{\ecvTagPlainValueRagged}[3][\ecv@lang]{\ecvERP[#1]{#2}{#3}}
% Plain tag with blocked value
\newcommand{\ecvEPB}[3][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvTP[#1]{#2} & \ecvVB[#1]{#3} %
  }{}%
}
\newcommand{\ecvTagPlainValueBlocked}[3][\ecv@lang]{\ecvERB[#1]{#2}{#3}}
% bulleted first tag with ragged value
\newcommand{\ecvEFR}[3][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvTF[#1]{#2} & \ecvVR[#1]{#3} %
  }{}%
}
\newcommand{\ecvTagFirstValueRagged}[3][\ecv@lang]{\ecvEFR[#1]{#2}{#3}}
% bulleted first tag with blocked value
\newcommand{\ecvEFB}[3][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvTF[#1]{#2} & \ecvVB[#1]{#3} %
  }{}%
}
\newcommand{\ecvTagFirstValueBlocked}[3][\ecv@lang]{\ecvEFB[#1]{#2}{#3}}
% bulleted intermediate tag with ragged value
\newcommand{\ecvEIR}[3][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvTI[#1]{#2} & \ecvVR[#1]{#3} %
  }{}%
}
\newcommand{\ecvTagIntermediateValueRagged}[3][\ecv@lang]{\ecvEIR[#1]{#2}{#3}}
% bulleted intermediate tag with blocked value
\newcommand{\ecvEIB}[3][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvTI[#1]{#2} & \ecvVB[#1]{#3} %
  }{}%
}
\newcommand{\ecvTagIntermediateValueBlocked}[3][\ecv@lang]{\ecvEIB[#1]{#2}{#3}}
\newcommand{\ecvENR}[3][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvTN[#1]{#2} & \ecvVR[#1]{#3} %
  }{}%
}
\newcommand{\ecvTagNextValueRagged}[3][\ecv@lang]{\ecvENR[#1]{#2}{#3}}
% bulleted next tag with blocked value
\newcommand{\ecvENB}[3][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvTN[#1]{#2} & \ecvVB[#1]{#3} %
  }{}%
}
\newcommand{\ecvTagNextValueBlocked}[3][\ecv@lang]{\ecvENB[#1]{#2}{#3}}
% value only ragged
\newcommand{\ecvOVR}[2][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    & \ecvVR[#1]{#2} %
  }{}%
}
\newcommand{\ecvOnlyValueRagged}[2][\ecv@lang]{\ecvOVR[#1]{#2}}
\newcommand{\ecvOVB}[2][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    & \ecvVB[#1]{#2} %
  }{}%
}
\newcommand{\ecvOnlyValueBlocked}[2][\ecv@lang]{\ecvOVB[#1]{#2}}




% Sections

% section: \ecvSection{name}
\newcommand{\ecvSec}[2][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvLeft{\textsc{\Large{\textcolor{ecv@ColBlue}{#2}}} \bigskip } &%
    \tabularnewline%
  }{}%
}
\newcommand{\ecvSection}[2][\ecv@lang]{\ecvSec[#1]{#2}}
% section with breaksection: \ecvBreakSection{name}
\newcommand{\ecvBSec}[2][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvBreaksections
    \ecvLeft{\textsc{\Large{\textcolor{ecv@ColBlue}{#2}}} \bigskip } &%
    \tabularnewline%
  }{}%
}
\newcommand{\ecvBreakSection}[2][\ecv@lang]{\ecvBSec[#1]{#2}}
% sub-section: \ecvSubSection{name}
\newcommand{\ecvSub}[2][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvLeft{\textsc{\large{#2}}}%
    & \tabularnewline%
  }{}%
}
\newcommand{\ecvSubSection}[2][\ecv@lang]{\ecvSub[#1]{#2}}
\newcommand{\ecvBSub}[2][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvBreaksubsections
    \ecvLeft{\textsc{\large{#2}}}%
    & \tabularnewline%
  }{}%
}
\newcommand{\ecvBreakSubSection}[2][\ecv@lang]{\ecvBSub[#1]{#2}}
% sub-section with a value
\newcommand{\ecvERSub}[3][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvLeft{\textsc{\large{#2}}} & \ecvRight{#3}%
  }{}%
}
\newcommand{\ecvEntryRaggedSubSection}[3][\ecv@lang]{\ecvERSub[#1]{#2}{#3}}
\newcommand{\ecvBERSub}[3][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvBreaksubsections
    \ecvLeft{\textsc{\large{#2}}} & \ecvRight{#3}%
  }{}%
}
\newcommand{\ecvBreakEntryRaggedSubSection}[3][\ecv@lang]{\ecvBERSub[#1]{#2}{#3}}
% sub-section with a value
\newcommand{\ecvEBSub}[3][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvLeft{\textsc{\large{#2}}} & \ecvRightBlock{#3}%
  }{}%
}
\newcommand{\ecvEntryBlockedSubSection}[3][\ecv@lang]{\ecvEBSub[#1]{#2}{#3}}
\newcommand{\ecvBEBSub}[3][\ecv@lang]{%
  \ifthenelse{\equal{#1}{\ecv@lang}}{%
    \ecvBreaksubsections
    \ecvLeft{\textsc{\large{#2}}} & \ecvRightBlock{#3}%
  }{}%
}
\newcommand{\ecvBreakEntryBlockedSubSection}[3][\ecv@lang]{\ecvBEBSub[#1]{#2}{#3}}




% Signature

% \ecvSignature{name}{town}
\newcommand{\ecvSig}[2]{ %
  \vspace{1cm}
  \noindent
  #2, \today \\[18pt]

  #1
}
\newcommand{\ecvSignature}[2]{\ecvSig{#1}{#2}}
%    \end{macrocode}
%\iffalse
%    \begin{macrocode}
%</ecv.cls>
%    \end{macrocode}
%\fi
%\iffalse
%    \begin{macrocode}
%<*ecvEnglish.ldf>
%    \end{macrocode}
%\fi
%    \begin{macrocode}
%%
%% Copyright 2006-2011 Christoph P. Neumann, Bernd Haberstumpf
%%
%% This a language definition file for the ecv class.
%% THe file defines some NLS strings.
%%
%% This file is free property; as a special exception the author
%% gives unlimited permission to copy and/or distribute it, with
%% or without modifications, as long as this notice is 
%% preserved.
%%
%% This file is distributed in the hope that it will be useful, 
%% but WITHOUT ANY WARRANTY, to the extent permitted by law; 
%% without even the implied warranty of MERCHANTABILITY or 
%% FITNESS FOR A PARTICULAR PURPOSE.
%%
%% SPECIAL THANKS to
%% Alexander von Gernler, who introduced me to the European Curriculum Vitae
%%

\def\fileversion{0.3}
\def\filedate{2011/04/18}

\NeedsTeXFormat{LaTeX2e}

\ProvidesFile{ecvEnglish.ldf}[2007/01/05]

\def\ecvNLS@Page{Page}
\def\ecvNLS@Title{Curriculum Vitae}
\def\ecvNLS@Person{Personal Information}
\def\ecvNLS@Profession{Profession}
\def\ecvNLS@Education{Education}
\def\ecvNLS@Research{Research}
\def\ecvNLS@Awards{Awards}
\def\ecvNLS@Publications{Publications}
\def\ecvNLS@Scholarships{Scholarships}
\def\ecvNLS@Jobs{Jobs}
\def\ecvNLS@Languages{Languages}
\def\ecvNLS@LanguageTravels{Language Travels}
\def\ecvNLS@Abilities{Abilities}
\def\ecvNLS@Conferences{Conferences}
\def\ecvNLS@Speeches{Speeches}
\def\ecvNLS@Trainig{Training}
\def\ecvNLS@Attachements{Attachements}
%    \end{macrocode}
%\iffalse
%    \begin{macrocode}
%</ecvEnglish.ldf>
%    \end{macrocode}
%\fi
%\iffalse
%    \begin{macrocode}
%<*ecvGerman.ldf>
%    \end{macrocode}
%\fi
%    \begin{macrocode}
%%
%% Copyright 2006-2011 Christoph P. Neumann, Bernd Haberstumpf
%%
%% This a language definition file for the ecv class.
%% THe file defines some NLS strings.
%%
%% This file is free property; as a special exception the author
%% gives unlimited permission to copy and/or distribute it, with
%% or without modifications, as long as this notice is 
%% preserved.
%%
%% This file is distributed in the hope that it will be useful, 
%% but WITHOUT ANY WARRANTY, to the extent permitted by law; 
%% without even the implied warranty of MERCHANTABILITY or 
%% FITNESS FOR A PARTICULAR PURPOSE.
%%
%% SPECIAL THANKS to
%% Alexander von Gernler, who introduced me to the European Curriculum Vitae
%%


\def\fileversion{0.3}
\def\filedate{2011/04/18}

\NeedsTeXFormat{LaTeX2e}

\ProvidesFile{ecvGerman.ldf}[2007/01/05]

\def\ecvNLS@Page{Seite}
\def\ecvNLS@Title{Lebenslauf}
\def\ecvNLS@Person{Zur Person}
\def\ecvNLS@Profession{Beruf}
\def\ecvNLS@Education{Bildung}
\def\ecvNLS@Research{Forschung}
\def\ecvNLS@Awards{Auszeichnungen}
\def\ecvNLS@Publications{Publikationen}
\def\ecvNLS@Scholarships{Stipendien}
\def\ecvNLS@Jobs{Arbeitserfahrung}
\def\ecvNLS@Languages{Sprachen}
\def\ecvNLS@LanguageTravels{Sprachreisen}
\def\ecvNLS@Abilities{F\"ahigkeiten}
\def\ecvNLS@Conferences{Konferenzen}
\def\ecvNLS@Speeches{Vortr\"age}
\def\ecvNLS@Trainig{Fortbildung}
\def\ecvNLS@Attachements{Anlagen}
%    \end{macrocode}
%\iffalse
%    \begin{macrocode}
%</ecvGerman.ldf>
%    \end{macrocode}
%\fi
%\iffalse
%    \begin{macrocode}
%<*ecvNLS.sty>
%    \end{macrocode}
%\fi
%    \begin{macrocode}
%%
%% Copyright 2006-2007 Christoph Neumann, Bernd Haberstumpf
%%
%% This LaTeX package provides NLS support for the ecv class.
%%
%% This file is free property; as a special exception the author
%% gives unlimited permission to copy and/or distribute it, with
%% or without modifications, as long as this notice is 
%% preserved.
%%
%% This file is distributed in the hope that it will be useful, 
%% but WITHOUT ANY WARRANTY, to the extent permitted by law; 
%% without even the implied warranty of MERCHANTABILITY or 
%% FITNESS FOR A PARTICULAR PURPOSE.
%%
%% SPECIAL THANKS to
%% Alexander von Gernler, who introduced me to the European Curriculum Vitae
%%

\def\fileversion{0.1}
\def\filedate{2007/01/05}

\NeedsTeXFormat{LaTeX2e}

%
% Package definition
% 

\ProvidesPackage{ecvNLS}[\filedate %
  \space Version \fileversion\space by %
  Christoph Neumann & Bernd Haberstumpf %
]

%
% Option definition
%

\def\ecvNLS@lang{german}
\def\ecvNLS@german{1}
\def\ecvNLS@english{2}
\DeclareOption{german}{\def\ecvNLS@lang{\ecvNLS@german}\input{ecvGerman.ldf}}
\DeclareOption{english}{\def\ecvNLS@lang{\ecvNLS@english}\input{ecvEnglish.ldf}}
\ProcessOptions


%
% Load packages
%

% \selectlanguage{ngerman} will be called after \begin{document}
\RequirePackage[ngerman,english]{babel}   


% \begin{document} preamble
\AtBeginDocument{%
  \ifnum\ecvNLS@lang =\ecvNLS@german
    \selectlanguage{ngerman}
  \else
    \selectlanguage{english}
  \fi
}


%
% Define NLS commands
%

\newcommand{\ecvPage}{\ecvNLS@Page}
\newcommand{\ecvTitle}{\ecvNLS@Title}
\newcommand{\ecvPerson}{\ecvNLS@Person}
\newcommand{\ecvProfession}{\ecvNLS@Profession}
\newcommand{\ecvEducation}{\ecvNLS@Education}
\newcommand{\ecvResearch}{\ecvNLS@Research}
\newcommand{\ecvAwards}{\ecvNLS@Awards}
\newcommand{\ecvPublications}{\ecvNLS@Publications}
\newcommand{\ecvScholarships}{\ecvNLS@Scholarships}
\newcommand{\ecvJobs}{\ecvNLS@Jobs}
\newcommand{\ecvLanguages}{\ecvNLS@Languages}
\newcommand{\ecvLanguageTravels}{\ecvNLS@LanguageTravels}
\newcommand{\ecvAbilities}{\ecvNLS@Abilities}
\newcommand{\ecvConferences}{\ecvNLS@Conferences}
\newcommand{\ecvSpeeches}{\ecvNLS@Speeches}
\newcommand{\ecvTrainig}{\ecvNLS@Trainig}
\newcommand{\ecvAttachements}{\ecvNLS@Attachements}
%    \end{macrocode}
%\iffalse
%    \begin{macrocode}
%</ecvNLS.sty>
%    \end{macrocode}
%\fi
%\Finale
\endinput
