1

I want to override the \maketitle command, but I get a warning that no \author is given.

\documentclass[11pt]{amsart}
\title{test}
\author{Aleksandr Kozlovskiy}
\date{\today}
\thanks{This document  was printted in LaTex by Aleksandr Kozlovskiy from minsk.}
\makeatletter
\def\maketitle{
\textbf{\@title}
\textit{\@author}
\text{\@thanks}
}
\makeatother
\begin{document}
\maketitle
this is a test document
\end{document}
1

AMS classes store the author (and thanks) in a different macro:

\documentclass[11pt]{amsart}
\title{test}
\author{Aleksandr Kozlovskiy}
\date{\today}
\thanks{This document  was printted in LaTex by Aleksandr Kozlovskiy from minsk.}
\makeatletter
\def\maketitle{
\textbf{\@title}
\textit{\authors}
\def\thanks##1{##1\par}
\text{\thankses}
}
\makeatother
\begin{document}
\maketitle
this is a test document
\end{document}
  • Thanks very mutch for your help,but it very interesting for me,why in several examples to override \maketitle people use \@author command? – Aleksandr Kozlovskiy May 23 at 16:13
  • @AleksandrKozlovskiy the standard article, report, book, classes uses \@author but it is not a documented interface that is just the internal macro those classes use, and ams classes set up the frontmatter differently. – David Carlisle May 23 at 16:20

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.