I have a document in "book" format (strictly speaking, in an environment defined by the book publisher I am using, the details of which are way beyond my comprehension), and I very much want to have certain paragraphs labeled with the same running count as for theorems, lemmas, etc. but with the numerical label appearing as boldface within the text and not set off on its own line.
For example, between Theorem 2.3.7 and Theorem 2.3.9 within section 2.3 of Chapter 2, I'd like to be able to make some intermediate paragraph of my choosing begin with either "2.3.8" in boldface (and ordinary-size font), or perhaps "2.3.8 Blah-blah" in boldface (and ordinary-size font). It is also very important for this command to allow the possibility of using a \label
command associated to that numerical label "2.3.8" for cross-referencing purposes.
In order to increase the chances of a solution being usable by the book publisher (whose typesetting staff has been unable to provide me with a solution), please try to make answers as simple as possible.
Although I cannot reproduce the publishers proprietary documentclass
here (it is much too large, and incomprehensible to me), here is a test .tex
file that I tried based on the comment below suggesting to use the command \paragraph:
\documentclass{book}
\begin{document}
\chapter{A class of groups}
Let $G$ be a group.
\section{A class of subgroups}
Let $H$ be a subgroup.
\paragraph{Refinements}\label{refined} This can be refined.
In \ref{refined} we saw something.
\end{document}
The output that I get does not make any numerical label appear in front of "Refinements", and the cross-reference to it at the end produces the numerical label for the section, so it fails miserably. I want that labelled paragraph to begin with "1.1.1. Refinements" in boldface, and the cross-reference at the end should appear as "In 1.1.1 we saw something".
I should also point out that a version (given to me long ago from a source I cannot remember) does work within the amsart
environment, where the hierarchy shifts by one: instead of \chapter
, \section
, \subsection
it is \section
, \subsection
, \subsubsection
, and the following gives exactly what I seek as a subsubsection (but the publisher told me that they cannot adapt it; hmm, maybe I should specifically ask them to try replacing "subsubsection" with "subsection" below, in case they didn't try that?).
\makeatletter
\def\@seccntformat#1{\@ifundefined{#1@cntformat}%
{\csname the#1\endcsname\quad}% default
{\csname #1@cntformat\endcsname}% individual control
}
\def\subsubsection@cntformat{{\rm{\textbf{\thesubsubsection.}}}}
\makeatother
\documentclass{...}
and ending with\end{document}
.\subsection
between two theorems, having the number 2.3.8?\paragraph
rather thansubsection
, if the label number should be a leadin