I'm using the titlesec package to format my (sub)section titles. I'd like to use the runin
option in \titleformat
to place my subsections titles within the first paragraph of each subsection. However, when I do this, I get extra spacing after the first line of each subsection. I've fiddled with the the options in \titlespacing
and none of them seem to fix the problem.
\documentclass[11pt]{article}
\usepackage{titlesec}
\titleformat{\section}{\normalfont\fontsize{11}{36}\bfseries}{\thesection.}{0.25em}{}
\titlespacing{\section}{0em}{-1.0em}{-2.0em} % {left}{before}{after}[right]
\renewcommand{\thesubsection}{\thesection.\alph{subsection}}
\titleformat{\subsection}[runin]{\normalfont\fontsize{11}{36}\bfseries\slshape}{\thesubsection.}{0.25em}{}
\titlespacing{\subsection}{0.0em}{0.0em}{0.5em} % {left}{before}{after}[right]
\linespread{1}
\begin{document}
\section{The first section}
\subsection{The first subsection within the first section:} Asdf asdf asdf asdf asdf asdf adsf asdf asdf asdf adf adf adsf adsf adsf asdf asdf asdf asd f. Wert qwer qwer qwer qwer qwer qwer qewr qewr erwq erw erw rewr rew re ewq ewr wqr qwer weq rqwe r re qwe reqw r ewe r we e w er qwe rq we rqwer qwer qw erq er qewr we are qew rq ew r ew. Hkjlkljj h jlkjh lkjlk jlhlkh lhkjljkj lklkk.
\subsection{The second subsection within the first section:} Asdf asdf asdf asdf asdf asdf adsf asdf asdf asdf adf adf adsf adsf adsf asdf asdf asdf asd f. Wert qwer qwer qwer qwer qwer qwer qewr qewr erwq erw erw rewr rew re ewq ewr wqr qwer weq rqwe r re qwe reqw r ewe r we e w er qwe rq we rqwer qwer qw erq er qewr we are qew rq ew r ew. Hkjlkljj h jlkjh lkjlk jlhlkh lhkjljkj lklkk.
\end{document}
Any suggestions?