I have a problem with the tocloft
package. Whenever I try to include it in my document, the first page (only) of the table of contents contains a page number, even so I don´t want any page numbers at all for the toc. When I remove the \usepackage{tocloft}
call, the toc is displayed without a page number, so somehow it must be messing up the layout…
Is there a way to tell tocloft
to not adjust anything in the table of contents?
\pagestyle{empty}
and \thispagestyle{empty}
don´t solve the problem.
Note: I am using the tocloft
package only so I can create a list of equations (via \newlistof
command from tocloft
). So I would also be glad about way to get the \newlistof
command without the tocloft
package.
EDIT: Example:
Thank you for considering my problem: Here is a code example:
\documentclass[12pt,a4paper]{article}
\usepackage[export]{adjustbox}% http://ctan.org/pkg/adjustbox
\usepackage{tocloft}
\usepackage{amsmath,amsthm,amssymb}
\usepackage[T1]{fontenc}
...
//the part responsible for creating creating the listofequations
\newcommand{\listequationsname}{}
\newlistof{myequations}{equ}{\listequationsname}
\newcommand{\myequations}[1]{%
\addcontentsline{equ}{myequations}{\protect\numberline{\theequation}#1}\hfill}
...
//sample equation
\begin{equation}\label{eq:Eq1}
a^{2}+b^{2}=c^{2}
\end{equation}
\myequations{Satz des Pythagoras \ref{eq:Eq1}}
...
//displaying the list of equations
\subsection{Equations}
\renewcommand{\listequationsname}{}
\listofmyequations
Thanks in advance!
SOLUTION:
The command posted by Andrew Swann as a comment solved the issue for me.
I only had to add \renewcommand{\cftaftertoctitle}{\thispagestyle{empty}}
before \tableofcontents
Thank you alot!
Best Answer
The manual suggests
\renewcommand{\cftafterZtitle}{\thispagestyle{empty}}
whereZ
is the list type. In your caseZ
isequ
so you should addto your preamble.
By the way, your command
\myequations
should end with\ignorespaces
instead of\hfill
so that following text doesn't necessarily start a new paragraph.