[OS X TeX] First Page Header & Subsequent Pages Header
Josep Maria Font
jmfont at ub.edu
Thu Sep 17 13:45:08 EDT 2009
El dia 17/09/2009, a les 14:35, Scott, Randy va escriure:
> \ifthenelse{\value{page}=1}
> {\lhead{\textbf{Math 280, Intermediate Calculus\\Change of
> Variables in Multiple Integrals}} \chead{} \rhead{}\lfoot{} \cfoot{}
> \rfoot{}}
> {\lhead{\textbf{Math 280, Change of Variables in Multiple
> Integrals}} \chead{} \rhead{\textbf{\thepage}}\lfoot{} \cfoot{}
> \rfoot{}
> }
I suppose the problem is that, wherever you insert this macro, it gets
executed only once, so that only the current page number is used. I
don't know whether there is some \everypage macro that allows you to
force something to be repeated for every page (there is \everypar,
though; see The TeXBook).
One idea would be to put the \ifthenelse mechanism *inside* each of
the headers. Something like
\lhead{\ifthenelse{\value{page}=1}{\textbf{Math 280, Intermediate
Calculus\\Change of Variables in Multiple Integrals}{\textbf{Math 280,
Change of Variables in Multiple Integrals}}}
and similar for \rhead, etc.
BTW, I don't think it is necessary to use the "ifthenelse" package for
this conditional; probably the following TeX primitive would also work:
\lhead{\ifnum\value{page}=1\textbf{Math 280, Intermediate Calculus\
\Change of Variables in Multiple Integrals}\else\textbf{Math 280,
Change of Variables in Multiple Integrals}\fi}
Hope this helps
JMaF
More information about the MacOSX-TeX
mailing list