这是我的代码,它会自动在“Intern - Technology”位后面放置一个冒号,我该如何覆盖并摆脱它?
\cvitemwithcomment{\normalfont{HSBC, London,} \textbf{Intern - Technology Division}}{}{\normalfont{Jun--August 2015}}
\begin{itemize}
\item
\vspace{2mm}
\end{itemize}
这是我正在使用的课程:
\documentclass[10pt,a4paper,sans]{moderncv}
\moderncvstyle{banking}
\moderncvcolor{black}
\usepackage[utf8]{inputenc}
\usepackage[scale=0.8]{geometry}
答案1
无需重新定义\cvitemwithcomment
,您可以捕获:
并将其删除:
\documentclass{moderncv}
\moderncvstyle{banking}
\firstname{First}
\lastname{Lastname}
\let\oldcvitemwithcomment\cvitemwithcomment
\let\oldhintstyle\hintstyle
\renewcommand{\cvitemwithcomment}[4]{{%
\renewcommand*{\hintstyle}[2]{\oldhintstyle{##1}}%
\oldcvitemwithcomment{#1}{#2}{#3}{#4}%
}}
\begin{document}
\cvitemwithcomment
{{\normalfont HSBC, London,} \textbf{Intern - Technology Division}}
{}
{{\normalfont Jun--August 2015}}
\end{document}
\cvitemwithcomment
这是插入的:
第一行可见的原始定义:
\renewcommand*{\cvitemwithcomment}[4][.25em]{%
\savebox{\cvitemwithcommentmainbox}{\ifthenelse{\equal{#2}{}}{}{\hintstyle{#2}: }#3}%
\setlength{\cvitemwithcommentmainlength}{\widthof{\usebox{\cvitemwithcommentmainbox}}}%
\setlength{\cvitemwithcommentcommentlength}{\maincolumnwidth-\separatorcolumnwidth-\cvitemwithcommentmainlength}%
\begin{minipage}[t]{\cvitemwithcommentmainlength}\usebox{\cvitemwithcommentmainbox}\end{minipage}%
\hfill% fill of \separatorcolumnwidth
\begin{minipage}[t]{\cvitemwithcommentcommentlength}\raggedleft\small\itshape#4\end{minipage}%
\par\addvspace{#1}}
您可以根据您的需要进行更改,并在加载您选择的样式后将生成的代码添加到您的序言中。