Seite 1 von 1

Lebenslauf mit Latex

Verfasst: Mo 22. Apr 2013, 10:53
von galilio
Hallo alle zusammen,

ich habe meine lebenslauf mit Latex geschrieben, nur leider habe ich eine kleine Problem.
Ich möchte gerne die farben der Balkem umändern ja nach dem wie die Firmen in deren Homepage haben.
Konkret gesagt :
die Klasse \moderncvtheme[blue]{casual}
hat die farbe blue als default und man kann die Farben ändern zwischen 'orange', 'red', 'green', 'grey' und 'roman' : ich möchte aber andere Farben haben.

Hier ist eine Beispiel :
%\documentclass[11pt,a4paper]{moderncv}

\moderncvtheme[red]{casual}
\usepackage[latin1]{inputenc}
\AtBeginDocument{\recomputelengths}
\AtBeginDocument{\definecolor{sectionrectanglecolor}{rgb}{1,0.80,0}}
\AtBeginDocument{\definecolor{sectiontitlecolor}{rgb}{1,1,0}}
\makeatletter
\AtBeginDocument{
\providecommand*{\makefooter}{}
\renewcommand*{\makefooter}{%
  \fancypagestyle{plain}{%
    \fancyfoot[c]{%
      \parbox{0.8\textwidth}{%
      \centering%
      \addressfont\color{addresscolor}%
      \ifthenelse{\isundefined{\@familyname}}{}{\@firstname~\@familyname\@firstfooterelementfalse}
      \ifthenelse{\isundefined{\@addressstreet}}{}{%
      	{~~\color{footersymbolcolor}\textbullet~~~}
        \addresssymbol~\@addressstreet%
        \@firstfooterelementtrue%
      	\ifthenelse{\isundefined{\@addresscity}}{}{~--~\@addresscity}\\\@firstfooterelementfalse}%
      \ifthenelse{\isundefined{\@mobile}}{}{\footersymbol\mobilesymbol~\@mobile\@firstfooterelementfalse}%
      \ifthenelse{\isundefined{\@phone}}{}{\footersymbol\phonesymbol~\@phone\@firstfooterelementfalse}%
      \ifthenelse{\isundefined{\@fax}}{}{\footersymbol\faxsymbol~\@fax\@firstfooterelementfalse}%
      \ifthenelse{\isundefined{\@email}}{}{\footersymbol\emailsymbol~\emaillink{\@email}\@firstfooterelementfalse}%
      \ifthenelse{\isundefined{\@extrainfo}}{}{\footersymbol\@extrainfo\@firstfooterelementfalse}}}%
  }%
  \pagestyle{plain}}
\AtBeginDocument{\makefooter}}
\makeatother
\firstname{John}
\familyname{Doe}
\title{Resumé title (optional)}
\address{street and number}{postcode city}
\mobile{mobile (optional)}
\phone{phone (optional)}
\fax{fax (optional)}
\email{email (optional)}
\extrainfo{additional information (optional)}
%\photo[64pt]{picture}
\quote{Some quote (optional)}

%------------------------------
% content
%------------------------------
\begin{document}
\maketitle

\section{Education}
\cventry{year--year}{Degree}{Institution}{City}{\textit{Grade}}{D escription}
\cventry{year--year}{Degree}{Institution}{City}{\textit{Grade}}{D escription}

\end{document}
% Ende des Dokumentes
[/code]

Verfasst: Mo 22. Apr 2013, 12:22
von Epllus
moderncv definiert seine Farben etwas kompliziert, aber hier mal eine Lösung:
\RequirePackage{filecontents} 

\begin{filecontents}{moderncvcolorviolet.sty}
\NeedsTeXFormat{LaTeX2e} 
\ProvidesPackage{moderncvcolorviolet}[2013/02/09 v1.3.0 modern curriculum vitae and letter color scheme: green] 

\definecolor{color0}{rgb}{0,0,0}% 
\definecolor{color1}{rgb}{0.502,0.0,0.502}% violet 
\definecolor{color2}{rgb}{0.45,0.45,0.45}% 
\endinput 
\end{filecontents} 

\begin{filecontents}{moderncvcolorbrown.sty}
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{moderncvcolorbrown}[2013/02/09 v1.3.0 modern curriculum vitae and letter color scheme: green] 

\definecolor{color0}{rgb}{0,0,0}% 
\colorlet{color1}{brown} 
\definecolor{color2}{rgb}{0.45,0.45,0.45}% 

\endinput 
\end{filecontents} 


\documentclass[11pt,a4paper]{moderncv} 
\usepackage{xcolor} 

\moderncvtheme[violet]{casual} 
\usepackage[latin1]{inputenc} 
\AtBeginDocument{\recomputelengths} 
\AtBeginDocument{\definecolor{sectionrectanglecolor}{rgb}{1,0.80,0}} 
\AtBeginDocument{\definecolor{sectiontitlecolor}{rgb}{1,1,0}} 
\makeatletter 
\AtBeginDocument{ 
\providecommand*{\makefooter}{} 
\renewcommand*{\makefooter}{% 
  \fancypagestyle{plain}{% 
    \fancyfoot[c]{% 
      \parbox{0.8\textwidth}{% 
      \centering% 
      \addressfont\color{addresscolor}% 
      \ifthenelse{\isundefined{\@familyname}}{}{\@firstname~\@familyname\@firstfooterelementfalse} 
      \ifthenelse{\isundefined{\@addressstreet}}{}{% 
         {~~\color{footersymbolcolor}\textbullet~~~} 
        \addresssymbol~\@addressstreet% 
        \@firstfooterelementtrue% 
         \ifthenelse{\isundefined{\@addresscity}}{}{~--~\@addresscity}\\\@firstfooterelementfalse}% 
      \ifthenelse{\isundefined{\@mobile}}{}{\footersymbol\mobilesymbol~\@mobile\@firstfooterelementfalse}% 
      \ifthenelse{\isundefined{\@phone}}{}{\footersymbol\phonesymbol~\@phone\@firstfooterelementfalse}% 
      \ifthenelse{\isundefined{\@fax}}{}{\footersymbol\faxsymbol~\@fax\@firstfooterelementfalse}% 
      \ifthenelse{\isundefined{\@email}}{}{\footersymbol\emailsymbol~\emaillink{\@email}\@firstfooterelementfalse}% 
      \ifthenelse{\isundefined{\@extrainfo}}{}{\footersymbol\@extrainfo\@firstfooterelementfalse}}}% 
  }% 
  \pagestyle{plain}} 
\AtBeginDocument{\makefooter}} 
\makeatother 
\firstname{John} 
\familyname{Doe} 
\title{Resumé title (optional)} 
\address{street and number}{postcode city} 
\mobile{mobile (optional)} 
\phone{phone (optional)} 
\fax{fax (optional)} 
\email{email (optional)} 
\extrainfo{additional information (optional)} 
%\photo[64pt]{picture} 
\quote{Some quote (optional)} 

%------------------------------ 
% content 
%------------------------------ 
\begin{document} 
\maketitle 

\section{Education} 
\cventry{year--year}{Degree}{Institution}{City}{\textit{Grade}}{D escription} 
\cventry{year--year}{Degree}{Institution}{City}{\textit{Grade}}{D escription} 

\end{document} 
% Ende des Dokumentes 
Wie du bemerkst, erstelle ich mittels filecontents zwei neue .sty Dateien (moderncvcolorviolet.sty, moderncvcolorbrown.sty).
Nun sind noch die Farben brown und violet verfügbar.
Willst du eine neue Farbe, müstest du das kopieren und bei color1 eine neue Farbdefinition eingeben, entweder durch \definecolor (wie bei violet) oder durch \colorlet (wie bei brown).

Hoffe es hilft
Epllus

Verfasst: Mo 22. Apr 2013, 12:27
von Genmutant
Du musst einfach color1 und color2 mit der entsprechenden Farbe belegen, z.B.:
\definecolor{color1}{cmyk}{0, 0, 0, 0.75}

Verfasst: Mo 22. Apr 2013, 12:38
von galilio
@Epllus

ich danke es dor für die Antwort nur leider kann ich nicht dein Beispiel kompilieren.
ich bekomme folgende Fehlermedlung :

! LaTeX Error: Missing \begin{document}.See the LaTeX manual or LaTeX Companion for explanation.Type H <return> for immediate help.... \begin{filecontents}{moderncvcolorviolet.sty}

danke es dir in voraus.

Verfasst: Mo 22. Apr 2013, 13:27
von Epllus
Merkwürdig, da es bei mir funktioniert. Jedenfalls habe ich es edidiert, sollte jetzt funktionieren.

Grüße
Epllus

Verfasst: Mo 22. Apr 2013, 13:47
von galilio
@Epllus
Kannst du mir deine Änderung hier posten!


Danke im voraus

Verfasst: Mo 22. Apr 2013, 13:53
von Epllus
Ich habe mein Beispiel oben editiert, sprich ich habe statt einen neuen Post zu machen den alten verändert.

Grüße
Epllus

Verfasst: Mo 22. Apr 2013, 14:15
von galilio
@Epllus

ich danke es dir.
Es hat funktioniert.