summaryrefslogtreecommitdiff
path: root/macros/ytex/ytex.mac
blob: 3fb03e09820ca235e48c2ff6b43701b7d0d15b1f (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
% Copyright (c) 1985, 1986 Daniel C. Brotsky.  All rights reserved.
% The yTeX macros.  Written and maintained by DCB@MIT-AI.ARPA
% Questions, suggestions, bug reports by net mail to BUG-YTEX@MIT-AI.ARPA

\ifx \fmtname\completelyundefinedcontrolsequence
  \input yplain.mac \fi                 % load a Plain format if needed

\message{[Loading the YTEX macros:}

% CONTENTS

% ^L-page       contents
% ----------------------------------------------------------------------
% 1             %% YTEX macros
% 2             %% setup
% 3             %% Load the library
% 4             %% Load the fonts
% 5             %% Load the user level
% 6             %% miscellany
% 7             %% initialization

%% setup

% @ used in macros
\def\makeatletter {\catcode`\@=11\relax}
\def\makeatother {\catcode`\@=12\relax}
\makeatletter

% conditional message output
\newif\ifyinfo
\newif\ifywarn
\newif\ifydebug
\def\ymessage #1{\ifyinfo \message{#1}\fi}
\def\ywarning #1{\ifywarn \message{#1}\fi}
\def\ybuginfo #1{\ifydebug \message{#1}\fi}

% preserve def of \input
\let\@@input=\input

%% Load the library

\message{(BASE)}
\@@input ybase.mac

%% Load the fonts

\message{(FONTS)}
\@@input yfonts.mac

%% Load the user level

\message{(USER)}
\@@input yuser.mac

%% miscellany

% library location
\def\ytexlibrary {}

% name of this TeX
\def\yTeX {\leavevmode\lower.5ex\hbox{Y}\kern-.1667em\TeX}
\def\ytex {\yTeX}
\let\YTEX=\ytex
\let\YTeX=\ytex
\let\oopstex=\ytex

%% initialization

% format name, version, and site modifications
\ifx \fmtname\completelyundefinedcontrolsequence
  \def\fmtname{yTeX}\fi
\@@input ylog.mac
\@@input ysite.mac

% read fixes and augmentations to these macros
\everyjob={%
  \ymessage{{YTEX version \fmtversion}}%
  \st@rttime
  \makeatletter
  \@input{\ytexlibrary yfix.mac}{\ymessage{{No fixes}}}%
  \makeatother
  \@input@{ymath}{}%
  \@input@{ylocal}{}%
  }

% no user @ in macro names, print messages only
\makeatother
\yinfotrue
\ywarntrue
\ydebugfalse

\message{(DONE)]}