4

I'm currently working with the apxproof package and I'm having some minor trouble with it... Consider the following MWE:

\documentclass{article}
\usepackage{amsthm}
\usepackage{apxproof}

\theoremstyle{definition}
\newtheorem{definition}{Definition}

\begin{document}

\begin{definition}[Some test title] Some other nonsense.
\end{definition}

\end{document}

which produces this enter image description here but what I actually would want is enter image description here If I comment out the line with \usepackage{apxproof} I get what I want, but I'm obviously not able any more to use the package... So, is there a way to keep using the package and make the title of the Definitions (and Theorems etc.) appear as defined in \theoremstyle command?

Sito
  • 681

1 Answers1

4

The apxproof package does

\AtBeginDocument{%
  \def\thmhead#1#2#3{%
    \thmname{#1}\thmnumber{\@ifnotempty{#1}{ }\@upn{#2}}%
    \thmnote{ #3}}%
}

which is the cause of the issue.

\documentclass{article}
\usepackage{amsthm}
\usepackage{apxproof}

\theoremstyle{definition}
\newtheoremrep{definition}{Definition}

\makeatletter
\AtBeginDocument{%
  \def\thmhead#1#2#3{%
    \thmname{#1}\thmnumber{\@ifnotempty{#1}{ }\@upn{#2}}%
    \thmnote{ {\normalfont (#3)}}}%
}
\makeatother

\begin{document}

\begin{definition}[Some test title]
Some other nonsense.
\end{definition}

\end{document}

enter image description here

egreg
  • 1,121,712