我正在使用 moderncv 撰写求职信。
当我编辑/创建文档时,我在\opening{}
和之间输入的文本\closing{}
会放在页面顶部。后面是地址和其他所有内容。
日志中写道:
Underfull \hbox (badness 10000) in paragraph.
但即使我将其写为一个连贯的文本,它也会像我上面解释的那样显示。
任何想法?
这里我试着举个例子。我使用空白的 moderncv 模板,上面提到的两个命令之间只输入了文本。没有其他内容。
\documentclass[11pt,a4paper,sans,english]{moderncv} % possible options include font size ('10pt', '11pt' and '12pt'), paper size ('a4paper', 'letterpaper', 'a5paper', 'legalpaper', 'executivepaper' and 'landscape') and font family ('sans' and 'roman')
\moderncvstyle{casual} % style options are 'casual' (default), 'classic', 'oldstyle' and 'banking'
\moderncvcolor{blue} % color options 'blue' (default), 'orange', 'green', 'red', 'purple', 'grey' and 'black'
%\nopagenumbers{} % uncomment to suppress automatic page numbering for CVs longer than one page
\usepackage[utf8]{inputenc} % if you are not using xelatex ou lualatex, replace by the encoding you are using
\usepackage[scale=0.75,a4paper]{geometry}
\usepackage{babel}
%----------------------------------------------------------------------------------
% personal data
%----------------------------------------------------------------------------------
\firstname{first name}
\familyname{family name}
\title{Resumé title} % optional, remove/comment the line if not wanted
\address{street and number}{postcode city}{country} % optional, remove/comment the line if not wanted; the "country" arguments can be omitted or provided empty
\mobile{mobile number} % optional, remove/comment the line if not wanted
\phone{phone number} % optional, remove/comment the line if not wanted
\fax{fax number} % optional, remove/comment the line if not wanted
\email{email} % optional, remove/comment the line if not wanted
\homepage{home page} % optional, remove/comment the line if not wanted
\extrainfo{additional information} % optional, remove/comment the line if not wanted
% \photo[64pt][0.4pt]{picture} % optional, uncomment the line if wanted; '64pt' is the height the picture must be resized to, 0.4pt is the thickness of the frame around it (put it to 0pt for no frame) and 'picture' is the name of the picture file
\quote{some quote} % optional, remove/comment the line if not wanted
%
\begin{document}
%----- letter ---------------------------------------------------------
% recipient data
\recipient{Company Recruitment team}{Company's name\\Street address\\Zip Code City}
\date{Date}
\opening{Dear Sir or Madam,}
Far curiosity incommode now led smallness allowance. Favour bed assure son things yet. She consisted consulted elsewhere happiness disposing household any old the. Widow downs you new shade drift hopes small. So otherwise commanded sweetness we improving. Instantly by daughters resembled unwilling principle so middleton. Fail most room even gone her end like. Comparison dissimilar unpleasant six compliment two unpleasing any add. Ashamed my company thought wishing colonel it prevent he in. Pretended residence are something far engrossed old off.\\
She suspicion dejection saw instantly. Well deny may real one told yet saw hard dear. Bed chief house rapid right the. Set noisy one state tears which. No girl oh part must fact high my he. Simplicity in excellence melancholy as remarkably discovered. Own partiality motionless was old excellence she inquietude contrasted. Sister giving so wicket cousin of an he rather marked. Of on game part body rich. Adapted mr savings venture it or comfort affixed friends.\\
Started his hearted any civilly. So me by marianne admitted speaking. Men bred fine call ask. Cease one miles truth day above seven. Suspicion sportsmen provision suffering mrs saw engrossed something. Snug soon he on plan in be dine some.\\
By an outlived insisted procured improved am. Paid hill fine ten now love even leaf. Supplied feelings mr of dissuade recurred no it offering honoured. Am of of in collecting devonshire favourable excellence. Her sixteen end ashamed cottage yet reached get hearing invited. Resources ourselves sweetness ye do no perfectly. Warmly warmth six one any wisdom. Family giving is pulled beauty chatty highly no. Blessing appetite domestic did mrs judgment rendered entirely. Highly indeed had garden not.\\
\closing{Yours faithfully,}
\enclosure{enclosures} % use an optional argument to use a string other than "Enclosure", or redefine \enclname
\makelettertitle
\makeletterclosing
\end{document}
答案1
你的简历结构应该是
\documentclass[<options>]{moderncv}
\moderncvstyle{<style>}
\moderncvcolor{<colour>}
% Various package choices
% Personal data (these things are used in the title/header/footer
\firstname{<first name>}
\lastname{<last name>}
% ...
\begin{document}
% Content for the CV letter
\recipient{<recipient information>}
\date{<date>}
\opening{<opening>}
\closing{<your closing>}
\enclosures{<enclosures>}
\makelettertitle
% Your letter
Lorem ipsum...
\makeletterclosing
\end{document}
以下是按上述顺序排列的输入:
\documentclass[11pt,a4paper,sans,english]{moderncv} % possible options include font size ('10pt', '11pt' and '12pt'), paper size ('a4paper', 'letterpaper', 'a5paper', 'legalpaper', 'executivepaper' and 'landscape') and font family ('sans' and 'roman')
\moderncvstyle{casual} % style options are 'casual' (default), 'classic', 'oldstyle' and 'banking'
\moderncvcolor{blue} % color options 'blue' (default), 'orange', 'green', 'red', 'purple', 'grey' and 'black'
%\nopagenumbers{} % uncomment to suppress automatic page numbering for CVs longer than one page
\usepackage[utf8]{inputenc} % if you are not using xelatex ou lualatex, replace by the encoding you are using
\usepackage[scale=0.75,a4paper]{geometry}
\usepackage{babel}
%----------------------------------------------------------------------------------
% personal data
%----------------------------------------------------------------------------------
\firstname{first name}
\familyname{family name}
\title{Resumé title} % optional, remove/comment the line if not wanted
\address{street and number}{postcode city}{country} % optional, remove/comment the line if not wanted; the "country" arguments can be omitted or provided empty
\mobile{mobile number} % optional, remove/comment the line if not wanted
\phone{phone number} % optional, remove/comment the line if not wanted
\fax{fax number} % optional, remove/comment the line if not wanted
\email{email} % optional, remove/comment the line if not wanted
\homepage{home page} % optional, remove/comment the line if not wanted
\extrainfo{additional information} % optional, remove/comment the line if not wanted
% \photo[64pt][0.4pt]{picture} % optional, uncomment the line if wanted; '64pt' is the height the picture must be resized to, 0.4pt is the thickness of the frame around it (put it to 0pt for no frame) and 'picture' is the name of the picture file
\quote{some quote} % optional, remove/comment the line if not wanted
%
\begin{document}
%----- letter ---------------------------------------------------------
% recipient data
\recipient{Company Recruitment team}{Company's name\\Street address\\Zip Code City}
\date{Date}
\opening{Dear Sir or Madam,}
\closing{Yours faithfully,}
\enclosure{enclosures} % use an optional argument to use a string other than "Enclosure", or redefine \enclname
\makelettertitle
Far curiosity incommode now led smallness allowance. Favour bed assure son things yet. She consisted consulted elsewhere happiness disposing household any old the. Widow downs you new shade drift hopes small. So otherwise commanded sweetness we improving. Instantly by daughters resembled unwilling principle so middleton. Fail most room even gone her end like. Comparison dissimilar unpleasant six compliment two unpleasing any add. Ashamed my company thought wishing colonel it prevent he in. Pretended residence are something far engrossed old off.\\
She suspicion dejection saw instantly. Well deny may real one told yet saw hard dear. Bed chief house rapid right the. Set noisy one state tears which. No girl oh part must fact high my he. Simplicity in excellence melancholy as remarkably discovered. Own partiality motionless was old excellence she inquietude contrasted. Sister giving so wicket cousin of an he rather marked. Of on game part body rich. Adapted mr savings venture it or comfort affixed friends.\\
Started his hearted any civilly. So me by marianne admitted speaking. Men bred fine call ask. Cease one miles truth day above seven. Suspicion sportsmen provision suffering mrs saw engrossed something. Snug soon he on plan in be dine some.\\
By an outlived insisted procured improved am. Paid hill fine ten now love even leaf. Supplied feelings mr of dissuade recurred no it offering honoured. Am of of in collecting devonshire favourable excellence. Her sixteen end ashamed cottage yet reached get hearing invited. Resources ourselves sweetness ye do no perfectly. Warmly warmth six one any wisdom. Family giving is pulled beauty chatty highly no. Blessing appetite domestic did mrs judgment rendered entirely. Highly indeed had garden not.\\
\makeletterclosing
\end{document}
以下是使用默认类生成的非常相似的输出article
。我认为代码呈现更清晰:
\documentclass{article}
\usepackage{geometry}
\geometry{hmargin=1in,top=.5in,bottom=1.5in,includeheadfoot}
\usepackage{fancyhdr,xcolor,fontawesome}
\usepackage{lipsum}% Just for this example
\pagestyle{fancy}
\fancyhf{}% Clear header/footer
\renewcommand{\headrulewidth}{0pt}% No header rule
\fancyfoot[C]{%
\color{black!55}% 55% black
\sffamily
\begin{tabular}{c}
\bfseries first name family name \\
\slshape street and number --- postal code --- country \\
{\Large\faMobile}~mobile number \quad $\bullet$ \quad
\faPhone~phone number \quad $\bullet$ \quad
{\small\faFax}~fax number \quad $\bullet$ \quad
{\small\faEnvelopeO}~email \\
{\small\faGlobe}~home page \quad $\bullet$ \quad additional information
\end{tabular}
}
\AtBeginDocument{\sffamily}
\setlength{\parindent}{0pt}% No paragraph indentation
\raggedright
\begin{document}
\begin{tabular}[t]{@{}l}
\bfseries Company Recruitment team \\
\slshape Company's name \\
\slshape Street address \\
\slshape Zip Code City
\end{tabular}\hfill
Date
\vspace{\baselineskip}
Dear Sir or Madam,
\vspace{\baselineskip}
\lipsum[1-3]
Yours faithfully,
\vspace{3\baselineskip}
{\bfseries first name family name}
\vspace{6\baselineskip}
\textcolor{black!55}{\slshape encl: enclosures}
\end{document}