19

Although `I wouldn't normally do this', I'm writing a short(ish) document for which I'd like to place a small TOC in two columns as the last thing on the title page.

In single column mode it works fine. However, when I specify \twocoltocetc, I get a new page. Here's an MWE:

\documentclass[10pt,a4paper]{memoir}
\twocoltocetc
\begin{document}
\frontmatter
\title{Something or other}
\author{H.I.M. Self}
\maketitle
\tableofcontents*
\mainmatter
\chapter{Introduction}
\chapter{First chapter}
\section{First section}
\end{document}

What, if anything, must I do to fix this?

19

A quick way is temporarily disabling \clearpage for the table of contents which prevents that page break:

\begingroup
\let\clearpage\relax
\tableofcontents*
\endgroup

After that group, \clearpage has the original meaning.

0
6
\documentclass[10pt,a4paper]{memoir}
\usepackage{multicol}
\makeatletter
\renewcommand\tableofcontents{%
\begin{multicols}{2}[
    \section*{\huge\contentsname
        \@mkboth{%
           \MakeUppercase\contentsname}{\MakeUppercase\contentsname}}]
    \@starttoc{toc}%
\end{multicols}}
\makeatother
\begin{document}
\frontmatter
\title{Something or other}
\author{H.I.M. Self}
\maketitle
\tableofcontents
\mainmatter
\chapter{Introduction}
\chapter{First chapter}
\section{First section}
\end{document}
1
  • Thanks, Herbert. I'm going to wait a day or two before accepting, to see if a ``pure memoir'' solution appears... Aug 27 '11 at 15:57
1

Not sure if this is more pure or not. It might just be abuse of innocent memoir ToC-formatting commands. And if you're looking to have a title followed by the first part of the ToC in column one, this won't work (use one of the other answers). But if you want a narrower ToC to the right of the narrow title block, this could be used.

enter image description here

\documentclass[10pt,a4paper]{memoir}
\twocoltocetc
\begin{document}
\frontmatter
\title{Something or other}
\author{H.I.M. Self}
\date{\today}

\renewcommand{\tocheadstart}{
{\beforepartskip \centering
{\Huge\bfseries\thetitle} \par
{\Large\theauthor} \par
{\Large\thedate} \afterpartskip
\newpage}
}
\tableofcontents*
\mainmatter
\chapter{Introduction}
\chapter{First chapter}
\section{First section}
\end{document}
1
  • Thanks, Mike. That's ingenious, and reasonably pure, but I really wanted to keep the titling stuff `above' and the TOC `below' Aug 27 '11 at 20:14
0

Although six years have elapsed since the question was asked, I want to provide a memoir solution with an index after the title that does not force a page break. This variant includes the excellent idea of Herber using the multicol package, so that the index is two columns. I add that the text is two columns, with a separating line, for a good visual appearance (in my opinion), but that can also be used with a column layout.

\documentclass[article,12pt,twocolumn]{memoir}

% Herber's solution
\usepackage{multicol}
\makeatletter
\renewcommand\tableofcontents{%
\begin{multicols}{2}[
    \section*{\huge\contentsname
        \@mkboth{%
           \MakeUppercase\contentsname}{\MakeUppercase\contentsname}}]
    \@starttoc{toc}%
\end{multicols}}
\makeatother

% My proposal
\renewcommand{\maketitlehookd}[1]{\twocoltocetc\tableofcontents
{{ }\hfill\rule{0.618\linewidth}{1.25pt}\hfill{ }}}

\begin{document}
%\frontmatter
\title{Something or other}
\author{H.I.M. Self}
\maketitle
%\tableofcontents
%\mainmatter

\chapter{Introduction 1}
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx 
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx 

xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx 
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx 

\section{First section}
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx 
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx 

xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx 
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx 

\section{Second section}
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx 
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx 

xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx 
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx 

\chapter{Introduction 2}
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx 
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx 

xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx 
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx 

\section{First section}
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx 
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx 

xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx 
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx 

\section{Second section}
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx 
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx 

xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx 
xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx xxxxx xxxxxx xxxxxx 

\end{document}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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