TransWikia.com

Remove period at the end of section numbers in amsart

TeX - LaTeX Asked on June 22, 2021

For instance, amsart formats a subsection number as 1.2. but I want 1.2, as in the standard article class.

These questions ask how to remove the period following the heading (nopunct), but I have been unable to find anything on removing the period after the number.

MWE:

documentclass{amsart}
begin{document}
tableofcontents

section{$leftarrow$ I'd like to remove this period}

subsection{$leftarrow$ And this one too}

subsubsection{$leftarrow$ This one as well}

end{document}

One Answer

enter image description here

documentclass{amsart}
makeatletter
def@seccntformat#1{%
  protecttextup{protect@secnumfont
    csname the#1endcsname
%%%    protect@secnumpunct
space
  }%
}


renewcommand{tocsection}[3]{%
  indentlabel{@ifnotempty{#2}{ignorespaces#1 #2%.
     quad}}#3}
lettocsubsectiontocsection
lettocsubsubsectiontocsection

makeatother
begin{document}
tableofcontents

section{$leftarrow$ I'd like to remove this period}

subsection{$leftarrow$ And this one too}

subsubsection{$leftarrow$ This one as well}

end{document}

Correct answer by David Carlisle on June 22, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP