7

How can I change the \begin{proof} environment so that the word Proof which is displayed in my document isn't italic? I tried changing \proofname, but that only changes the displayed text, not the style.

1
  • Welcome to TeX.SX! It is easier to help you if you add a minimal working example that takes the form \documentclass{...}\usepackage{....}\begin{document}...\end{document}. If possible, it should compile and have the minimum amount of code needed to illustrate your problem. This makes it much easier for people to help you - and much more likely that they will! If you are using the amsthm package then \begin{proof}[\textbf{Proof}]...\end{proof} should put proof in bold.
    – user30471
    Jun 20, 2015 at 12:36

1 Answer 1

7

I assume you're talking about proof as defined by amsthm. The command \itshape is hardwired in the environment's definition.

I suggest patching it so it uses a “generic” command that you can redefine at will:

\usepackage{amsthm}
\usepackage{xpatch}
\xpatchcmd{\proof}{\itshape}{\normalfont\proofnamefont}{}{}

\newcommand{\proofnamefont}{} % add nothing

Full example. The \renewcommand is just for testing.

\documentclass{article}

\usepackage{amsthm}
\usepackage{xpatch}
\xpatchcmd{\proof}{\itshape}{\normalfont\proofnamefont}{}{}

\newcommand{\proofnamefont}{}

\begin{document}

\begin{proof}
Obvious, isn't it?
\end{proof}

\renewcommand{\proofnamefont}{\bfseries}

\begin{proof}[Proof in boldface]
Test for boldface and the optional argument.
\end{proof}

\end{document}

enter image description here

Just to clear up things: if you want boldface, the code should be

\documentclass{article}

\usepackage{amsthm}
\usepackage{xpatch}
\xpatchcmd{\proof}{\itshape}{\normalfont\proofnamefont}{}{}

\newcommand{\proofnamefont}{\bfseries}

\begin{document}

\begin{proof}
Obvious, isn't it?
\end{proof}

\end{document}
3
  • @Nicholas I added the amsthm tag, so surely our friend Barbara Beeton will take notice of the feature request.
    – egreg
    Jun 20, 2015 at 12:47
  • request posted, but as a request to add \proofnamefont rather than hard-coded \itshape. in fact, there is a generic request on file to reconsider all hard-coded font settings (except perhaps for italic for the basic theorem environment, although even there i know some people who prefer slanted type). Jun 20, 2015 at 14:39
  • @barbarabeeton I have no objection to just \proofnamefont.
    – egreg
    Jun 20, 2015 at 14:41

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.