[Tex/LaTex] Specification in `theorem` environment also bold

amsmathboldenvironmentstheorems

I'm using the following packages/options in my article:

\documentclass[b4paper,12pt]{article}   
\usepackage[english]{babel}
\usepackage{amssymb}                
\usepackage{amsmath}                
\usepackage{amsfonts}
\usepackage{amsthm}
\usepackage{hyperref}               
\usepackage{graphicx}
\usepackage{color}              

\newtheoremstyle{break}
   {\topsep}{\topsep}%
   {\itshape}{}%
   {\bfseries}{}%
   {\newline}{}% 
\theoremstyle{break}

\newtheorem{theorem}{Theorem}%[section]
\newtheorem{lemma}[theorem]{Lemma}
\newtheorem{proposition}[theorem]{Proposition}
\newtheorem{corollary}[theorem]{Corollary}
\newtheorem{definition}{Definition}

\begin{definition}[Test]
This is a test definition
\end{definition}

I would like to have the name (here 'Test') not only in parentheses but also boldface. How can I achieve that?

Thank you!

Best Answer

Your amsthm specification for the break theorem style should look like this:

\makeatletter
\newtheoremstyle{break}
   {\topsep}{\topsep}%
   {\itshape}{}%
   {\bfseries}{}%
   {\newline}
   {\thmname{#1}\thmnumber{\@ifnotempty{#1}{ }\@upn{#2}}%
    \thmnote{ {\bfseries(#3)}}}% 
\makeatother

The header is managed using the ninth argument. I've just copied it from the amsmath source and replaced the note font with \bfseries. If you leave it empty, it defaults to the plain theorem header style.

Here's your original MWE with the above modification:

enter image description here

\documentclass[12pt]{article}   
%\usepackage[english]{babel}
%\usepackage{amssymb}                
%\usepackage{amsmath}                
%\usepackage{amsfonts}
\usepackage{amsthm}% http://ctan.org/pkg/amsthm
%\usepackage{hyperref}               
%\usepackage{graphicx}
%\usepackage{color}              

\makeatletter
\newtheoremstyle{break}
   {\topsep}{\topsep}%
   {\itshape}{}%
   {\bfseries}{}%
   {\newline}
   {\thmname{#1}\thmnumber{\@ifnotempty{#1}{ }\@upn{#2}}%
    \thmnote{ {\bfseries(#3)}}}% 
\makeatother
\theoremstyle{break}

\newtheorem{theorem}{Theorem}%[section]
\newtheorem{lemma}[theorem]{Lemma}
\newtheorem{proposition}[theorem]{Proposition}
\newtheorem{corollary}[theorem]{Corollary}
\newtheorem{definition}{Definition}
\begin{document}
\begin{definition}[Test]
This is a test definition
\end{definition}
\end{document}
Related Question