diff options
author | Norbert Preining <norbert@preining.info> | 2019-09-02 13:46:59 +0900 |
---|---|---|
committer | Norbert Preining <norbert@preining.info> | 2019-09-02 13:46:59 +0900 |
commit | e0c6872cf40896c7be36b11dcc744620f10adf1d (patch) | |
tree | 60335e10d2f4354b0674ec22d7b53f0f8abee672 /macros/lamstex/doc/wiz.mac |
Initial commit
Diffstat (limited to 'macros/lamstex/doc/wiz.mac')
-rw-r--r-- | macros/lamstex/doc/wiz.mac | 229 |
1 files changed, 229 insertions, 0 deletions
diff --git a/macros/lamstex/doc/wiz.mac b/macros/lamstex/doc/wiz.mac new file mode 100644 index 0000000000..79d6736eac --- /dev/null +++ b/macros/lamstex/doc/wiz.mac @@ -0,0 +1,229 @@ +\catcode`\@=11 + +\font\cmbf=cmbx10 + +\font\cmtensl=cmsl10 + +\font\sevenit=bs0032 at 7pt +\font\sixit=bs0032 at 6pt +\font\sevenbfit=bs0034 at 7pt +\font\swissblackcondensed=bs0033 at 16pt +\font\Tensy=cmsy10 scaled \magstephalf + +\def\muttontex{\hskip1pt minus1ptM\kern-.19em\lower.32ex\hbox{U}\kern-.33em + T\kern-.29em\lower.26ex\hbox{T}\kern.01em + \raise .9ex\hbox{\if\pointsize@ t\sevenit\else \sixit\fi o}% + \kern-.1em n\kern.05em\tex\null\FN@\muttontex@} + +\def\muttontex@{\let\next@,\ifx\next\next@\else + \let\next@.\ifx\next\next@ + \else\let\next@;\ifx\next\next@\else + \let\next@:\ifx\next\next@\else\let\next@?\ifx\next\next@\else + \let\next@!\ifx\next\next@\else\let\next@'\ifx\next\next@\else + \hskip1pt minus1pt\relax\fi\fi\fi\fi\fi\fi\fi} + +\def\slip{\egroup%\box\litbox@\vskip-2\baselineskip\penalty\interlitpenalty@ + \medskip\litlines@\z@\Lit@}%\initspaces@\z@\FN@\CtrlM@@} + +\def\slop{\egroup%\box\litbox@\vskip-2\baselineskip\penalty\interlitpenalty@ + \vskip3pt\litlines@\z@\Lit@}%\initspaces@\z@\FN@\CtrlM@@} + +{\catcode`\^^M=13 \gdef\letCM@{\let^^M=\CCtrlM@}} + +\def\CCtrlM@{\egroup\iffirstCtrlM@\firstCtrlM@false + \else\box\litbox@\penalty\interlitpenalty@\fi\initspaces@\z@\FN@\CCtrlM@@} + +\gdef\CCtrlM@@{\ifx\next*\DN@**{\egroup\endgroup\printcode@}\else +\DN@{\Lit@}\fi\next@} + +\newbox\codebox@ + +\def\codestar@{\def*##1{\egroup\egroup\endgroup\printcode@}} + +\def\C**{\begingroup\codestar@ + \def\displaybreak{\egroup\break\litlines@\z@\Lit@}% + \def\allowdisplaybreak{\egroup\allowbreak\litlines@\z@\Lit@}% + \def\allowdisplaybreaks{\egroup\allowbreak + \interlitpenalty@\z@\litlines@\z@\Lit@}% + \tt\obeylines\letM@\catcode`\^^I=\active% + \litcodes@\letTAB@\global\setbox\codebox@\vbox\bgroup\litindent\z@% + \Lit@} + +\newif\ifdashcode@ +\newif\ifdotcode@ + +\def\dashC{\dashcode@true\C} +\def\dotC{\dotcode@true\C} + +\newif\ifdoublecode@ + +\def\CC{\doublecode@true\C} + +\font\tenrmmag=cmr10 scaled \magstep1 + +\def\coderule{\ifdashcode@ + \hbox{\xleaders\hbox + to6pt{\hfil\leaders\hrule\hskip3pt\hfil}\hskip\dimen@}\else + \ifdotcode@ + \hbox{\xleaders\hbox to4pt{\hfil\eightbf.\hfil}\hskip\dimen@}\else + \ifdoublecode@ + \hbox{\leaders\hrule\hskip\dimen@}\nobreak\vskip-\baselineskip\vskip1.5pt + \hbox{\leaders\hrule\hskip\dimen@}\else + \hbox{\leaders\hrule\hskip\dimen@}\fi\fi\fi} + + +\def\printcode@{\endgraf +\bigskip\dimen@\wd\codebox@ + \ifdim\dimen@<\hsize\dimen@\hsize\fi + \vskip-\baselineskip\coderule %\hbox{\leaders\hrule\hskip\dimen@} + \nobreak + \nointerlineskip + \vskip 6pt + \unvbox\codebox@ + \nobreak + \vskip 6pt + \coderule % \hbox{\leaders\hrule\hskip\dimen@} + \dashcode@false + \dotcode@false + \doublecode@false + \nointerlineskip + \bigskip + \FN@\printcode@@} + +\def\printcode@@{\ifx\next\par\else\noindent\ignorespaces\fi} + +\def\starparts@#1{\def\stari@{#1}\def\starii@{#1}\let\stariii@\empty + \test@false + \DN@##1*##2##3\next@{\ifx\starparts@##2\test@false\else\test@true\fi}% + \next@#1*\starparts@\next@ + \iftest@\DN@{\starparts@@#1\starparts@@}\else\let\next@\relax\fi\next@} +\def\starparts@@#1*#2\starparts@@{\def\starii@{#1}\def\stariii@{*#2}} + + +\newif\ifrunningchapter@ +\newtoks\runningchaptertoks@ +\def\runningchapter#1{\global\runningchapter@true\runningchaptertoks@{#1}} + +\let\thechapter@\relax + + +\expandafter\def\csname HL@1\endcsname#1\endHL{\par\vfill\break + \global\nosection@true + \ifrunningchapter@\else\runningchaptertoks@{#1}\fi + \global\runningchapter@false + {\noexpands@ + \xdef\thechapter@{\ifx\Thepref@\empty\else\Thepref@\null. \fi + \the\runningchaptertoks@}}% + \global\firstchappage@true + {\locallabel@ + \global\setbox\@ne\vbox{\Let@\tabskip\hss@ + \halign to\hsize{\bf\hfil\ignorespaces##\unskip\hfil\cr + {\ifx\thelabel@@\empty\else Chapter \thelabel@@\enspace\fi}% + \ignorespaces#1\crcr}}}\unvcopy\@ne\mark{}\nobreak\vskip\baselineskip + \firstparflush@ +} +\def\chaptergr#1\endchaptergr{%\runningchapter{\ignorespaces#1\unskip}% + \Evaluate\chapter + \count@\Value\relax\advance\count@\@ne + \setbox\z@\hbox{\bf Chapter \number\count@.\enspace}% + \setbox\@ne\hbox{\ \ }\dimen@\wd\@ne + \setbox\@ne\hbox{\glasses A}\advance\dimen@\wd\@ne + \chapter \Glasses#1\endGlasses\endchapter} + + + +\expandafter\def\csname HL@I1\endcsname{\Reset\hl1{1}\newpre + \hl1{\ifx\pref\empty\else\pref.\fi}} + + +\NameHL2\chapters + +\expandafter\def\csname HL@2\endcsname#1\endHL{% + \endgraf\vfil\eject\null + \nosection@true + \firstchappage@true +% \Reset\hl1{1}% + {\locallabel@ + \toks@{#1}\xdef\thechapter@{Chapters \thelabel@. \the\toks@\unskip}% +% \globalnew +% \newpre\hl1{For Chapter \thelabel@}% + \global\setbox\z@\vbox{\Let@\tabskip\hss@ + \halign to\hsize{\bf\hfil\ignorespaces##\unskip\hfil\cr + {\ifx\thelabel@@\empty\else Chapters \thelabel@@\null + \punct@.\addspace@\enspace\fi}% + #1\crcr}}}\unvcopy\z@\nobreak\vskip\baselineskip + \firstparflush@ +} + +\expandafter\def\csname HL@I2\endcsname{\Reset\hl1{1}} +% \newpre\hl1{For Chapter }}%\xdef\TheHLpref@{\pref}} + +\def\altsection#1{\def\hltype@{\section}\def\hlname@{\section}% + \def\entry@{#1}% + \gdef\hllevel@{1}{\noexpands@ + \ifx\hltype@\relax + \global\advance\hl@@C\@ne + \xdef\Thelabel@@@{\number\hl@@C}% + \xdefThelabel@{\hl@@N}% + \xdef\Thelabel@@@@{\hl@@P\Thelabel@\hl@@Q}% + \xdefThelabel@@{\hl@@S}% + \else + \global\advance\hl@@@C\@ne + \xdef\Thelabel@@@{\number\hl@@@C}% + \xdefThelabel@{\hl@@@N}% + \xdef\Thelabel@@@@{\hl@@@P\Thelabel@\hl@@@Q}% + \xdefThelabel@@{\hl@@@S}% + \fi + \xdef\Thepref@{\Thelabel@@@@}}% + \nosection@false + \medbreak\noindent + {\locallabel@ + \toks@=\expandafter{\thelabel@. #1}\mark{For Chapter \the\toks@}% + \bfit For Chapter \thelabel@\null. + \ignorespaces#1\unskip\punct@.\addspace@\enspace}% + \hltoc@\let\hltype@\relax\nopunct@false\ignorespaces} + + + + +\headline={\def\label#1{\prevanish@\postvanish@}% + \ifpart@\hfil\else +\iffirstchappage@\hfil\else + \ifodd\pageno\hfil + \tenit\ifnosection@ Chapter \thechapter@\else\botmark\fi + \hfil + \llap{\tenbf\number\pageno}\else + \rlap{\tenbf\number\pageno}\hfil\tenit Chapter \thechapter@\hfil\fi\fi\fi} + +%\tracingonline1 + + + + +\def\footnoterule{\kern-3\p@ + \hrule height1pt depth 0pt width 2truein \kern2\p@} + +\def\2{\allowdisplaybreak} + +\def\CS#1{{\tt\bs#1}} + +\def\bibtex{\if\pointsize@ t% + B{\eightrm IB}\kern-.1em\tex\else + \if\pointsize@ n% + B{\sevenrm IB}\kern-.1em\tex\else +\if\pointsize@ e% + B{\sixrm IB}\kern-.1em\tex\else + \errmessage{Can't print this at this point size}\fi\fi\fi} + +\def\8#1\8{\pagelabel{#1}} + + +\newcounter\pitemno +\newstyle\pitemno#1{{\rm(}#1\/{\rm)}} +\usecounter\pitemno\pitem#1{\par#1\space\ignorespaces} +\def\Pitem{\Reset\pitemno1 \pitem} + + + + +\catcode`\@=\active |