Page 1, lines 11-12 of the lineno states:
lineno.sty can only number lines in the main text. Lines in any kind of boxes cannot be numbered. But see section 7.4 below.
The AMS class file typesets the abstract as part of the title page, but the abstract is specified using an environment. So it has to slurp in the text and save it for reuse. It does that by using a box, precisely the situation that lineno.sty
warns us against.
Section 7.4 may help but it is not a true numbering: it describes an extension of lineno.sty
that simply typesets a list of numbers down the left in the vague hope that they will line up correctly with the lines in the box.
So to answer your question: No, I have no suggestions! Other than to ask, do you really need your abstract to have line numbers?
Okay, I do have a suggestion.
\documentclass{amsart}
\usepackage{lipsum}
\usepackage{lineno}
\makeatletter
\let\my@abstract=\relax
\def\abstract#1{%
\def\my@abstract{%
\normalfont\Small
\list{}{\labelwidth\z@
\leftmargin3pc \rightmargin\leftmargin
\listparindent\normalparindent \itemindent\z@
\parsep\z@ \@plus\p@
\let\fullwidthdisplay\relax
}%
\item[\hskip\labelsep\scshape\abstractname.]%
#1
\endlist}}
\def\@setabstracta{%
\ifx\my@abstract\relax
\else
\skip@20\p@ \advance\skip@-\lastskip
\advance\skip@-\baselineskip \vskip\skip@
\my@abstract
\prevdepth\z@ % because \abstractbox is a vtop
\fi
}
\makeatother
\linenumbers
\begin{document}
\title{Line numbering and amsart}
\abstract{%
\lipsum[1]}
\maketitle
\lipsum[2]
\end{document}
I don't particularly recommend it, and it needs a little adjusting to get the spacing right above and below. Basically, it reimplements the amsart abstract handling without using a box. It's ugly, it's hacky, and it probably just sent a coded signal to the AMS which will get me on their naughty list for years to come. But it does number the lines of the abstract and, apart from the spacing, it looks right.
indentfirst
,hyperref
andshowkeys
aren't needed), but it does show the problem. I'm out of votes for today, but will upvote your question tomorrow.