以下信件文件没有显示电子邮件地址,这应该由命令触发
\setkomavar{fromemail}{[email protected]}
以下是全文
\documentclass[
fontsize=11pt,
paper=a4,
parskip=half,
enlargefirstpage=on, % More space on first page
fromalign=right, % PLacement of name in letter head
fromphone=on, % Turn on phone number of sender
fromrule=aftername, % Rule after sender name in letter head
addrfield=on, % Adress field for envelope with window
backaddress=on, % Sender address in this window
subject=beforeopening, % Placement of subject
locfield=narrow, % Additional field for sender
foldmarks=on, % Print foldmarks
]{scrlttr2}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[english]{babel}
\usepackage{blindtext}
\setkomafont{fromname}{\sffamily \LARGE}
\setkomafont{fromaddress}{\sffamily}%% statt \small
\setkomafont{pagenumber}{\sffamily}
\setkomafont{subject}{\bfseries}
\setkomafont{backaddress}{\mdseries}
\LoadLetterOption{DIN}
\setkomavar{fromname}{Mario Rossi}
\setkomavar{fromaddress}{Via Roma 2,\\Frascati}
\setkomavar{fromphone}{+39 \,00\,00\,00\,000}
\setkomavar{fromemail}{[email protected]} % NON VIENE VISUALIZZATA
\setkomavar{backaddressseparator}{\enspace\textperiodcentered\enspace}
\setkomavar{signature}{(Mario Rossi)}
\setkomavar{place}{Frascati}
\setkomavar{date}{\today}
\setkomavar{enclseparator}{: }
\begin{document}
\begin{letter}{To: Claire Laterfield}
\setkomavar{subject}{Greetings}
\opening{Dear Claire,}
I am writing this letter because I have nothing better to do.
\closing{Sincerely,}
\end{letter}
\end{document}
答案1
只需将类选项fromemail=true,
或添加fromemail=on,
到您的代码中。
梅威瑟:
\documentclass[
fontsize=11pt,
paper=a4,
parskip=half,
enlargefirstpage=on, % More space on first page
fromalign=right, % PLacement of name in letter head
fromphone=on, % Turn on phone number of sender
fromrule=aftername, % Rule after sender name in letter head
fromemail=on, % <===========================================
addrfield=on, % Adress field for envelope with window
backaddress=on, % Sender address in this window
subject=beforeopening, % Placement of subject
locfield=narrow, % Additional field for sender
foldmarks=on, % Print foldmarks
]{scrlttr2}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[english]{babel}
\usepackage{blindtext}
\setkomafont{fromname}{\sffamily \LARGE}
\setkomafont{fromaddress}{\sffamily}%% statt \small
\setkomafont{pagenumber}{\sffamily}
\setkomafont{subject}{\bfseries}
\setkomafont{backaddress}{\mdseries}
\LoadLetterOption{DIN}
\setkomavar{fromname}{Mario Rossi}
\setkomavar{fromaddress}{Via Roma 2,\\Frascati}
\setkomavar{fromphone}{+39 \,00\,00\,00\,000}
\setkomavar{fromemail}{[email protected]} % NON VIENE VISUALIZZATA
\setkomavar{backaddressseparator}{\enspace\textperiodcentered\enspace}
\setkomavar{signature}{(Mario Rossi)}
\setkomavar{place}{Frascati}
\setkomavar{date}{\today}
\setkomavar{enclseparator}{: }
\begin{document}
\begin{letter}{To: Claire Laterfield}
\setkomavar{subject}{Greetings}
\opening{Dear Claire,}
I am writing this letter because I have nothing better to do.
\closing{Sincerely,}
\end{letter}
\end{document}
并查看结果: