blob: e0d81a168b59c9ea688e13a40dbb5bdaa4bcce8f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
|
%-*-tex-*-
% some macros for english/french side by side
\def\coltol{\pretolerance=5000 \tolerance=5000 \hbadness=5000 }
\newbox\leftbox
\newbox\leftrembox
\newbox\rightbox
\newbox\rightrembox
\newbox\tempbox
\newif\ifboxsplit % if either box is split
\newif\ifcolsplit % if this col is being split
\newdimen\remsplit
\newdimen\rempage
\newdimen\colsize \colsize=2.8in
\let\dbmess=\message
\def\dbmess#1{}
\raggedbottom
\def\splitparms #1{\remsplit=\pagegoal \advance\remsplit by -\pagetotal \relax
\rempage=\remsplit
\ifdim\pageshrink<10pt \advance\remsplit by -10pt\fi
\advance\rempage by -\ht#1
\advance\rempage by -\dp#1 \colsplitfalse
\ifdim\rempage<0pt \ifdim\remsplit>0pt \colsplittrue \fi\fi
\dbmess{<<rs \the\remsplit* rp \the\rempage *ps \the\pageshrink>>}}
% general column form #1 \right(left)box #2 \right(\left)rembox #3 type
% #4 input
\def\colform #1#2#3#4{\setbox#1=\vtop{\hsize \colsize \coltol #3#4}
\splitparms{#1}\ifcolsplit\dbmess{<<col split \the\ppnum>>}
\boxsplittrue\setbox\tempbox=\vsplit
#1 to \remsplit \fi
\ifvoid\tempbox \else
\setbox#2=\vtop{\unvbox#1}\relax
\setbox#1=\vtop{\unvbox\tempbox}\fi
\dbmess{** tbx r ** rrh \the\ht#1
* rh \the\ht#2
* drh \the\dp#1
* dh \the\dp#2 }}
% right and left forms
\long\def\rightform #1{\colform{\rightbox}{\rightrembox}{\fhyph}{#1\endgraf}}
\long\def\leftform #1{\colform{\leftbox}{\leftrembox}{\ehyph}{#1\endgraf}}
\newcount\ppnum
\long\def\pp #1@@#2!!{\advance\ppnum by 1 \dbmess{<< pp num \the\ppnum>>}
{\def\pp{\dbmess{<<Possible @@ or !! error>>}}\vskip \parskip
\boxsplitfalse\leftform{#1}\rightform{#2}\relax
\line{\box\leftbox\hss\box\rightbox}\relax
\ifboxsplit
\line{\box\leftrembox\hss\box\rightrembox}
\dbmess{<<End Splitbox \the\ppnum>>}\fi
}}
\def\seh#1#2#3{\pp\innershead{#1}{#2}@@\autonumberingoff
\innershead{\qref{#1}.}{#3}!!\nobreak\mark{#2/#3}\nobreak}
\def\sseh#1#2#3{\pp\innersshead{#1}{#2}@@\autonumberingoff
\innersshead{\qref{#1}}{#3}!!\nobreak\mark{#2/#3}\nobreak}
\def\ssseh#1#2#3{\pp\innerssshead{#1}{#2}@@\autonumberingoff
\innerssshead{\qref{#1}}{#3}!!\nobreak\mark{#2/#3}\nobreak}
\def\dssseh#1#2{\pp\innerdssshead{#1}@@
\innerdssshead{#2}!!\nobreak\mark{#1/#2}\nobreak}
\let\dsh=\dssseh
%\tracingpages=1
% --- header stuff ----
\headertext{\ifodd\pageno\rightheadertext
\else\leftheadertext\fi}
\def\rightheadertext{\line{\hss
\firstmark\rlap{\ssheadfont\qquad\folio}}}
\def\leftheadertext{\line{\llap{\ssheadfont\folio
\qquad}\firstmark{ }\hss}}
\documentstyle{\normalheaderstyle
\vheadersize=.35in
\normalfooterstyle
\vfootersize=.35in}
% Autonumbering ... referencing sections paragraphs
\newautonum{art}
\def\pn{{\bf \autoartnum{}} }
\def\pntag#1{\autoartnum{#1}}
\def\rpn{{\bf \the\artnum } }
% Toc forms change
\let\idssshtoc=\shtoc
\let\ishtoc=\shtoc
\def\shtoc #1#2#3 \shtoc #4#5#6{\pp \ishtoc{#1}{#2}{#3}@@\ishtoc{#4}{#5}{#6}!!}
\let\isshtoc=\sshtoc
\def\sshtoc #1#2#3 \sshtoc #4#5#6{\pp \isshtoc{#1}{#2}{#3}@@\isshtoc{#4}{#5}{#6}!!}
\let\issshtoc=\ssshtoc
\def\ssshtoc #1#2#3 \ssshtoc #4#5#6{\pp \issshtoc{#1}{#2}{#3}@@\issshtoc{#4}{#5}{#6}!!}
% like section heads .. minor indent
\def\dssshtoc #1#2#3 \dssshtoc #4#5#6{\pp \idssshtoc{#1}{#2}{#3}@@\idssshtoc{#4}{#5}{#6}!!}
\parindent=0pt \parskip=2.8ex % block mode
|