[Tex/LaTex] Table of contents only on right-hand side pages

double-sidedtable of contents

I need to have a table of contents only on right-hand sided (even) pages, a goal similar to what was described here: Table of content only on right-side pages. However, I have a table of contents spanning at least 3 pages, and while

\documentclass[11pt,twoside,a4paper]{report}
\usepackage{afterpage}
\AtBeginDocument{%
    \addtocontents{toc}{\protect\afterpage\protect\cleardoublepage}%
}
\begin{document}
\tableofcontents
\chapter{}
\end{document}

does add one blank page after the first toc page, the following pages appear as well in the left side.

Is there a way to have all pages of this kind of front matter (particularly the TOC) only right-sided while using the report document class?

Best Answer

I couldn't find a solution in viable time, so I ended up by manually editing the doc.toc table of contents index and adding several \afterpage \cleardoublepage commands through it to force clearing the pages.

In the main document I replaced the \tableofcontents command with \input doc.toc which prevents indexing a new table of contents and reads the file I've manually edited:

\documentclass[11pt,twoside,a4paper]{report}
\usepackage{afterpage}

\begin{document}
\input doc.toc
\chapter{}
\end{document}

If anyone still has a programmatic solution, please contribute.

EDIT: Instead of manually editing the .toc file one can add a

\addtocontents{toc}{\protect\afterpage\protect\cleardoublepage}

command throughout the main text (e.g. after the begining of each chapter), which will add the \cleardoublepage command to the .toc just the same. This way, you can call the toc with \tableofcontents as always.

Related Question