Sie sind hier

Klassenoption parskip=half- scheint sich nicht mit Paket titletoc zu vertragen

Hallo zusammen,

Der Code unten tut schon genau was er soll, naemlich ein Inhaltsverzeichnis fuer jede Section zu machen (mit titletoc). Allerdings ist mir aufgefallen dass der vertikale Zwischenraum der "mini-tocs" deutlich groesser ist als beim globalen Inhaltsverzeichnis am Anfang. Eine Suche ergab, dass der Zwischenraum wieder "richtig" ist, wenn ich die Option "parskip=half-" auskommentiere. Wie kann ich diese Option verwenden ohne dass der Zwischenraum in den "mini-tocs" beeinflusst wird. Ist das ein Bug bei titletoc?

Viele Gruesse,

Marius

\documentclass[
paper=128mm:96mm,% like beamer
pagesize,% write page size to dvi or pdf
parskip=half-,% paragraphs are separated by half a line, no special marking of line endings
numbers=noendperiod,% removes points for special parts (e.g. appendix)
captions=nooneline% do not distinguish between one or more lines in captions
]{scrartcl}
\linespread{1.12}% enlarge line space
 
% font stuff
\usepackage[T1]{fontenc}% for correct hyphenation and T1 encoding
\usepackage{lmodern}
\renewcommand{\familydefault}{\sfdefault}% text [not math] will be sans serif (CM-Sans)
\usepackage[american]{babel}% for American English
% \usepackage{microtype}% for character protrusion and font expansion (only with pdflatex)
 
% page structure
\usepackage{calc}% working with lengths, counters etc.
\usepackage[includefoot,top=5.5mm,bottom=4.5mm,left=5.5mm,right=5.5mm,footskip=4mm]{geometry}% set page layout parameters
\usepackage{scrpage2}% package for page style with not only uppercase letters in the head
\usepackage{titlesec}% for reducing space between ((sub)sub)sections and text
\usepackage{titletoc}% for subtocs (see documentation of titlesec); note: can't be used with tocstyle or minitoc
 
% page style and layout
\pagestyle{scrheadings}% activates pagestyle from scrpage2
\clearscrheadfoot% clear head and foot of scrheadings and scrplain
 
% enlarge font sizes of headings by two levels
\addtokomafont{section}{\huge}% from \Large to \huge
\addtokomafont{subsection}{\LARGE}% from \large to \LARGE
\addtokomafont{subsubsection}{\Large}% from \normalsize to \Large
 
% spacings
\titlespacing{\section}{0mm}{0ex plus 1ex minus .2ex}{0ex plus .2ex}% make space (left, before, after) between section and text smaller
\titlespacing{\subsection}{0mm}{0ex plus 1ex minus .2ex}{-.2ex plus .2ex}% make space (left, before, after) between subsection and text smaller
\titlespacing{\subsubsection}{0mm}{0ex plus 1ex minus .2ex}{-.4ex plus .2ex}% make space (left, before, after) between subsubsection and text smaller
\setcounter{secnumdepth}{3}% add numbering down to subsubsection
 
% table of contents
\AtBeginDocument{\renewcaptionname{american}{\contentsname}{\hspace{-0.08em}\Large Outline}}% change name of toc
\setcounter{tocdepth}{3}
\titlecontents{section}[1.2em]{\addvspace{0.6em}\bfseries}{\contentslabel{1.2em}}{\hspace*{-1.2em}}{}[]% define format for section of toc; entries: section, left, above, before with label, before without label, filler and page, after
\titlecontents{subsection}[3em]{}{\contentslabel{1.8em}}{\hspace*{-1.8em}}{}[]% define format for subsection of toc; entries: section, left, above, before with label, before without label, filler and page, after
\titlecontents{subsubsection}[5.6em]{}{\contentslabel{2.6em}}{\hspace*{-2.6em}}{}[]% define format for subsubsection of toc; entries: section, left, above, before with label, before without label, filler and page, after
\titlecontents{psubsection}[1.8em]{\addvspace{0.6em}}{\contentslabel{1.8em}}{\hspace*{-1.8em}}{}[]% define format for section of toc; entries: section, left, above, before with label, before without label, filler and page, after
\titlecontents{psubsubsection}[4.4em]{}{\contentslabel{2.6em}}{\hspace*{-2.6em}}{}[]% define format for subsection of toc; entries: section, left, above, before with label, before without label, filler and page, after
 
 
%%% document %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 
\begin{document}
\tableofcontents
\clearpage
\section{Section 1}
\startcontents[]% kind
\printcontents[]{p}{2}{}% kind, prefix, top, init-code
\clearpage
\subsection{Subsection 1.1}
This is some text This is some text This is some text This is some text This is some text This is some text This is some text This is some text This is some text This is some text This is some text This is some text This is some text This is some text This is some text This is some text This is some text This is some text
 
This is some text This is some text This is some text This is some text This is some text This is some text This is some text This is some text This is some text This is some text This is some text This is some text
\subsubsection{Subsubsection 1.1.1}
\subsection{Subsection 1.2}
\section{Section 2}
\subsection{Subsection 2.1}
\subsubsection{Subsubsection 2.1.1}
\subsubsection{Subsubsection 2.1.2}
\subsection{Subsection 2.2}
\subsubsection{Subsubsection 2.2.1}
\subsubsection{Subsubsection 2.2.2}
\clearpage
\end{document}
forum: 
Bild von Markus Kohm

Ein Bug liegt da nicht vor. titletoc setzt das Verzeichnis schlicht mit dem Absatzabstand, den Du eingestellt hast (wohingegen KOMA-Script selbst weiß, dass Verzeichnisse mit erhöhtem Absatzabstand normalerweise grauenvoll sind). Das beispielsweise mit:

\printcontents[]{p}{2}{\KOMAoptions{parskip=false}}

wunschgemäß anzupassen, ist doch kein Problem, oder?

Du kannst natürlich beim Autor von titletoc, darum bitten, dass er (wie andere Pakete auch) die Verzeichnisse mit angepassten Werten für \parskip und \parfillskip setzt. Von einem Bug würde ich aber nicht reden.

Da es sich hier um eine Frage zu titletoc und nicht zu KOMA-Script handelt (das Problem tritt beispielsweise auch mit einer Standardklasse und Paket parskip auf), werde ich das Thema entsprechend verschieben.

Sehr gut, genau was ich gesucht habe! Danke Dir, Markus.
Ich habe eine entsprechende Anfrage an den maintainer von titletoc gestellt.

Comments for "Klassenoption parskip=half- scheint sich nicht mit Paket titletoc zu vertragen" abonnieren