summaryrefslogtreecommitdiff
path: root/macros/generic/schemata/README
blob: 93c0a037d7990f6430191dd97f9841e03e816127 (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
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379

--------:| ----------------------------------------------------------------
schemata:| Generic package to aid construction of topical categories
  Author:| Charles P. Schaum
  E-mail:| charles dot schaum@comcast.net
 License:| Released under the LaTeX Project Public License v1.3c or later
     See:| http://www.latex-project.org/lppl.txt

Short description:
The schemata package helps the creation of topical outlines that illustrate the breakdown of concepts and categories in academic texts from the late medieval to early modern periods.

Files     Distribution

README        This file
schemata.pdf  Documentation
schematest.tex  Test file for Plain TeX or Eplain
schemata.png  Image file used for the manual

Makefile      Automates building with GNU make 3.81
schemata.dtx  Documented LaTeX file containing both code and documentation

Installation

Download the package from

https://www.ctan.org/tex-archive/macros/generic/schemata

Unpack schemata.zip in an appropriate directory.

If you have a make utility compatible with GNU make, either in
GNU/Linux, a BSD variant, OSX, or Cygwin in Windows you can type

make inst

to install the package into your $TEXMFHOME tree or

make install

to install the package into your $TEXMFLOCAL tree for all users.
The latter requires sudo privileges.

Other useful targets include:

(release process)

make release The default target, same as just ``make''.

make clean Removes all intermediate files. Left are
the files listed above plus schemata.sty.

make distclean Leave only schemata.dtx, schematest.tex,
schemata.png, and Makefile.

make zip Generate a zip file ready for distribution.

(testing process)

make testing Release files, plus compiles schematest.tex.

It is not necessary, however, to use GNU make. One can generate
the package files manually. Since the files schemata.ins and README.txt
are contained in the .dtx file itself, the first step is to generate
the installer driver schemata.ins, plus the file README.txt, which will
also trigger the extraction of schemata.sty and produce the first pass of
the package documentation schemata.pdf:

pdflatex -shell-escape -recorder -interaction=batchmode schemata.dtx

Next one adds a table of contents and all cross-references, this also
should finalize page numbers for glossary and index input files:

pdflatex --recorder --interaction=nonstopmode schemata.dtx

The next commands generate the glossary/index output files:

makeindex -q -s gglo.ist -o schemata.gls schemata.glo
makeindex -q -s gind.ist -o schemata.ind schemata.idx

The final two commands integrate the glossary (changes) and index:

pdflatex --recorder --interaction=nonstopmode schemata.dtx
pdflatex --recorder --interaction=nonstopmode schemata.dtx

Now one can either keep README.txt or rename it to README, e.g.:

mv README.txt README

Normally one creates the following directories for a user:

$TEXMFHOME/source/generic/schemata dtx file, schemata.png
$TEXMFHOME/doc/generic/schemata pdf file, README, schematest.tex,

and creates the following directories for the local site:

$TEXMFLOCAL/source/generic/schemata dtx file, schemata.png
$TEXMFLOCAL/doc/generic/schemata pdf file, README, schematest.tex,

The above environment variables often are /usr/local/texlive/texmf-local for
$TEXMFLOCAL and ~/texmf for $TEXMFHOME.

The make process normally renames the README.txt file created from the
dtx file to just README by using mv (move / rename utility in the *nix
userland). Windows distributions of TeX and LaTeX often keep the txt file
because of using file extensions instead of ``magic numbers'' to identify
files.

Run mktexlsr with the appropriate level of permissions to complete the
install.

This packages works with LaTeX and Plain TeX.

License

This material is subject to the LaTeX Project Public License:
http://www.ctan.org/tex-archive/help/Catalogue/licenses.lppl.html

Happy TeXing!
\ifx\fmtname\schemataLaTeX\else
  \catcode`@=11\relax
\fi
\newbox\@schemata@rhs
\newbox\@schemata@lhs
\newdimen\@schemata@rheight
\newdimen\@schemata@lheight
\newif\if@schemata@LCBox
\newif\if@schemata@SWBox
\newif\if@schemata@NudgeBox
\ifx\fmtname\schemataLaTeX
  \DeclareOption{braces}%
    {\let\@schemata@LD\lbrace \let\@schemata@RD\rbrace}
  \DeclareOption{brackets}%
    {\let\@schemata@LD\lbrack \let\@schemata@RD\rbrack}
  \DeclareOption{parens}%
    {\let\@schemata@LD( \let\@schemata@RD)}
  \DeclareOption{groups}%
    {\let\@schemata@LD\lgroup \let\@schemata@RD\rgroup}
  \ExecuteOptions{braces}
  \ProcessOptions\relax
\else
  \let\@schemata@LD\lbrace%
  \let\@schemata@RD\rbrace%
\fi
\ifx\fmtname\schemataLaTeX
  \newcommand*{\DoBraces}%
    {\let\@schemata@LD\lbrace \let\@schemata@RD\rbrace}
\else
  \def\DoBraces%
    {\let\@schemata@LD\lbrace \let\@schemata@RD\rbrace}
\fi
\ifx\fmtname\schemataLaTeX
  \newcommand*{\DoBrackets}%
    {\let\@schemata@LD\lbrack \let\@schemata@RD\rbrack}
\else
  \def\DoBrackets%
    {\let\@schemata@LD\lbrack \let\@schemata@RD\rbrack}
\fi
\ifx\fmtname\schemataLaTeX
  \newcommand*{\DoParens}%
    {\let\@schemata@LD( \let\@schemata@RD)}
\else
  \def\DoParens%
    {\let\@schemata@LD( \let\@schemata@RD)}
\fi
\ifx\fmtname\schemataLaTeX
  \newcommand*{\DoGroups}%
    {\let\@schemata@LD\lgroup \let\@schemata@RD\rgroup}
\else
  \def\DoGroups%
    {\let\@schemata@LD\lgroup \let\@schemata@RD\rgroup}
\fi
\ifx\fmtname\schemataLaTeX
  \newcommand*{\LCschema}{\@schemata@LCBoxtrue}
\else
  \def\LCschema{\@schemata@LCBoxtrue}
\fi
\ifx\fmtname\schemataLaTeX
  \newcommand*{\UCschema}{\@schemata@LCBoxfalse}
\else
  \def\UCschema{\@schemata@LCBoxfalse}
\fi
\ifx\fmtname\schemataLaTeX
  \newcommand*{\SwitchSB}{\@schemata@SWBoxtrue}%
\else
  \def\SwitchSB{\@schemata@SWBoxtrue}
\fi
\ifx\fmtname\schemataLaTeX
  \newcommand*{\NudgeSB}{\@schemata@NudgeBoxtrue}
\else
  \def\NudgeSB{\@schemata@NudgeBoxtrue}
\fi
\ifx\fmtname\schemataLaTeX
  \newcommand{\SBNudgeFactor}{\kern0.2em}
\else
  \def\SBNudgeFactor{\kern0.2em}
\fi
\ifx\fmtname\schemataLaTeX
  \newcommand*{\schemabox}[2][0pt]{\@schemata@schemabox[#1]{#2}}
\else
  \def\schemabox{\futurelet\testchar\@schemata@schemab@x}
  \def\@schemata@schemab@x{%
    \ifx[\testchar
      \let\next\@schemata@schemabox%
    \else
      \let\next\@schemata@@schemab@x%
    \fi
    \next%
  }%
  \def\@schemata@@schemab@x#1{\@schemata@schemabox[0pt]{#1}}
\fi
\def\@schemata@schemabox[#1]#2{%
  \ifinner
    \if@schemata@LCBox
      \def\@Adj{}%
      \if@schemata@SWBox\def\@Adj{\strut}\fi
    \else
      \def\@Adj{\strut}%
      \if@schemata@SWBox\def\@Adj{}\fi
    \fi
    \if@schemata@NudgeBox
      \let\@Nudge\SBNudgeFactor%
    \else
      \def\@Nudge{}%
    \fi
    \ifdim#1<1pt
      \def\\{\@Nudge\egroup\hbox\bgroup\ignorespaces }%
      \vbox{\hbox\bgroup\@Adj\ignorespaces #2\@Nudge\egroup}%
    \else
      \def\\{\hfil\egroup\hbox to #1\bgroup\ignorespaces }%
      \vbox{\hbox to #1\bgroup\@Adj\ignorespaces #2\hfil\egroup}%
    \fi
  \else
    #2%
  \fi
  \@schemata@SWBoxfalse%
  \@schemata@NudgeBoxfalse%
}
\ifx\fmtname\schemataLaTeX
  \newcommand{\schema}[3][open]{%
    \@schemata@schema[#1]{#2}{#3}}
\else
  \long\def\schema{\futurelet\testchar\@schemata@schem@}
  \long\def\@schemata@schem@{%
    \ifx[\testchar
      \let\next\@schemata@schema%
    \else
      \let\next\@schemata@@schem@%
    \fi
    \next%
  }%
  \long\def\@schemata@@schem@#1#2{%
    \@schemata@schema[open]{#1}{#2}}
\fi
\long\def\@schemata@schema[#1]#2#3{%
  \def\@ption{#1}\def\@pen{open}%
  \ifx\@ption\@pen
    \setbox\@schemata@rhs=\vbox{#3}%
    \@schemata@rheight=\ht\@schemata@rhs%
    \advance\@schemata@rheight\dp\@schemata@rhs%
    \advance\@schemata@rheight by 1.44265ex%
    \hbox{$\vcenter{#2}%
      \@schemata@lbrace{\@schemata@rheight}%
      \vcenter{#3}$}%
  \else
    \setbox\@schemata@lhs=\vbox{#2}%
    \@schemata@lheight=\ht\@schemata@lhs%
    \advance\@schemata@lheight\dp\@schemata@lhs%
    \advance\@schemata@lheight by 1.44265ex%
    \hbox{$\vcenter{#2}%
      \kern-0.2em\@schemata@rbrace{\@schemata@lheight}%
      \vcenter{#3}$}%
  \fi
}
\ifx\fmtname\schemataLaTeX
  \newcommand{\Schema}[5][open]{%
    \@schemata@Schema[#1]{#2}{#3}{#4}{#5}}
\else
  \long\def\Schema{\futurelet\testchar\@schemata@Schem@}
  \long\def\@schemata@Schem@{%
    \ifx[\testchar
      \let\next\@schemata@Schema%
    \else
      \let\next\@schemata@@Schem@%
    \fi
    \next%
  }%
  \long\def\@schemata@@Schem@#1#2#3#4{%
    \@schemata@Schema[open]{#1}{#2}{#3}{#4}}
\fi
\long\def\@schemata@Schema[#1]#2#3#4#5{%
  \def\@ption{#1}%
  \def\@pen{open}%
  \dimen0=#2%
  \ifx\@ption\@pen
    \hbox{$\vcenter{\vskip1.44265\dimen0#4}%
      \@schemata@biglbrace{#2}{#3}\vcenter{#5}$}%
  \else
    \hbox{$\vcenter{\vskip1.44265\dimen0#4}\kern-0.2em%
      \@schemata@bigrbrace{#2}{#3}\vcenter{#5}$}%
  \fi
}
\ifx\fmtname\schemataLaTeX
  \newcommand*{\@schemata@lbrace}[1]{%
    \ifmmode
      \left.\vcenter{\vbox to #1{\vfil}}\right\@schemata@LD%
    \fi
  }
\else
  \def\@schemata@lbrace#1{%
    \ifmmode
      \left.\vcenter{\vbox to #1{\vfil}}\right\@schemata@LD%
    \fi
  }
\fi
\ifx\fmtname\schemataLaTeX
  \newcommand*{\@schemata@rbrace}[1]{%
    \ifmmode
      \left\@schemata@RD\vcenter{\vbox to #1{\vfil}}\right.%
    \fi
  }
\else
  \def\@schemata@rbrace#1{%
    \ifmmode
      \left\@schemata@RD\vcenter{\vbox to #1{\vfil}}\right.%
    \fi
  }
\fi
\ifx\fmtname\schemataLaTeX
  \newcommand*{\@schemata@biglbrace}[2]{%
    \@schemata@@biglbrace{#1}{#2}}
\else
  \def\@schemata@biglbrace#1#2{%
    \@schemata@@biglbrace{#1}{#2}}
\fi
\def\@schemata@@biglbrace#1#2{%
  \dimen0=#1%
  \dimen2=#2%
  \dimen4=-\dimen2%
  \ifdim\dimen4>\dimen2\dimen2=\dimen4\fi
  \ifdim\dimen0<0pt
    \ifmmode\vcenter{\hbox{$\left.%
      \vbox to 1.44265\dimen2{\vfil}%
      \right\@schemata@LD%
      \atop\vbox to -1.44265\dimen0{\vfil}$}}\fi
  \else
    \ifmmode\vcenter{\hbox{$\vbox to 1.44265\dimen0{\vfil}%
      \atop\left.%
      \vbox to 1.44265\dimen2{\vfil}%
      \right\@schemata@LD$}}\fi
  \fi
}
\ifx\fmtname\schemataLaTeX
  \newcommand*{\@schemata@bigrbrace}[2]{%
    \@schemata@@bigrbrace{#1}{#2}%
  }
\else
  \def\@schemata@bigrbrace#1#2{%
    \@schemata@@bigrbrace{#1}{#2}%
  }
\fi
\def\@schemata@@bigrbrace#1#2{%
  \dimen0=#1%
  \dimen2=#2%
  \dimen4=-\dimen2%
  \ifdim\dimen4>\dimen2\dimen2=\dimen4\fi
  \ifdim\dimen0<0pt
    \ifmmode\vcenter{\hbox{$\left.%
      \vbox to 1.44265\dimen2{\vfil}%
      \right\@schemata@RD%
      \atop\vbox to -1.44265\dimen0{\vfil}$}}\fi
  \else
    \ifmmode\vcenter{\hbox{$\vbox to 1.44265\dimen0{\vfil}%
      \atop\left.%
      \vbox to 1.44265\dimen2{\vfil}%
      \right\@schemata@RD$}}\fi
  \fi
}
\ifx\fmtname\schemataLaTeX\else
  \catcode`@=12\relax
\fi