Part and the TOC

242 views
Skip to first unread message

chip

unread,
Sep 6, 2009, 5:40:31 PM9/6/09
to tufte-latex
Hi
I'm having fun. Strange way to spend the holiday, though. I appreciate
the quick replies.

I need the Part sectioning and get that to work by using the svn
latest version of the common def file. (Thanks) However, something
about the TOC production is unhappy. I get the following errors (when
going through the filet the second time). As you can see, I keep
pushing through and eventually it finishes with a hyperlinked TOC,
including a Part TOC entry with a red box around it.

thanks,
ray

PS Do you understand the complaint about symmetric? That's not
bothersome, but just a curiosity.

No file fancyvrb.cfg.
) (/usr/local/texlive/2007/texmf-dist/tex/latex/tools/xspace.sty)
(/usr/local/texlive/2007/texmf-dist/tex/latex/units/units.sty
(/usr/local/texlive/2007/texmf-dist/tex/latex/units/nicefrac.sty))
(/usr/local/texlive/2007/texmf-dist/tex/latex/base/makeidx.sty)
Writing index file PPaC_090609_ag.idx

LaTeX Warning: Unused global option(s):
[symmetric].
(./PPaC_090609_ag.aux (./001Particles28.aux) (./
002C:_Our_Toolkit25.aux)
(./003S:_Some_Graphs12.aux) (./
004S:_Feynman_Diagrams_and_the_Fast_Break12.aux)
(./005C:_Physics_Is_Undone16.aux) (./
006S:_Light_Before_Maxwell16.aux))
(/usr/local/texlive/2007/texmf-dist/tex/latex/base/ts1cmr.fd)
(/usr/local/texlive/2007/texmf-dist/tex/latex/lm/t1lmr.fd)
(/usr/local/texlive/2007/texmf-dist/tex/latex/hyperref/nameref.sty
(/usr/local/texlive/2007/texmf-dist/tex/latex/oberdiek/refcount.sty))
(./PPaC_090609_ag.out) (./PPaC_090609_ag.out)
(/usr/local/texlive/2007/texmf-dist/tex/context/base/supp-pdf.tex
[Loading MPS to PDF converter (version 2006.09.02).]
) (./001Particles28.tex [1{/usr/local/texlive/2007/texmf-var/fonts/map/
pdftex/u
pdmap/pdftex.map}] (/usr/local/texlive/2007/texmf-dist/tex/latex/lm/
ts1lmr.fd)
[2] (/usr/local/texlive/2007/texmf-dist/tex/latex/lm/t1lmss.fd)
(./PPaC_090609_ag.toc
! Undefined control sequence.
\find@pdflink ...ode \protected@edef \Hy@testname
{#2}\ifx
\Hy@testname \@em...
l.1 ...rt}{I\hspace {1em}The Particles}{5}{part.1}

?
! Undefined control sequence.
<argument> \Hy@testname

l.1 ...rt}{I\hspace {1em}The Particles}{5}{part.1}

?
! Undefined control sequence.
<argument> \Hy@testname

l.1 ...rt}{I\hspace {1em}The Particles}{5}{part.1}

?
! Undefined control sequence.
<argument> \Hy@testname

l.1 ...rt}{I\hspace {1em}The Particles}{5}{part.1}

?
! Missing control sequence inserted.
<inserted text>
\inaccessible
l.1 ...rt}{I\hspace {1em}The Particles}{5}{part.1}

?
! Missing control sequence inserted.
<inserted text>
\inaccessible
l.1 ...rt}{I\hspace {1em}The Particles}{5}{part.1}

?
! Extra }, or forgotten \endgroup.
\ttl@tocentry ...ondoftwo #5{#7}\strut \kern \z@ }
\fi {#6}\ifcase
#1\relax \...
l.1 ...rt}{I\hspace {1em}The Particles}{5}{part.1}

?
) [3] [4] [5] [6]
Chapter 1.
(/usr/local/texlive/2007/texmf-dist/tex/latex/lm/ts1lmss.fd)
Overfull \hbox (15.23529pt too wide) in paragraph at lines 58--58
[]\T1/lmss/m/n/10 Elementary Par-ti-cle Physics and Cos-mol-ogy are
two sub-dis
ciplines
[7]

Kevin Godby

unread,
Sep 6, 2009, 5:54:16 PM9/6/09
to tufte...@googlegroups.com
'allo.

On Sun, Sep 6, 2009 at 4:40 PM, chip<br...@pa.msu.edu> wrote:
>
> Hi
> I'm having fun. Strange way to spend the holiday, though. I appreciate
> the quick replies.
>
> I need the Part sectioning and get that to work by using the svn
> latest version of the common def file. (Thanks) However, something
> about the TOC production is unhappy. I get the following errors (when
> going through the filet the second time). As you can see, I keep
> pushing through and eventually it finishes with a hyperlinked TOC,
> including a Part TOC entry with a red box around it.

Are you using any custom TOC code?

The last time I saw this error it was due to an interaction between
the hyperref package the the letterspacing (specifically, \allcaps)
code. I'm still trying to work out a good solution for it.

> PS Do you understand the complaint about symmetric? That's not
> bothersome, but just a curiosity.

This is because of a recent switch to the xkeyval package for the
document class option handling. I haven't finished that code yet, so
it generates a warning with some document class options. The options
still take effect, but the xkeyval package doesn't remove them from
LaTeX's "unprocessed options" list at the moment, so LaTeX generates a
warning to let you know that it doesn't remember doing anything with
that option.

--Kevin

chip

unread,
Sep 8, 2009, 12:40:45 PM9/8/09
to tufte-latex
HI
Again, thanks for your help. I don't think it's related to my file. If
I add a \part{This is a Part} (followed by a chapter) to the regular
tufte-book.tex file and then run it with the cvs version that allows
Parts...I get the same error. My local file is pasted below...which is
proceeded by the snippet of text that I added to tufte-book.tex

thanks,
Ray

my change to the tufte-book.tex file:


Tufte's books primarily use two typefaces: Bembo and Gill Sans. Bembo
is used
for the headings and body text, while Gill Sans is used for the title
page and
opening epigraphs in \BE.

\part{This is a Part}

\chapter{This is a chapter}

Since neither Bembo nor Gill Sans are available in default \LaTeX{}
installations, the \TL document classes default to using Palatino and
Helvetica, respectively. In addition, the Bera Mono typeface is used
for
\texttt{monospaced} type.



My tufte-book-local.tex contents:

%%
% VDQI title page
\renewcommand{\maketitlepage}[0]{%
\cleardoublepage%
{%
\begin{fullwidth}%
\fontsize{24}{30}\selectfont\par\noindent\thanklessauthor%
\vspace{1.75in}%
\fontsize{36}{54}\selectfont\par\noindent\thanklesstitle%
%\vspace{0.5in}%
%\LARGE\par\noindent\theedition%
\vfill%
\fontsize{14}{16}\selectfont\par\noindent\thanklesspublisher%
\end{fullwidth}%
}
\thispagestyle{empty}%
\clearpage%
}

\usepackage[svgnames]{xcolor}
%\titleformat{\chapter}{\color{MidnightBlue}}{\thechapter}{1em}{#1}

\titleformat{\part}%
[hang]% shape
{\color{black}\Huge\sffamily}% format applied to label+text
{\color{black}\sffamily Part \thepart}% label
{1em}% horizontal separation between label and title body
{\color{gray}\sffamily}% before the title body
[]% after the title body

\titleformat{\chapter}%
[display]% shape
{\relax\ifthenelse{\NOT\boolean{@tufte@symmetric}}{\begin{fullwidth}}
{}}% format applied to label+text
{\color{black}\huge \bf \sffamily Chapter \thechapter}% label
{0pt}% horizontal separation between label and title body
{\color{gray}\huge\sffamily}% before the title body
[\ifthenelse{\NOT\boolean{@tufte@symmetric}}{\end{fullwidth}}{}] %
after the title body

\titleformat{\section}%
[hang]% shape
{\color{black}\LARGE\bf\sffamily}% format applied to label+text
{\color{black}\bf \sffamily\thesection}% label
{1em}% horizontal separation between label and title body
{\color{black}\bf \sffamily}% before the title body
[]% after the title body

\titleformat{\subsection}%
[hang]% shape
{\color{gray}\Large \bf \sffamily}% format applied to label+text
{\bf \sffamily \thesubsection}% label
{1em}% horizontal separation between label and title body
{}% before the title body
[]% after the title body

\geometry
{landscape,left=1in,top=1in,textheight=6.5in,textwidth=6in,marginparsep=0.5in,marginparwidth=2.5in}

%%
% VDQI table of contents
% See the `titlesec' and `titletoc' documentation for details:
http://ctan.org/pkg/titlesec
\titlecontents{part}%
[0pt]% distance from left margin
{\addvspace{0.25\baselineskip}}% above (global formatting of
entry)
{\allcaps{Part~\thecontentslabel}\allcaps}% before w/ label (label
= ``I'')
{\allcaps{Part~\thecontentslabel}\allcaps}% before w/o label
{}% filler and page (leaders and page num)
[\vspace*{0.5\baselineskip}]% after
\titlecontents{chapter}%
[4em]% distance from left margin
{}% above (global formatting of entry)
{\contentslabel{2em}\textit}% before w/ label (label = ``1'')
{\hspace{0em}\textit}% before w/o label
{\qquad\thecontentspage}% filler and page (leaders and page num)
[\vspace*{0.5\baselineskip}]% after
% TODO: Add similar for section, subsection, etc. if desired
%%
% VDQI \section headings are bold, not italic
% See the `titlesec' and `titletoc' documentation for details:
http://ctan.org/pkg/titlesec
%\titleformat{\section}%
% [hang]% shape
% {\normalfont\Large\bfseries}% format applied to label+text
% {\thesection}% label
% {1em}% horizontal separation between label and title body
% {}% before the title body
% []% after the title body
%%
% VDQI chapters are numbered
\setcounter{secnumdepth}{4}
% TODO: Use \titleformat to adjust the \part style
%%
% Done!

\usepackage{color}
\definecolor{footcolor}{rgb}{0.09,0.38,0.35}
\definecolor{slidercolor}{rgb}{0.09,0.38,0.35}
\definecolor{mycolor}{rgb}{0.09,0.29,0.51}
\definecolor{red}{rgb}{1, 0, 0}
\definecolor{blue}{rgb}{0, 0, 1}
\definecolor{green}{rgb}{0.24, 0.55, .24}
\definecolor{gray}{rgb}{0.35, 0.35, 0.35}
\definecolor{title}{rgb}{0.5, 0., 0.251}
\definecolor{title2}{rgb}{0.0, 0.25, 0.5}


\usepackage{framed}
\definecolor{shadecolor}{named}{Melon}

\setsidenotefont{\sffamily\footnotesize\color{title}}
\setmarginnotefont
\setcaptionfont
%\setcitationfont

Kevin Godby

unread,
Sep 8, 2009, 2:23:03 PM9/8/09
to tufte...@googlegroups.com
On Tue, Sep 8, 2009 at 11:40 AM, chip<br...@pa.msu.edu> wrote:
>
> HI
> Again, thanks for your help. I don't think it's related to my file. If
> I add a \part{This is a Part} (followed by a chapter) to the regular
> tufte-book.tex file and then run it with the cvs version that allows
> Parts...I get the same error. My local file is pasted below...which is
> proceeded by the snippet of text that I added to tufte-book.tex

In your -local.tex file, you have \titlecontents{part}, which
redefines the appearance of the part entries in the table of contents.
There's some bad interaction between the \allcaps command and
hyperref. I'm still working on a good solution for this.

In the meantime, if you replace \allcaps with \uppercase, you should
be able to compile your document (though you'll lose the letterspacing
of the all-caps part entries in the TOC).

--Kevin

chip

unread,
Sep 8, 2009, 2:39:55 PM9/8/09
to tufte-latex
Bingo. That fixes it. Thanks!
Ray
Reply all
Reply to author
Forward
0 new messages