在moderncv
,我添加了一行
\extrainfo{\faPassport~MyNationality}
回到序言。
我怎样才能让这些信息仅出现在简历中而不出现在求职信中?
按照这个答案,这应该可以通过
\makeatletter
\let\@extrainfo\relax
\makeatother
然而,这@extrainfo
在求职信和简历上都消失了。
我尝试通过以下方式修复此问题
\begingroup
\makeatletter
\let\@extrainfo\relax
\makeatother
\makelettertitle
\endgroup
但是,这似乎会覆盖其他格式设置:左对齐的封面信文本将变为两端对齐。不过,我想保留此默认设置。
梅威瑟:
\documentclass[11pt,a4paper,sans]{moderncv}
\moderncvstyle{classic}
\moderncvcolor{blue}
\moderncvicons{awesome}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc} % encoding
\usepackage[USenglish]{babel} % language
\usepackage[
a4paper,
left=25mm,
right=20mm,
top=20mm,
bottom=20mm
]{geometry} % specify margins
\firstname{FirstName}
\familyname{LastName}
\title{ProfileTitle}
\address{Street}{ZIP}{City}
\extrainfo{\faPassport~Nationality}
\mobile{\href{tel:+123456789}{+123456789}}
\email{[email protected]}
\social[linkedin][www.linkedin.com/in/some-page]{some-page}
\begin{document}
\recipient{Copmany}{
Street\\
ZIP City\\
Country
}
\date{\today}
\opening{Dear Sir or Madam:}
\closing{Sincerely,}
\begingroup
\makeatletter
% remove extrainfo from cover letter
\let\@extrainfo\relax
\makeatother
% create letter title
\makelettertitle
\endgroup
Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.
Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi. Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.
Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipit lobortis nisl ut aliquip ex ea commodo consequat. Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi.
\makeletterclosing
\newpage
\makecvtitle
\end{document}
答案1
\extrainfo
在之前 添加唯一\makecvtitle
\documentclass[11pt,a4paper,sans]{moderncv}
\moderncvstyle{classic}
\moderncvcolor{blue}
\moderncvicons{awesome}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc} % encoding
\usepackage[USenglish]{babel} % language
\usepackage[
a4paper,
left=25mm,
right=20mm,
top=20mm,
bottom=20mm
]{geometry} % specify margins
\firstname{FirstName}
\familyname{LastName}
\title{ProfileTitle}
\address{Street}{ZIP}{City}
%\extrainfo{\faPassport~Nationality} % NOT HERE <<<<<<<<<<<<<
\mobile{\href{tel:+123456789}{+123456789}}
\email{[email protected]}
\social[linkedin][www.linkedin.com/in/some-page]{some-page}
\begin{document}
\recipient{Copmany}{
Street\\
ZIP City\\
Country
}
\date{\today}
\opening{Dear Sir or Madam:}
\closing{Sincerely,}
\makelettertitle
Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.
Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi. Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.
Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipit lobortis nisl ut aliquip ex ea commodo consequat. Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi.
\makeletterclosing
\newpage
\extrainfo{\faPassport~Nationality} % added <<<<<<<<<<<
\makecvtitle
\end{document}