I would like to change like the moderncv
casual
theme:
- There is too much space below the picture, or above "Persönliches"… The picture should be directly on the right of the first block.
- I would like to have "Lebenslauf" on the left or in the middle of the line… but not on the right…
I tried a bit to change the header but it was not completly successful. And I also think there is lot in my header, which is not really needed.
Can someone give me a hint?
Thank you
\documentclass[a4paper,11pt]{moderncv}
\usepackage[scale=0.75,tmargin=2.0cm,right=2.8cm,left=2.5cm,bmargin=2.7cm]{geometry}
\usepackage[ngerman]{babel}
\usepackage[utf8]{inputenc}
\usepackage{paralist}
\usepackage{lmodern}
\moderncvtheme[red]{casual}
\nopagenumbers{}
\usepackage[scale=0.75]{geometry}
\renewcommand*{\titlefont}{\LARGE\mdseries\upshape}
\makeatletter
\renewcommand*{\makecvtitle}{
\recomputecvlengths
\makecvfooter%
\newbox{\makecvtitlepicturebox}
\savebox{\makecvtitlepicturebox}{
\ifthenelse{\isundefined{\@photo}}
{}
{%
\setlength\fboxrule{\@photoframewidth}%
\ifdim\@photoframewidth=0pt%
\setlength{\fboxsep}{0pt}\fi%
{\color{color1}\framebox{\includegraphics[width=\@photowidth]{\@photo}}}}}
\hfill%\usebox{\makecvtitlepicturebox}%
\@initializelength{\makecvtitlepicturewidth}
\settowidth{\makecvtitlepicturewidth}{\usebox{\makecvtitlepicturebox}}%
\parbox[b]{\textwidth-\makecvtitlepicturewidth}{
\raggedleft\namefont{\color{color2!50}\textsf{\@firstname}} {
\color{color2}\textsf{\@familyname}}}\\ [-.35em]
{\color{color2!50}\rule{\textwidth}{.25ex}}%
\ifthenelse{\equal{\@title}{}}{}{\\[1.25em]\null\titlestyle{\@title}}
\hfill\smash{\raisebox{\dimexpr-\ht\makecvtitlepicturebox+\baselineskip \relax}{
\usebox{\makecvtitlepicturebox}}}\\[0.5em]
\ifthenelse{\isundefined{\@quote}}%
{}
{{\null\hfill\begin{minipage} {\quotewidth}\centering \quotestyle{\@quote}\end{minipage}\hfill\null\\[2.5em]}}
\par}%
\makeatother
\setlength{\hintscolumnwidth}{3.5cm}
\name{}{Lebenslauf}
\photo[110pt][0.0pt]{picture.jpg}
\title{~}
\begin{document}
\maketitle
\section{Persönliches}
\cvitem{Name}{-------------}
\cvitem{Adresse}{--------------------------}
\cvitem{Handy}{0176 / 0000 0000}
\cvitem{E-Mail}{mail@mail.by}
\cvitem{Geburtsdatum}{40. Dezember 1900}
\cvitem{Geburtsort}{Berlin}
\cvitem{Nationalität}{Deutsch}
\section{Promotion}
\end{document}
Best Answer
You asked two things:
To get what you want in this case an easy way is to set the photo with package
textpos
in this way:Please change the given width
width=110pt
and the position(8.5,2.6)
, given in cm, where the image has to be placed for your own needs. It depends at last of the used image and where you want it to be ...Because you did not tell us if yu are using the letter (then you perhaps need the usage of given variables of
moderncv
) I changed your header code that you can now use:You see I commented the definition of
\photo
, in your case it is not needed.Because your wish complete destroys the layout of style
casual
we can now short the code to only generate the wanted title (see font changing please!) and the rule (there were a lot of new lines in your old code resulting in the huge distance between title and first section of cv):You can change the distance between title/rule and first section of your cv (Persönliches) with changing the code
\\[2ex]
to a number, what you need, for example\\[2cm]
.The complete MWE
gives the the wished result: