modercv의 경우 \cventry에 로고 삽입(클래식 스타일)

modercv의 경우 \cventry에 로고 삽입(클래식 스타일)

moderncv이력서용으로 사용하고 있습니다 . 약간의 조정을 거쳐 moderncvstyleclassic.sty원하는 결과에 거의 도달했습니다. 마지막으로 해결할 수 없는 문제가 하나 있습니다. 의 오른쪽 끝에 로고를 추가하고 싶습니다 \cventry.

지금은 다음과 같은 새 명령을 만들었습니다 \cventrylogo.

\renewcommand*{\cventrylogo}[8][.25em]{%
  \cvitem[#1]{#2}{%
    {\bfseries#3}%
    \ifthenelse{\equal{#4}{}}{}{, {\slshape#4}}%
    \ifthenelse{\equal{#5}{}}{}{, #5}%
    \ifthenelse{\equal{#6}{}}{}{, #6.}%
    \ifthenelse{\equal{#7}{}}{}{\hfill \includegraphics[scale=0.25]{#7}}%
    \strut%
    \ifx&#8&%
      \else{\newline{}\begin{minipage}[t]{\linewidth}\small#8\end{minipage}}\fi}}

그런 다음 다음과 같이 사용합니다.

\section{Experience}
\cventrylogo{2015}{Short Term Scientific Collaborator}{M\'et\'eosuisse}{Payerne}{Switzerland}{logo_meteosuisse}{}
\cventrylogo{2009--2014}{PhD. in Physical Chemistry}{ETH}{Zurich}{Switzerland}{logo_eth}{}
\cventrylogo{2006--2008}{Process Development Engineer}{STM S.p.A.}{Agrate Brianza}{Italy}{logo_st}{}
\cventrylogo{2004--2005}{Internship}{Alenia Spazio S.p.A.}{Turin}{Italy}{logo_tas}{}

결과는 다음과 같습니다.

여기에 이미지 설명을 입력하세요

이미 비슷한 질문을 본 적이 있는데,1그리고2, 그러나 이것은 정확히 내가 원하는 것이 아닙니다. 2가지 문제가 있습니다. 먼저 이미지가 아래쪽에 정렬되고 텍스트 중앙에 정렬되도록 하고 싶고 두 번째로 명령에서 이미지 크기를 지정할 수 있는 옵션이 있으면 좋겠지 \cventrylogo만 이를 구현하는 것은 내 능력을 벗어납니다. . 어떤 도움이라도 대단히 감사하겠습니다.


나는 MWE를 제공하는 Harish Kumar의 도움을 받아 이 질문에 직접 답했습니다.

답변1

이제 다음과 같이 정의된 명령을 사용하여 원하는 대로 작동합니다 \cventrylogo.

\renewcommand{\cventrylogo}[9][.25em]{% 
\cvitem[#1]{#2}{% 
  {\bfseries#3}% 
  \ifthenelse{\equal{#4}{}}{}{, {\slshape#4}}% 
  \ifthenelse{\equal{#5}{}}{}{, #5}% 
  \ifthenelse{\equal{#6}{}}{}{, #6.}% 
  \ifthenelse{\equal{#7}{}}{}{% 
    \ifthenelse{\equal{#8}{}}{}{\hfill \raisebox{-0.5\height}{\includegraphics[width=#8]{#7}}}}%
  \strut% 
  \ifx&#9&% 
    \else{\newline{}\begin{minipage}[t]{\linewidth}\small#9\end{minipage}}\fi} }

다음은 MWE를 사용할 수 있는 추가 참조용입니다.

\documentclass[11pt,a4paper,sans]{moderncv}
\moderncvstyle{classic}
\moderncvcolor{blue} 
\usepackage[utf8]{inputenc}

\usepackage[scale=0.8]{geometry} 

\name{Riccardo}{I.}
\title{Title title}
\address{XXX}{place ville}{}
\phone[mobile]{+00~(0)~00~000~00~00}    
\email{[email protected]} 

\begin{document}

\makecvtitle

\section{Experience}
\cventrylogo{2015}{Short Term Scientific Collaborator}{M\'et\'eosuisse}{Payerne}{Switzerland}{logo_meteosuisse}{16mm}{}
\cventrylogo{2009--2014}{PhD. in Physical Chemistry}{ETH}{Zurich}{Switzerland}{logo_eth}{25mm}{}
\cventrylogo{2006--2008}{Process Development Engineer}{STM S.p.A.}{Agrate Brianza}{Italy}{logo_st}{18mm}{}
\cventrylogo{2004--2005}{Internship}{Alenia Spazio S.p.A.}{Turin}{Italy}{logo_tas}{20mm}{}

\end{document}

관련 정보