Similar to this question here, how can I indent the chapter*
-like entries to the same indent as the numbered chapters?
section*
work with \KOMAoptions{toc=indentunnumbered}
.
The main difference to the other questions concerning indent with unnumbered chapter is related to indexes: The indentation of indexes won’t work with \addchap
/\addsec
etc.
\documentclass[ngerman,twoside=false,listof=totoc,listof=leveldown]{scrbook}
\usepackage{imakeidx}
\usepackage[style=archaeologie]{biblatex}
\addbibresource{archaeologie-examples.bib}
\usepackage{babel}
\newcommand\tocgobble[1]{}% <- added
\newcommand\tocpageseparator{\footnotesize\,\mbox{---}\,}
\newcommand\tocpagenumberbox[1]{\mbox{#1}}
\KOMAoptions{toc=indentunnumbered}%indent only for section* !?
\RedeclareSectionCommands[
tocraggedpagenumber,
toclinefill=\tocpageseparator,
tocindent=0em,
tocnumwidth=4em,
tocpagenumberbox=\tocpagenumberbox
]{chapter,section,subsection,subsubsection,paragraph}
\RedeclareSectionCommand[
tocentryformat=\large\scshape,
tocindent=0em,
tocnumwidth=4em,
tocpagenumberbox=\tocgobble
]{part}
\RedeclareSectionCommand[%
tocentryformat=\textbf%
]{chapter}
\makeindex[
intoc,
name=loc,
title={Locations},
columns=3,
]
\indexsetup{%
level=\section*,
toclevel=section,
noclearpage,
firstpagestyle=scrheadings,
headers={\indexname}{\indexname},
}
\begin{document}
\nocite{*}
\frontmatter
\tableofcontents
\mainmatter
\part{part}
\chapter{chapter chapter}
\section{section section section} \section{section section section} \section{section section section}
\part{part}
\chapter{chapter chapter}
\section{section section section} \section{section section section} \section{section section section}
\setcounter{page}{100}
\part{part}
\chapter{chapter chapter}
\section{section section section} \section{section section section} \section{section section section}
\backmatter
\part{part}
\index[loc]{A location}
\chapter*{Abbildungs-, Tabellen-, Tafelverzeichnis}
\addcontentsline{toc}{chapter}{Abbildungs-, Tabellen-, Tafelverzeichnis}
\listoffigures
\chapter*{\bibname}
\addcontentsline{toc}{chapter}{\bibname}
\printbiblist[%
heading=subbibintoc,%
title={Zeitschriftenabkürzungen}]{shortjournal}
\printbiblist[%
heading=subbibintoc,%
title={Reihenabkürzungen}]{shortseries}
\printbibliography[heading=subbibintoc]
\chapter*{Indizes}
\addcontentsline{toc}{chapter}{Indizes}
\printindex[loc]
\end{document}
\addchap{Indizes}
.