1

I'm trying to put the List of Figures into the toc, but everything I tried does not work.

My main.tex file:

\documentclass[
        a4paper,
        11pt,
        parskip=half-,
        oneside,
        listof=totoc,
        bibtotocnumbered,
        headings=big,
        appendixprefix=true
    ]{scrreprt}

\usepackage[utf8]{inputenc}
\usepackage[ngerman, english]{babel}


% Bearbeitungsdatum
\date{\today}

\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage{tocloft}
\usepackage{interfaces}
\usepackage{setspace}
\usepackage[page]{appendix}
\addto\captionsngerman{\let\appendixpagename\appendixname}

\begin{document}    
\selectlanguage{ngerman}
\pagenumbering{Roman}
\PartEinleitung
Some beginning text
\tocsetup{
    title/font = \huge\color{blue},
    part/font = \large\bfseries\color{blue},
    part/number/width=8mm,
    part/number/after = .,
    chapter/number/after = .,
    chapter/indent=8mm,
    chapter/number/width=8mm,   
    section/number/after = .,
    section/indent = 16mm,
    section/number/width=10mm,
    subsection/indent=26mm,
    subsection/number/after = .,
    subsection/number/width=10mm,
    subsubsection/indent=36mm,
    subsubsection/number/after = .,
    subsubsection/number/width=13mm
}
\listofsetup{lot}{
    parskip=0cm,
    title/font = \huge\color{blue},
    table/number/after = .,
    table/number/width=13mm,
}   
\listofsetup{lof}{
    parskip=0cm,
    title/font = \huge\color{blue},
    figure/number/after = .,    
    figure/number/width=13mm
}
\renewcommand{\contentsname}{Inhaltsverzeichnis}
\pdfbookmark[0]{Inhaltsverzeichnis}{pdfinhaltsverzeichnis}
\tableofcontents
\label{LastPageEinleitung}
\clearpage
\cleardoublepage

\PartHauptteil
\pagenumbering{arabic}
Some Text included by "include commands"
\listoftables
\listoffigures
\printbibliography
\label{LastPageHauptteil}
\cleardoublepage

\pagenumbering{Alph}
\PartAppendix
\appendix
\begin{appendices}
    \label{LastPageAppendix}
\end{appendices}
\end{document}

The Bibliograpie shows up in the toc, but not the list of figures... \listoffigures does also not create a chapter or something like that, since the \headmark does not change on the page with the list of figures.

  • Use bibliography=numbered instead the deprecated bibtotocnumbered to avoid a warning and the switch to version=first. – esdd Mar 14 '18 at 19:48
4

You should use the titles option of the tocloft package. It solves both issues in one shot. BUT: It would be better if you set up your document using the KOMA-script interfaces to change title formats and ToCs. This way you wouldn't have such issues.

\documentclass[
        a4paper,
        11pt,
        parskip=half-,
        oneside,
        listof=totoc,
        bibtotocnumbered,
        headings=big,
        appendixprefix=true
    ]{scrreprt}

\usepackage[utf8]{inputenc}
\usepackage[ngerman, english]{babel}


% Bearbeitungsdatum
\date{\today}

\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage[titles]{tocloft}
\usepackage{interfaces}
\usepackage{setspace}
\usepackage[page]{appendix}
\addto\captionsngerman{\let\appendixpagename\appendixname}

\usepackage{blindtext}% for dummy text

\begin{document}    
\selectlanguage{ngerman}
\pagenumbering{Roman}
Some beginning text
\tocsetup{
    title/font = \huge\color{blue},
    part/font = \large\bfseries\color{blue},
    part/number/width=8mm,
    part/number/after = .,
    chapter/number/after = .,
    chapter/indent=8mm,
    chapter/number/width=8mm,   
    section/number/after = .,
    section/indent = 16mm,
    section/number/width=10mm,
    subsection/indent=26mm,
    subsection/number/after = .,
    subsection/number/width=10mm,
    subsubsection/indent=36mm,
    subsubsection/number/after = .,
    subsubsection/number/width=13mm
}
\listofsetup{lot}{
    parskip=0cm,
    title/font = \huge\color{blue},
    table/number/after = .,
    table/number/width=13mm,
}   
\listofsetup{lof}{
    parskip=0cm,
    title/font = \huge\color{blue},
    figure/number/after = .,    
    figure/number/width=13mm
}
\renewcommand{\contentsname}{Inhaltsverzeichnis}
\tableofcontents
\label{LastPageEinleitung}
\clearpage
\cleardoublepage

\pagenumbering{arabic}
Some Text included by "include commands"
\listoftables
\listoffigures
\label{LastPageHauptteil}
\cleardoublepage
\Blinddocument

\pagenumbering{Alph}
\appendix
\begin{appendices}
    \label{LastPageAppendix}
\end{appendices}
\end{document}

How you could get your stuff done using only KOMA-script:

\documentclass[
        a4paper,
        11pt,
        parskip=half-,
        oneside,
        listof=totoc,
        bibliography=numbered,
        headings=big,
        appendixprefix=true
    ]{scrreprt}

\usepackage{xcolor}

\usepackage{blindtext}% for dummy text

\setkomafont{partentry}{\large\bfseries\color{blue}}
\RedeclareSectionCommand
  [%
    ,tocnumwidth=8mm
  ]{part}
\RedeclareSectionCommand
  [%
    ,tocindent=8mm
    ,tocnumwidth=8mm
  ]{chapter}
\RedeclareSectionCommand
  [%
    ,tocindent=16mm
    ,tocnumwidth=10mm
  ]{section}
\RedeclareSectionCommand
  [%
    ,tocindent=26mm
    ,tocnumwidth=10mm
  ]{subsection}
\RedeclareSectionCommand
  [%
    ,tocindent=36mm
    ,tocnumwidth=13mm
  ]{subsubsection}
\DeclareTOCStyleEntry
  [%
    numwidth=13mm
  ]{tocline}{figure}
\DeclareTOCStyleEntry
  [%
    numwidth=13mm
  ]{tocline}{table}

\BeforeTOCHead{\addtokomafont{chapter}{\huge\color{blue}}}

\begin{document}    
\pagenumbering{Roman}
Some beginning text
\renewcommand{\contentsname}{Inhaltsverzeichnis}
\tableofcontents
\cleardoublepage

\part{FOOOBAR}
\pagenumbering{arabic}
Some Text included by "include commands"
\listoftables
\listoffigures
\cleardoublepage
\Blinddocument
\captionof{figure}{foobar}
\captionof{table}{foobar}
\end{document}
  • Great, thanks, I'll keep it in mind for the next project! – the_dani Mar 6 '18 at 21:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.