I try to create a custom command \specialchapter
that works very similar to the normal \chapter
command, but uses it's own counter. And I would like for the section numbering under this ´\specialchapter` to
\chapter{Normal Chapter}
\section{Section}
\subsection{Subsection}
\specialchapter{Special Chapter}
\section{Section}
\subsection{Subsection}
\chapter{Normal Chapter}
\section{Section}
\subsection{Subsection}
should result in section numbering like this:
Chapter 1: Normal Chapter
1.1 Section
1.1.1 Subsection
Special 1: Special Chapter
S1.1 Section
S1.1.1 Subsection
Chapter 2: Normal Chapter
2.1 Section
2.1.1 Subsection
The idea is to have \specialchapter
on the same level as \chapter
but highlight sections in those chapters with a prefix letter to make the section numbering unambiguous.
I use KOMA-Script and tried
\DeclareNewSectionCommand[%
level=0,
style=chapter,
tocstyle=chapter,
tocindent=0pt,
toclevel=0,
tocnumwidth=1.5em,
beforeskip=0pt,
]{specialchapter}
\def\thespecialchapter{S\arabic{specialchapter}}%
This creates the chapter-like command, but the sections under this command continue their numbering from the last \chapter
command.