diff options
Diffstat (limited to 'Master/texmf-dist/tex/plain/pwebmac/pwebmac.tex')
-rw-r--r-- | Master/texmf-dist/tex/plain/pwebmac/pwebmac.tex | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/Master/texmf-dist/tex/plain/pwebmac/pwebmac.tex b/Master/texmf-dist/tex/plain/pwebmac/pwebmac.tex index 648064e6506..47390e217aa 100644 --- a/Master/texmf-dist/tex/plain/pwebmac/pwebmac.tex +++ b/Master/texmf-dist/tex/plain/pwebmac/pwebmac.tex @@ -10,7 +10,7 @@ % Uncomment the following line if you want PDF goodies to be the default %\ifx\pdf-\else\pdftrue\fi \def\pdflinkcolor{0 0 1} % the RGB values for hyperlink color -\ifx\undefined\XeTeXlinebreakpenalty\else\pdftrue\fi % XeTeX produces PDF output +\ifx\undefined\XeTeXrevision\else\pdftrue\fi % XeTeX produces PDF output \newif\ifpdftex \ifx\pdfoutput\undefined \pdftexfalse \else\ifnum\pdfoutput=0 \pdftexfalse \else \pdftextrue \pdfoutput=1 @@ -215,7 +215,8 @@ \def\MN#1.{\par % common code for \M, \N {\xdef\modstar{#1}\let\*=\empty\xdef\modno{#1}}% remove \* from section name \ifx\modno\modstar \onmaybe \else\ontrue \fi - \mark{\modno}} + \mark{{{\tensy x}\modno}{\rhead}}} +% each \mark is {section reference or null}{group title} \def\O#1{\hbox{\rm\char'23\kern-.2em\it#1\/\kern.05em}} % octal constant \def\P{\rightskip=0pt plus 100pt minus 10pt % go into Pascal mode \sfcode`;=3000 @@ -246,9 +247,14 @@ \def\onmaybe{\let\ifon=\maybe} \let\maybe=\iftrue \newif\ifon \newif\iftitle \newif\ifpagesaved \def\lheader{\mainfont\the\pageno\eightrm\qquad\rhead - \hfill\title\qquad\tensy x\mainfont\topmark} % top line on left-hand pages -\def\rheader{\tensy x\mainfont\topmark\eightrm\qquad\title\hfill + \hfill\title\qquad\mainfont\topsecno} % top line on left-hand pages +\def\rheader{\mainfont\topsecno\eightrm\qquad\title\hfill \rhead\qquad\mainfont\the\pageno} % top line on right-hand pages +\def\topsecno{\expandafter\takeone\topmark} +\def\takeone#1#2{#1} +\def\taketwo#1#2{#2} +\def\nullsec{\eightrm\kern-2em} % the \kern-2em cancels \qquad in headers + %\let\page=\pagebody \raggedbottom % cweb 3.2 uses this instead of next line \def\page{\box255 }\normalbottom % faster, but loses plain TeX footnotes \def\normaloutput#1#2#3{\ifodd\pageno\hoffset=\pageshift\fi @@ -260,6 +266,7 @@ \global\advance\pageno by1} \def\rhead{\.{WEB} OUTPUT} % this running head is reset by starred sections +\mark{\noexpand\nullsec{\rhead}} \def\title{\expandafter\uppercase\expandafter{\jobname}} \def\topofcontents{\centerline{\titlefont\title}\vskip.7in \vfill} % this material will start the table of contents page @@ -278,7 +285,7 @@ \fullpageheight=9truein\setpage} \def\setpage{\hsize\pagewidth\vsize\pageheight} % use after changing page size \def\contentsfile{CONTENTS} % file that gets table of contents info -\def\readcontents{\input CONTENTS} +\def\readcontents{\input \contentsfile} \newwrite\cont \output{\setbox0=\page % the first page is garbage @@ -324,6 +331,7 @@ \ifpdftex \makebookmarks \fi % added in Version 4.5 \parfillskip 0pt plus 1fil \def\rhead{NAMES OF THE SECTIONS} + \let\topsecno=\nullsec \message{Section names:} \output={\normaloutput\page\lheader\rheader} \setpage |