0

Following is the code for a self-defined list environment "Miscellaneous Examples"

\usepackage{amsthm}
\usepackage[inline]{enumitem}
\usepackage{xifthen}
\newtheoremstyle{mydefnstyle}{3ex}{3ex}{}{}{\bfseries}{:}{.5em}{}
\theoremstyle{mydefnstyle}
\newtheorem*{misc}{Miscellaneous Examples}

\newenvironment{Misc}[1][]
{%
    \ifthenelse{\isempty{#1}}{\begin{misc}}{\begin{misc}[#1]}
    \leavevmode\vspace{-1ex}
    \begin{enumerate}[label=\thechapter.\arabic*., font=\bfseries, ref=\thechapter.\arabic*, itemsep=1.5ex]
        }
        {
    \end{enumerate}
    \end{misc}
}

While writing a book, this environment is called a number of times. What I need is to continue the numbering over different appearances in the same chapter. Precisely what I want is the following:

\chapter{title}
\begin{Misc}
    \item Bla
\end{Misc}

\begin{Misc}[continued]
    \item Bla
\end{Misc}

should generate

Miscellaneous Examples

1.1. Bla

Miscellaneous Examples (continued)

1.2. Bla

The presence of the note/comment [continued] should not have any effect on the numbering. How do I achieve this?

4
  • tex.stackexchange.com/questions/1669/resuming-a-list might help. Please provide an MWE so we could help you more easily.
    – Sango
    Commented Mar 3, 2020 at 8:25
  • @schtandard, not really. Because I have other enumerated lists before the reappearance of the same environment. Commented Mar 3, 2020 at 8:40
  • @Sango your suggestion seems fine. But is there any way to include this inside the definition of the environment? Also, I have added an MWE. Commented Mar 3, 2020 at 8:44
  • In one of the answers there (tex.stackexchange.com/a/230004) the counter settings are done within the environment definition, this should also work in combination with enumitem options.
    – Marijn
    Commented Mar 3, 2020 at 9:02

0

Browse other questions tagged .