I would like to know how I can use single spacing (\singlespacing) in todonotes, considering Elsarticle Class, because I always get an error message about paragraph?
Following a minimal example:
%!Tex: LuaLaTeX
\documentclass[review,authoryear,3p]{elsarticle}
\usepackage{lipsum,setspace}
\usepackage[textwidth=1.7cm]{todonotes}
\journal{TUG}
\begin{document}
\begin{frontmatter}
\title{Doubt about LaTeX\tnoteref{Nota1}}
\tnotetext[Nota1]{This document was a collaborative effort.}
\author[Add1]{John Smith}
\ead{email@email.com}
\address[Add1]{TUG University}
\cortext[cor1]{Corresponding author}
\begin{abstract}
\lipsum[1]
\end{abstract}
\begin{keyword}
First word\sep Second word.
\end{keyword}
\end{frontmatter}
\section{Introduction}
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus at sapien vitae sapien ultricies sodales\todo{\tiny {\singlespacing Vivamus orci dui, posuere et suscipit placerat.}}.
Curabitur quam elit, tempus ut fringilla et, luctus sit amet nisl. Suspendisse mi odio, elementum quis blandit non, efficitur nec orci. Vivamus ullamcorper id justo quis posuere\todo{\tiny {\begin{spacing}{0.5} Vivamus orci dui, posuere et suscipit placerat.\end{spacing}}}.
\end{document}
Best Answer
No
setspace
: just use\linespread{1}
, but remember to add\par
at the end, or the paragraph would be set with the normal baselineskip.You may want to add a macro, say
so as to be able to write simply
A less hackish solution: