Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

When list-ofs follow each other they overlap, at least with my setup. Here's an example:

test.tex

\documentclass[a4paper]{memoir}

\usepackage{xltxtra}
\usepackage{polyglossia}

% New list of source code listings
\newcommand{\sourcename}{Source Code Listing}
\newfloat[chapter]{source}{los}{\sourcename}
\newcommand{\listsourcename}{List of Source Code}
\newlistof{listofsources}{los}{\listsourcename}
\newlistentry{source}{los}{0}

\renewcommand*{\insertchapterspace}{%
  \addtocontents{lof}{\protect\addvspace{10pt}}%
  \addtocontents{lot}{\protect\addvspace{10pt}}%
  \addtocontents{los}{\protect\addvspace{10pt}}}

\chapterstyle{pedersen}

\begin{document}

\frontmatter

\listoffigures

\listofsources

\mainmatter

\chapter{One}

\begin{figure} \caption{Some  fig} \end{figure}
\begin{figure} \caption{Other fig} \end{figure}

\begin{source} \caption{Some  src} \end{source}
\begin{source} \caption{Other src} \end{source}

\end{document}

Compile with:

xelatex test.tex && xelatex test.tex

This is the result:

I could add some vertical space, but is there a more correct way of handling this?

share|improve this question

1 Answer 1

up vote 5 down vote accepted

That's a side effect of the petersen chapter style. The definition of this style contains (among other things) the code line

\setlength{\beforechapskip}{-20pt}

which results in the observed overlap. One probably could add some safeguarding for the case of two unnumbered chapters starting on the same page, but IMO it's acceptable to manually add some vertical space in this case.

share|improve this answer
    
That explains it thank you very much. –  Thor Sep 2 '12 at 20:27

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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