Page LayoutMemoir Table of Contents Formatting

Information and discussion about page layout specific issues (e.g. header and footer lines, page formats, page numbers).
Post Reply
twesslen
Posts: 6
Joined: Thu Feb 03, 2011 9:17 pm

Memoir Table of Contents Formatting

Post by twesslen »

Hello there. I am trying to format a table of contents as per my university formatting guidelines and am almost there. I need to add a blank entry (not referencing anything, as a contents header if you will) and additionally, add a period after the chapter number in the table of contents only, not in the actual chapter printing within the body of my document. See the attached images for what I mean.

Current:
Current
Current
Current.jpg (24.46 KiB) Viewed 5608 times
Desired:
Desired
Desired
Desired.jpg (38.84 KiB) Viewed 5608 times
I have read the memoir documentation and I have to admit that I'm overwhelmed. If anyone can direct me towards what I should do that would be great.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

twesslen
Posts: 6
Joined: Thu Feb 03, 2011 9:17 pm

Memoir Table of Contents Formatting

Post by twesslen »

The attached files contain a MWE of the current state of my project. See the previous post for an example of what I want to do.

Main tex file:
toc.tex
Main tex file
(2.79 KiB) Downloaded 432 times
Style file:
twllu.sty
Style File
(14.6 KiB) Downloaded 376 times
twesslen
Posts: 6
Joined: Thu Feb 03, 2011 9:17 pm

Memoir Table of Contents Formatting

Post by twesslen »

Ok, I fixed one of the problems by placing

Code: Select all

\renewcommand{\cftchapteraftersnum}{.}
in the style file. Now I just need to figure out how to add a dummy line (header) in the toc. Anyone have any advice?
User avatar
frabjous
Posts: 2064
Joined: Fri Mar 06, 2009 12:20 am

Memoir Table of Contents Formatting

Post by frabjous »

Try something like:

Code: Select all

\addtocontents{toc}{\noindent{Chapter}\par}
Right before:

Code: Select all

\chapter{Introduction}
twesslen
Posts: 6
Joined: Thu Feb 03, 2011 9:17 pm

Memoir Table of Contents Formatting

Post by twesslen »

Thank you for your help. This works well. Additionally, I might add that to center the chapter numbers under the pseudo "Chapter" entry I used

Code: Select all

\renewcommand{\cftchaptername}{\hspace{1.5em}}
which put the

1. Introduction

over to the right a bit.
Post Reply