## LaTeX forum ⇒ General ⇒ Custom Chapter Name For Just One Entry

LaTeX specific issues not fitting into one of the other forums of this category.
AleCes
Posts: 286
Joined: Sat Nov 13, 2010 9:54 pm

### Custom Chapter Name For Just One Entry

Hello.

I want to have a customized ToC like this:

Chapter 1
/////// 2
/////// 3

and so on.

Is there a way to do that with tocloft?

\documentclass{book}\usepackage{tocloft}\begin{document}\chapter{Foreword} \chapter{blah} \chapter{Afterword}\end{document}

Thanks everybody.

Stefan Kottwitz
Posts: 9445
Joined: Mon Mar 10, 2008 9:44 pm
AleCes wrote:Chapter 1
/////// 2
/////// 3

Are 1, 2, 3 chapter numbers or page numbers? In case of the first - no page numbers? No titles such as "Foreword", "Afterword" of the example?

Which is the just one entry for you would like to have a custom name, and which is the name?

Stefan

AleCes
Posts: 286
Joined: Sat Nov 13, 2010 9:54 pm
OK sorry, I wanted something like this:

Chapter 1.................01
/////// 2.................10
/////// 3.................30

Stefan Kottwitz
Posts: 9445
Joined: Mon Mar 10, 2008 9:44 pm
Sounds like simply

\addcontentsline{toc}{chapter}{Chapter \thechapter}...\addcontentsline{toc}{chapter}{/////// \thechapter}...\addcontentsline{toc}{chapter}{/////// \thechapter}

at those places.

Stefan

AleCes
Posts: 286
Joined: Sat Nov 13, 2010 9:54 pm
Thanks but I was thinking about something more standardized, where only the first entry has a special format.

Stefan Kottwitz
Posts: 9445
Joined: Mon Mar 10, 2008 9:44 pm
I still don't understand why \chapter{Foreword} should produce "Chapter 1.................01" (without "Foreword") in the table of contents, and what "///////" in the other entries should mean (such actual symbols or dummy characters as place-holder for titles).

It would be good to post code you really mean (your code doesn't even contain the command \tableofcontents) and a better description. Even a hand-made drawing would be good.

Stefan

AleCes
Posts: 286
Joined: Sat Nov 13, 2010 9:54 pm
You're right I'm sorry about my sloppiness

Yeah, ///// stands for dummy characters as place-holders for titles. Anyway, tomorrow I shall draw a sketch of what I want and post it here.

Bye and thanks a lot for your patience!