我的代码如下:
% Source: http://tex.stackexchange.com/a/5374/23931
\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[margin=1in]{geometry}
\usepackage{xcolor} % Add the xcolor package
\usepackage{biblatex} %Imports biblatex package
\addbibresource{papers.bib} %Import the bibliography file
\usepackage{hyperref}
\hypersetup{
colorlinks,
citecolor=green,
linkcolor=blue,
urlcolor=blue
}
\newcommand{\HRule}{\rule{\linewidth}{0.5mm}}
\newcommand{\Hrule}{\rule{\linewidth}{0.3mm}}
\makeatletter% since there's an at-sign (@) in the command name
\renewcommand{\@maketitle}{%
\parindent=0pt% don't indent paragraphs in the title block
\centering
{\Large \bfseries\textsc{\@title}}
\HRule\par%
\textit{\@author \hfill \@date}
\par
}
\makeatother% resets the meaning of the at-sign (@)
\title{Statement of Purpose}
\author{\textcolor{blue}{ \textbf{Tim hammerberg}}}
\date{\textcolor{blue}{ \textbf{hammerberg.github.io}}}
\begin{document}
\maketitle% prints the title block
\vspace{0.4em}
Recent breakthroughs in natural language processing (NLP) have unlocked remarkable capabilities. However, there are still core limitations concerning efficiency.
\end{document}
我想要 Tim hammerberg 和 hammerberg.github.io 就在上面,怎么做?
答案1
\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[margin=1in]{geometry}
\usepackage{xcolor} % Add the xcolor package
\usepackage{biblatex} %Imports biblatex package
\addbibresource{papers.bib} %Import the bibliography file
\usepackage{hyperref}
\hypersetup{
colorlinks,
citecolor=green,
linkcolor=blue,
urlcolor=blue
}
\newcommand{\HRule}{\rule{\linewidth}{0.5mm}}
\newcommand{\Hrule}{\rule{\linewidth}{0.3mm}}
\makeatletter% since there's an at-sign (@) in the command name
\renewcommand{\@maketitle}{%
\parindent=0pt% don't indent paragraphs in the title block
\centering
{\Large \bfseries\textsc{\@title}}\par%
\textit{\@author \hfill \@date}\par%
\HRule%
% \par
}
\makeatother% resets the meaning of the at-sign (@)
\title{Statement of Purpose}
\author{\textcolor{blue}{ \textbf{Tim hammerberg \vspace{-2ex}}}}
\date{\textcolor{blue}{ \textbf{hammerberg.github.io}}}
\begin{document}
\maketitle% prints the title block
\vspace{0.8em}
Recent breakthroughs in natural language processing (NLP) have unlocked remarkable capabilities. However, there are still core limitations concerning efficiency.
\end{document}
编辑要删除标题前的间距,请将几何形状更改为
\usepackage[margin=0.5in]{geometry}
平均能量损失
\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage[margin=0.5in]{geometry}
\usepackage{xcolor} % Add the xcolor package
\usepackage{biblatex} %Imports biblatex package
\addbibresource{papers.bib} %Import the bibliography file
\usepackage{hyperref}
\usepackage{titling}
\hypersetup{
colorlinks,
citecolor=green,
linkcolor=blue,
urlcolor=blue
}
\newcommand{\HRule}{\rule{\linewidth}{0.5mm}}
\newcommand{\Hrule}{\rule{\linewidth}{0.3mm}}
\makeatletter% since there's an at-sign (@) in the command name
\renewcommand{\@maketitle}{%
\parindent=0pt% don't indent paragraphs in the title block
\centering
\setlength{\droptitle}{-3cm}
{\Large \bfseries\textsc{\@title}}\par%
\textit{\@author \hfill \@date}\par%
\HRule%
% \par
}
\makeatother% resets the meaning of the at-sign (@)
\title{Statement of Purpose }
\author{\textcolor{blue}{ \textbf{Tim hammerberg \vspace{-2ex}}}}
\date{\textcolor{blue}{ \textbf{hammerberg.github.io}}}
\begin{document}
\maketitle% prints the title block
\vspace{0.8em}
Recent breakthroughs in natural language processing (NLP) have unlocked remarkable capabilities. However, there are still core limitations concerning efficiency.
\end{document}
输出