summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/generic/pictex/postpictex.tex
blob: d46612a862d93ecac7f3fbcbe8301ad8b6e6b640 (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
% This is postpictex.tex  Version 1.1  9/10/87

% To use the PiCTeX macros under LaTeX, you first need to \input the
% file prepictex.tex, then the main corpus of PiCTeX macros (pictex.tex), 
% and finally this file.  Do not \input the file latexpicobjs.tex.
 
\catcode`@=11 \catcode`!=11
  
% Save meanings of PiCTeX keywords that duplicate LaTeX keywords
\let\!pictexendpicture=\endpicture 
\let\!pictexframe=\frame
\let\!pictexlinethickness=\linethickness
\let\!pictexmultiput=\multiput
\let\!pictexput=\put

% Redefine the PiCTeX \beginpicture macro
\def\beginpicture{%
  \setbox\!picbox=\hbox\bgroup%
  \let\endpicture=\!pictexendpicture
  \let\frame=\!pictexframe
  \let\linethickness=\!pictexlinethickness
  \let\multiput=\!pictexmultiput
  \let\put=\!pictexput
  \let\input=\@@input   % \@@input is LaTeX's saved version of TeX's primitive
  \!xleft=\maxdimen  
  \!xright=-\maxdimen
  \!ybot=\maxdimen
  \!ytop=-\maxdimen}

% Reestablish LaTeX's meaning of \frame. This makes
% PiCTeX's meaning of \frame available only inside a PiCture.
\let\frame=\!latexframe

% Make PiCTeX's meaning of \frame available everywhere in the
% guise of \pictexframe
\let\pictexframe=\!pictexframe

% Now do the same for \linethickness
\let\linethickness=\!latexlinethickness
\let\pictexlinethickness=\!pictexlinethickness

% Reset LaTeX's default meaning of \\
\let\\=\@normalcr
\catcode`@=12 \catcode`!=12