1

I am writing a paper in the article class with a very long title. Here is an MWE:

\documentclass[12pt]{article}

\usepackage{fullpage}
\usepackage{setspace} 


\newcommand\e{\emph}
\newcommand\tb{\textbf}
\newcommand\un{\underline}
\newcommand\txt{\texttt}

\usepackage[left=1 in,top=1in,right=1 in,bottom=1in,includefoot]{geometry}

\usepackage{blindtext}

\usepackage[small]{titlesec}
\titleformat*{\section}{\normalsize\bfseries}
\titlespacing*{\section}{0pt}{1.1\baselineskip}{\baselineskip}
\titlespacing{\section}{0pt}{\parskip}{-\parskip}

\title{\vspace{-7ex}\tb{\large A very very very very very very very very very very very very very very very very very very long title}\vspace{-7ex}}
\author{}
\date{}



\begin{document}

    \maketitle 

    \blindtext

\end{document}

Here is the output

enter image description here

How can I close the gap between the title so that the title is more single-spaced like the rest of the document?

Before posting this question, I've consulted different Stack Exchange threads about narrowing the gap between chapter titles but none of the solutions there have worked for me.

Thank you!

2

1 Answer 1

2

You can obtain what you want with the titling package, which provides tools to customise the \maketitle command and using \setstretch:

\documentclass[12pt]{article}

\usepackage{fullpage}
\usepackage{setspace}

\newcommand\e{\emph}
\newcommand\tb{\textbf}
\newcommand\un{\underline}
\newcommand\txt{\texttt}

\usepackage[margin=1in,includefoot]{geometry}

\usepackage{blindtext}

\usepackage[small]{titlesec}
\titleformat*{\section}{\normalsize\bfseries}
\titlespacing*{\section}{0pt}{1.1\baselineskip}{\baselineskip}
\titlespacing{\section}{0pt}{\parskip}{-\parskip}

\usepackage{titling}

\setlength{\droptitle}{-9.5ex}
 \pretitle{\begin{center}\large\bfseries\setstretch{0.5}}
 \posttitle{\par\end{center}\leavevmode\vspace*{-5.4ex}}%\

\title{A very very very very very very very very very very very very very very very very very very long title\vspace{-7ex}}
\author{}
\date{}

\begin{document}

    \maketitle

    \blindtext

\end{document} 

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.