[texhax] change some parameters of chapter

John R. Culleton john at wexfordpress.com
Tue Aug 15 04:32:28 CEST 2006

On Monday 14 August 2006 17:41, Reinhard Kotucha wrote:
> >>>>> "John" == John R Culleton <john at wexfordpress.com> writes:
>   >
>   > Here is a plain pdftex macro I used for a novel. It should also
>   > work in LaTeX:
>   >
>   > \def\chapter#1{%
>   > \vfil\eject
>   > \titlepagetrue
>   > \ifodd\pageno\else
>   > \vglue 1.5in
>   > \centerline{\webx 8}
>   > \vfil\eject
>   > \titlepagetrue\fi
>   > \vglue 1.8in
>   > \line{\leaderw\lower 4.5pt\hbox{\head #1}\  \leaderw}
>   > \vglue 1in}
> Why do you think this should work in LaTeX?  LaTeX is not just an
> extension to plain TeX, it is something completely different.
Not completely. Many of the commands created in plain also work in
LaTeX. But in any case I was merely illustrating how a custom
chapter heading could be constructed. Of course what I wanted and
what he wanted were two different things.  

> You can find out easily that it doesn't work:
>    *\show\titlepagetrue
>    > \titlepagetrue=undefined.

As I stated, I define titlepage  with a \newif statement, which
is a TeX primitive. So that is easily handled by LaTeX. 
 Those with sharp eyes will note that I borrowed it from 
"A Gentle Introduction to TeX." by Michael Doob. 
I use it to turn off headers for one page
only. The name "\titlepage" merely reflects its origin. 

Determining the folio is more problematic, but I suspect it would
be possible to determine which counter was in use in LaTeX.
Perhaps \pageref couild be substituted.

It is a fact that the \chapter macro as defined by LaTeX has very
few options, and even if I was working in LaTeX I would want to
either redfine it or else define a \Chapter macro if I wanted to
do anything fancy. I also suggested that some LaTeX construct
such as memoir.sty might have additional facilities. You could
assist by suggesting the most useful LaTeX construct that would
allow him to do what he wanted.

John Culleton
Able Indexing and Typesetting
Precision typesetting (tm) at reasonable cost.
Satisfaction guaranteed. 

More information about the texhax mailing list