summaryrefslogtreecommitdiff
path: root/support/glosstex/glosstex.dtx
blob: 0a1c20e8deb5a12559b038d4859d2a96afa0e115 (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
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
% \iffalse -*- latex -*-
%
% $Id: glosstex.dtx,v 1.57 1997/12/24 18:48:47 volkan Exp $
%
%   GlossTeX, a tool for the automatic preparation of glossaries.
%   Copyright (C) 1997 Volkan Yavuz
%
%   This program is free software; you can redistribute it and/or
%   modify it under the terms of the GNU General Public License
%   as published by the Free Software Foundation; either version 2
%   of the License, or (at your option) any later version.
%
%   This program is distributed in the hope that it will be useful,
%   but WITHOUT ANY WARRANTY; without even the implied warranty of
%   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
%   GNU General Public License for more details.
%
%   You should have received a copy of the GNU General Public License
%   along with this program; if not, write to the Free Software
%   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
%
%   Volkan Yavuz, yavuzv@rumms.uni-mannheim.de
%
%% \CharacterTable
%%  {Upper-case    \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
%%   Lower-case    \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
%%   Digits        \0\1\2\3\4\5\6\7\8\9
%%   Exclamation   \!     Double quote  \"     Hash (number) \#
%%   Dollar        \$     Percent       \%     Ampersand     \&
%%   Acute accent  \'     Left paren    \(     Right paren   \)
%%   Asterisk      \*     Plus          \+     Comma         \,
%%   Minus         \-     Point         \.     Solidus       \/
%%   Colon         \:     Semicolon     \;     Less than     \<
%%   Equals        \=     Greater than  \>     Question mark \?
%%   Commercial at \@     Left bracket  \[     Backslash     \\
%%   Right bracket \]     Circumflex    \^     Underscore    \_
%%   Grave accent  \`     Left brace    \{     Vertical bar  \|
%%   Right brace   \}     Tilde         \~}
%%
%<*!ist>
\def\filename{glosstex}
\def\fileversion{0.4}
\def\filedate{1997/12/13}
\let\docdate=\filedate
%</!ist>
%<*driver>
\documentclass{ltxdoc}
\usepackage{array}
\usepackage{glosstex}

\OnlyDescription
\CodelineIndex
%\EnableCrossrefs

\setlength{\arrayrulewidth}{0.4pt}
\setlength{\doublerulesep}{0pt}

\newcommand{\GloTeX}{Glo\TeX}
\newcommand{\MakeIndex}{\textsc{MakeIndex}}
\newcommand{\unix}{\textsc{Unix}}
\newcommand{\package}[1]{\textsf{#1}}
\newcommand{\file}[1]{\texttt{#1}}
\newcommand{\opt}[1]{$[$#1$]$}
\newcommand{\teTeX}{\textrm{te}\TeX}

\newenvironment{definition}{\begin{quote}}{\end{quote}}
\newenvironment{example}{\begin{quote}}{\end{quote}}

\begin{document}
\DocInput{glosstex.dtx}
%\PrintIndex
\end{document}
%</driver>
%
% \fi
%
% \CheckSum{1369}
%
% \title{\GlossTeX{} \fileversion}
% \author{\scshape Volkan Yavuz\footnote{e-mail: yavuzv@rumms.uni-mannheim.de}}
% \date{\filedate}
% \maketitle
%
% \begin{abstract}
%  \GlossTeX{} is a tool for the preparation of glossaries, lists of
%  acronyms or sorted lists in general. It greatly
%  simplifies this task. One or more glossary-definition files serve as
%  databases which contain descriptions of terms. These terms are
%  identified through labels. Based upon labels set into the
%  \TeX{}-source, \GlossTeX{} determines which entries have to appear in
%  the typeset list. \GlossTeX{} uses \MakeIndex{} for the sorting of the
%  lists. References to the place where a term appears in the text
%  can be set in the list. A term consists of a label which is
%  used to identify it, an optional item describing the typeset
%  output, an optional long-form and the actual text representing
%  it. There are many ways to access each of these fields within
%  the document. It is also possible to generate cross-references 
%  to another term. \GlossTeX{} is well customizable in respect to
%  the produced output.
% \end{abstract}
%
% \tableofcontents
% \listoftables
% \printglosstex(acr)
%
% \section{Introduction}
% \subsection{Purpose}
% \GlossTeX{} is a tool for the automatic preparation of glossaries,
% lists of acronyms, nomenclature and sorted lists in general. Based
% upon the labels set into the \TeX{}-source, \GlossTeX{} determines
% which entries from a glossary-definition file have to be processed
% to generate the list. \GlossTeX{} then creates an intermediate file
% that has to be processed by \MakeIndex{} for sorting. The output of
% \MakeIndex{} is then included into the \TeX{}-source for
% typesetting. With each term associated is an item representing the
% typeset output, an optional long-form if it's an acronym and an
% optional descriptive text. These elements can all be accessed within
% the document in many ways.
%
% \subsection{History}
% I created \GlossTeX{} because there were no tools for the
% preparation of glossaries that fit my needs. \GlossTeX{} is mainly a
% combination of the features of the packages \package{acronym},
% \package{nomencl} and \GloTeX{}. The commands starting with |\ac|
% are taken more or less directly from \package{acronym} and the way
% \GlossTeX{} handles page references is almost identical to the way
% \package{nomencl} does. The use of glossary databases is inspired by
% \GloTeX{}.
%
% \subsection{Legalise}
% \GlossTeX{} is provided ``as is'' and comes with absolutely no
% warranty. It is covered by the GNU General Public License (see the
% file |COPYING| that comes with this package).
%
% \begin{center}
%   \noindent\copyright\ Volkan Yavuz, 1997
% \end{center}
%
% \section{Building and Installation}
% First, you need to build glosstex from its C sources. Note that you
% need an ANSI C compiler. If you have
% MAKE and a decent OS (speak \unix{}), typing |make| from the shell
% should build the binary (have a 
% look at the various makefiles, namely |Makefile| (which is my rather
% complex development version that may not run on your system setup),
% |Makefile.unx| (which is the most generic one) and
% |Makefile.os2|). Also have a look at the start of the makefiles
% where you will find some variables to be customized. The most
% important ones may be |CC| and |SHELL|. You may also want to have a
% look at |config.h|.
%
% If you don't
% have MAKE get it right now or just issue 
% these commands: 
%
% \begin{example}
%   |cc -c database.c -o database.o|\\
%   |cc -c error.c -o error.o|\\
%   |cc -c labels.c -o labels.o|\\
%   |cc -c list.c -o list.o|\\
%   |cc -c main.c -o main.o|\\
%   |cc -c version.c -o version.o|\\
%   |cc database.o error.o labels.o list.o main.o version.o -o glosstex|
% \end{example}
%
% Now just move the resulting binary to a directory where your other
% binaries live. After that you need to unpack |glosstex.dtx|. Do this
% by invoking
% \begin{example}
%   |latex glosstex.ins|
% \end{example}
%
% which will produce some more files. You will have to move them
% to their proper places according to your particular
% \TeX{}-installation. The instructions that will appear on the
% screen should give you a good start.
%
% \subsection{A Goodie for \teTeX{} User}
% If you are using \textsc{Thomas Esser}'s fantastic \teTeX{} system,
% \GlossTeX\ has some good news for you. \GlossTeX\ comes with a
% kpathsea shell-wrapper which supports path searching. For this to
% work, rename |glosstex| to |glosstex.bin| and |glosstex.sh| to
% |glosstex|. Put them somewhere convenient. Now add a line of the
% form
% \begin{example}
% |GDFINPUTS = $KPSE_DOT:$TEXMFS/glosstex//|
% \end{example}
% in you |texmf.cnf| file. That's it!
%
% If you get problems, the following notes may help you. 
% First check whether
% \begin{example}
%  |kpsetool -v -n glosstex '$GDFINPUTS'|
% \end{example}
% and 
% \begin{example}
%  |kpsetool -v -n tex '$GDFINPUTS'| 
% \end{example}
%
% do what you want, i.e.\ their output
% should be equal. These won't find your \teTeX{} |texmf| tree (where
% your |texmf.cnf| file lives) if |glosstex| is not in something like
% |teTeX/bin| or |teTeX/bin/i386-linux|. In these cases, replace
% \begin{example}
% |TETEXDIR = $SELFAUTOPARENT| 
% \end{example}
% in |texmf.cnf| with something like
% \begin{example}
% |TETEXDIR = /usr/local/lib/teTeX|.
% \end{example}
%  This makes sure that the proper |texmf| tree is found, even if
%  |glosstex| is not in the \teTeX{} 
% |texmf| tree but in your local |texmf| tree.
% 
% You also need symbolic links from e.\,g.\ 
% |/usr/local/lib/localTeX/texmf.cnf| to your \teTeX{} |texmf.cnf|. This
% is because kpathsea looks for |texmf.cnf| in the tree where the
% binary was found.
%
% These instructions should apply to \teTeX{} version 0.4 or newer.
%
% \section{Usage}
% The \LaTeX{}-macros needed by \GlossTeX{} have to be included into
% the source using
%
% \begin{example}
%   |\usepackage|\opt{|[|\meta{options}|]|}|{glosstex}|
% \end{example}
%
% Valid \meta{options} are listed in table \ref{tab:options}.
%
% \begin{table}[htbp]
% \begin{center}
% \begin{tabular}{>{\ttfamily}ll}
% \hline\hline
% \rmfamily Option & Discussed in section\\
% \hline
% refpage, \textit{norefpage} &\ref{sec:page_references}\\
% \textit{itemfirst}, longfirst &\ref{sec:order}\\
% \textit{text}, footnote &\ref{sec:footnotes}\\
% \textit{roundparen}, squareparen&\ref{sec:parentheses}\\
% \hline\hline
% \end{tabular}
% \caption[Package options.]{Package options. Defaults are set in
% \textit{italics}.}
% \label{tab:options}
% \end{center}
% \end{table}
%
% Whenever you want a term to appear in the glossary, you insert
% \DescribeMacro{\glosstex}
% \begin{definition}
%   |\glosstex|\opt{|(|\meta{list}|)|}\opt{|[|\meta{pageref-mode}|]|}|{|\meta{label}|}|
% \end{definition}
%
% into the text. \meta{label} references the entry and the optional
% arguments \meta{pageref-mode} and \meta{list} determine the mode for
% page references\footnote{Page references are described in section
% \ref{sec:page_references}. \meta{pageref-mode} works in conjunction
% with the optional arguments |refpage| and |norefpage| to the package
% and defaults to |p|. \meta{list} defaults to |glo|.} and the list
% the referenced term should appear in.
%
% But you can create $n$ independent lists and make each \meta{label}
% appear in any \meta{list}, each appearance independent of the other
% ones. To facilitate the creation of multiple \meta{list}s and
% especially make it easy to achieve the most likely usage, there are
% actually two sets of commands. One set starting with |\gl| defaults
% to \meta{list} |glo| (which stands for glossary) and
% \meta{pageref-mode} |p|, the other set starting with |\ac| defaults
% to \meta{list} |acr| (list of acronyms) and \meta{pageref-mode}
% |n|. The following is the equivalent to |\glosstex| for acronyms:
%
% \DescribeMacro{\acronym}
% \begin{definition}
%   |\acronym|\opt{|(|\meta{list}|)|}\opt{|[|\meta{pageref-mode}|]|}|{|\meta{label}|}| 
% \end{definition}
%
% These two commands can also be called as |\glosstex{*}| and
% |\acronym{*}| to include all terms found in the |.gdf|-files into
% the corresponding \meta{list}. This is similar to the command
% |\nocite{*}| in \BibTeX{} and is primarily meant for debugging
% purposes. But do \emph{not} use something like |\gls{*}| (see
% below).
%
% There is another set of commands that produce both an entry in the
% list (this is optional) and typeset output. 
%
% \DescribeMacro{\gls}
% \DescribeMacro{\gls*}
% \begin{definition}
%   |\gls|\opt{|*|}\opt{|(|\meta{list}|)|}\opt{|[|\meta{pageref-mode}|]|}|{|\meta{label}|}|
% \end{definition}
%
% |\gls| typesets \meta{item} and produces a list entry (\meta{list}
% defaults to |glo|).  The starred version |\gls*| just produces
% typeset output without a list-entry.\footnote{To be honest, a
% list-entry is produced, but it never appears in the output. The
% starred version implicitly produces entries with \meta{list-mode}
% |n| (never appear in typeset \meta{list}) while the unstarred
% versions set \meta{list-mode} to |a| (always appear). There is no
% other way of specifying the \meta{list-mode} of an \meta{label}.}
%
% \DescribeMacro{\ac}
% \DescribeMacro{\ac*}
% \DescribeMacro{\acs}
% \DescribeMacro{\acs*}
% \DescribeMacro{\acl}
% \DescribeMacro{\acl*}
% \DescribeMacro{\acf}
% \DescribeMacro{\acf*}
% \begin{definition}
%   |\ac|\opt{|*|}\opt{|,|\meta{lparen}|,|\meta{rparen}|,|}\opt{|<|\meta{form}|>|}\opt{|(|\meta{list}|)|}\opt{|[|\meta{pageref-mode}|]|}|{|\meta{label}|}|\\
%   |\acs|\opt{|*|}\opt{|(|\meta{list}|)|}\opt{|[|\meta{pageref-mode}|]|}|{|\meta{label}|}|\\
%   |\acl|\opt{|*|}\opt{|(|\meta{list}|)|}\opt{|[|\meta{pageref-mode}|]|}|{|\meta{label}|}|\\
%   |\acf|\opt{|*|}\opt{|,|\meta{lparen}|,|\meta{rparen}|,|}\opt{|<|\meta{form}|>|}\opt{|(|\meta{list}|)|}\opt{|[|\meta{pageref-mode}|]|}|{|\meta{label}|}|
% \end{definition}
%
% These all produce typeset output. |\acs| typesets \meta{item},
% |\acl| typesets \meta{long-form} and |\acf| typesets \meta{full}
% (see section \ref{sec:format}). |\ac| works like |\acf| at it's first
% invocation and like |\acs| on all subsequent ones. Using |\ac| you
% can make sure that an acronym is always spelled out at least once in
% your document while safely using the short form whenever
% possible. Note that the use of |\acf| has no effect on subsequent
% invocations of |\ac|. The starred versions |\ac*|, |\acs*|, |\acl*|
% and |\acf*| 
% just produce typeset output. Table~\ref{tab:commands} gives an
% overview of all this.
%
% \begin{table}[htbp]
%  \begin{center}
%    \begin{tabular}{rllll}
%      \hline\hline
%      defaults & list & list and text & text & output\\
%      \hline
%      |(glo)[p]| & |\glosstex| & |\gls| & |\gls*| & \meta{item}\\
%      |(acr)[n]| & |\acronym| & |\ac| & |\ac*| 
% & \meta{item} or \meta{full}\\
%      |(acr)[n]| & & |\acs| & |\acs*| & \meta{item}\\
%      |(acr)[n]| & & |\acl| & |\acl*| & \meta{long-form}\\
%      |(acr)[n]| & & |\acf| & |\acf*| & \meta{full}\\
%      \hline\hline
%    \end{tabular}
%    \caption{Overview of the different sets of commands.}
%    \label{tab:commands}
%  \end{center}
% \end{table}
%
% In the most simple case, \meta{full} will look like ``\meta{item}
% |(|\meta{long-form}|)|''. You can switch the order of \meta{item}
% and \meta{long-form} by using the options |itemfirst| and
% |longfirst|. If you rather like either in a footnote, try the option
% |footnote| instead of the default |text|. If you don't like the
% round parentheses, just use the optional arguments \meta{lparen},
% \meta{rparen} which are also described in section \ref{sec:format}.
%
% \subsection{The Glossary Definition File}
% A glossary-definition file\glosstex{gdf-file} (suffix |.gdf|) is
% needed which serves as a database for \GlossTeX{}, holding the
% actual descriptions of all terms. You can have $m$ |.gdf|-files that
% contain the definitions to the \meta{label}s you reference in your
% documents. Entries have the form
% \begin{definition}
%   |@entry{|\meta{label}\opt{|,|\meta{item}\opt{|,|\meta{long-form}}}|}| \opt{\meta{text}}
% \end{definition}
%
% where \meta{label} is used to identify the entry and \meta{text} may
% contain any amount of \TeX{}-source, being the actual definition of
% the item. You should know that \meta{label} is used to construct
% \TeX{}-macros, so it shouldn't contain funny characters or you will
% most likely get funny errors.  The optional argument \meta{item}
% describes the appearance of the item in the produced list. If
% omitted, it defaults to \meta{label}. It can be used when some
% special form of typesetting is wanted. \meta{item} can contain any
% \TeX{}-construct, as long as each ``|{|'' has a corresponding
% ``|}|'' or \GlossTeX{} will get confused. The same applies
% to \meta{long-form}, except that it defaults into an empty string if
% not specified.
%
% Following is the |.gdf|-file used for this documentation. Note the use of
% ``|~|'' as the quote-character. Also note that all lines
% until the first line starting with |@entry{| are
% ignored. Additionally, all lines starting with ``|%|'' are ignored,
% too. Thus they
% can serve as comments.
%    \begin{macrocode}
%<*gdf>
% -*- latex -*-

This is a database file for GlossTeX.

@entry{ist-file, \texttt{.ist}-file} Style file for \MakeIndex{},
describing the input and output format of read and written files.

@entry{gdf-file, \texttt{.gdf}-file} This file is the database file
containing definitions for Gloss\TeX{}.

@entry{gxs-file, \texttt{.gxs}-file} Intermediate file produced by
\GlossTeX{} to be processed by \MakeIndex{}.

@entry{glx-file, \texttt{.glx}-file} This file contains the sorted
lists, ready to be read by \LaTeX{}.

@entry{gxg-file, \texttt{.gxg}-file} This is the log-file produced by
the \GlossTeX{}-run. See also \glxref{glg-file}.

@entry{glg-file, \texttt{.glg}-file} This is the log-file produced by
the \MakeIndex{}-run. See also \glxref{gxg-file}.

@entry{ASCII, ASCII, American Standard Code for Information Interchange} 
A character encoding. See also \glxref{EBCDIC}.

@entry{EBCDIC, EBCDIC, Extended Binary Coded Decimals Interchange Code} 
A character encoding exclusively used on mainframes. See also
\glxref{ASCII}.
%</gdf>
%    \end{macrocode}
%
% \subsection{Invocation}
% After the first run of \LaTeX{}, the |.aux|-file contains all
% necessary information for the preparation of the glossary. \GlossTeX\
% is then invoked to read one or more |.gdf|-files and outputs all
% definitions that are referenced in the |.aux|-file. The output of
% \GlossTeX{} is then processed by \MakeIndex{} for sorting.
%
% \GlossTeX{} is invoked in a \unix{}-like environment using the
% following command
%
%\begin{example}
%  |glosstex |\meta{aux-file}| |\meta{gdf-file}| |\opt{\meta{gdf-file}\opt{...}}| |\opt{|-v|\opt{|0|\ldots|5|}} 
% \end{example}
%
% This produces 2 files as output, one \gls{gxs-file} to be input into
% \MakeIndex{} and a log-file with extension |.gxg|\glosstex{gxg-file}
% which contains more detailed information. The |-v| option selects
% how verbose \GlossTeX{} should be when writing the log-file. |-v| is
% equal to |-v4| and |-v2| is the default. |-v0| makes \GlossTeX{}
% shut his mouth and only report errors and |-v5| makes \GlossTeX{}
% really talkative.
%
% \MakeIndex{}  has to be invoked in this way
%
% \begin{example}
%   |makeindex |\meta{gxs-file}| -o |\meta{glx-file}| -s |glosstex.ist| |\opt{|-t |\meta{glg-file}}
% \end{example}
%
% The commands
%
% \begin{example}
% |glosstex thesis thesis.gdf master.gdf|\\
% |makeindex thesis.gxs -o thesis.glx -s glosstex.ist|
% \end{example}
%
% produce the final \gls{glx-file} which is then included by
% \DescribeMacro{\printglosstex}
% \begin{definition}
%  |\printglosstex|\opt{|(|\meta{list}|)|}\opt{|[|\meta{pageref-mode}|]|}
% \end{definition}
% during the next \LaTeX{}-run. The argument \meta{pageref-mode}
% supersedes the one given to the entries individually for each
% \meta{list} and defaults to |p|. You can turn on page references
% unconditionally for each \meta{list} individually by using
% \meta{pageref-mode} |a| and turn it off by using
% \meta{pageref-mode} |n| as argument to |\printglosstex|. See also
% table~\ref{tab:references} for an overview of these options.
% 
% Note that, no matter of how many \meta{list}s you produce, there is
% always exactly \emph{one} |.glx|-file which contains the entries of
% \emph{all} produced lists. 
%
% Depending on whether you use \meta{item}
% or \meta{long-form} in your text or you have cross-references, it
% may be necessary to run \LaTeX{} and \GlossTeX{} up to 4 times until
% all references are resolved. Watch out for warnings from
% \package{glosstex} during a \LaTeX{} run. Messages about unresolved
% \meta{label}s from \GlossTeX{} are caused by missing definitions in
% the |.gdf|-files.
%
% \subsection{Page References}
% \label{sec:page_references}
% You may want a reference in the list to the place where the term
% first appears in the text. This can be done using the optional
% argument \meta{pageref-mode} on \meta{item}-level and
% \meta{list}-level. These arguments in combination with the option to
% |\usepackage| control page references. Table \ref{tab:references}
% gives an overview of all possible combinations of these 3
% arguments.
%
% \begin{table}[htbp]
% \begin{center}
%  \begin{tabular}{l|ccc|ccc}
%    \hline\hline
%    \hfill list & & |refpage| & & & |norefpage|\\
%    entry & |a| & |p| & |n| & |a| & |p| & |n|\\
%    \hline
%    |a| & $\times$ & $\times$ & $-$ & $\times$ & $\times$ & $-$\\
%    |p| & $\times$ & $\times$ & $-$ & $\times$ & $-$ & $-$\\
%    |n| & $\times$ & $-$ & $-$ & $\times$ & $-$ & $-$\\
%    \hline\hline
%  \end{tabular}
%  \caption[Options controlling the appearance of page
%    references.]{Options controlling the appearance of page
%    references. A ``$\times$'' indicates that a reference is
%    produced.}
%  \label{tab:references}
% \end{center}
% \end{table}
%
% One possible usage of this feature: while debugging a document, turn
% on page references by using the option |refpage| to the
% package. Every entry included with the modes |a| (always) or the
% default |p| (package) will contain a reference. After debugging,
% remove the option |refpage| and only those entries that were
% included with mode |a| will still have a reference.
%
% \subsection{The Appearance of \protect\meta{full}}
% \label{sec:format}
% \meta{full} stands for the appearance of the typeset term in the
% text. The appearance of \meta{full} is controlled through the
% optional arguments \meta{lparen}, \meta{rparen} and \meta{form} to
% |\ac| and |\acf|. Additionally, these arguments work together with
% defaults set forth on \meta{list}-level and package level. The
% following sections shall shed some light on this topic.
%
% \subsubsection{The \protect\meta{order} of \protect\meta{item}s}
% \label{sec:order} 
% \DescribeMacro{\glxitemorderdefault}
% The options |itemfirst| and |longfirst| control which one of
% \meta{item} and \meta{long-form} should be typeset first. On
% \meta{list}-level, \meta{item-order} can be set using
% \begin{definition}
% |\glxitemorderdefault||{|\meta{list}|}||{|\meta{item-order}|}|
% \end{definition}
% \meta{item-order} may be either ``|i|'',
% ``|l|'' or empty. |i| first typesets \meta{item}, |l| first typesets
% \meta{long-form}. Omitting \meta{item-order} lets the defaults take
% effect. Table \ref{tab:item-order} gives an overview over each
% combination of the options for \meta{item-order}.
%
% \begin{table}[htbp]
% \begin{center}
%  \begin{tabular}{l|ccc|ccc}
%    \hline\hline
%    \hfill list & & |itemfirst| & & & |longfirst|\\
%    entry & |i| & $-$& |l| & |i| & $-$ & |l|\\
%    \hline
%    |i| & |i| & |i| & |l| & |i| & |i| & |l|\\
%    $-$ & |i| & |i| & |l| & |i| & |l| & |l|\\
%    |l| & |i| & |l| & |l| & |i| & |l| & |l|\\
%    \hline\hline
%  \end{tabular}
%  \caption{Options controlling \protect\meta{item-order}.}
%  \label{tab:item-order}
% \end{center}
% \end{table}
%
% \subsubsection{Placement of footnotes and \protect\meta{form}}
% \label{sec:footnotes}
% \DescribeMacro{\glxitemplacementdefault}
% The options |text| and |footnote| control where the second typeset
% output should go, either into the text or into a footnote.
% \begin{definition}
% |\glxitemplacementdefault||{|\meta{list}|}||{|\meta{item-placement}|}|
% \end{definition}
% sets this option on \meta{list}-level. \meta{item-placement} may be
% either |t|, |f| or empty. |t| typesets both parts into the text, |f|
% puts one part into a footnote. Omitting \meta{item-placement} lets
% the defaults for \meta{item-placement} take effect. See also table
% \ref{tab:item-placement} for an overview of all possible
% combinations.
%
% \begin{table}[htbp]
% \begin{center}
%  \begin{tabular}{l|ccc|ccc}
%    \hline\hline
%    \hfill list & & |text| & & & |footnote|\\
%    entry & |t| & $-$& |f| & |t| & $-$ & |f|\\
%    \hline
%    |t| & |t| & |t| & |f| & |t| & |t| & |f|\\
%    $-$ & |t| & |t| & |f| & |t| & |f| & |f|\\
%    |f| & |t| & |f| & |f| & |t| & |f| & |f|\\
%    \hline\hline
%  \end{tabular}
%  \caption{Options controlling \protect\meta{item-placement}.}
%  \label{tab:item-placement}
% \end{center}
% \end{table}
%
% The aforementioned \meta{form} is built by simply concatenating
% \meta{item-order} and \meta{item-placement}. You supply the
% \meta{form} argument to |\ac| and |\acf| by enclosing it in angle
% brackets, just like |\ac<if>{foo}| or |\ac<t>{bar}|. Please note that
% \meta{item-order} is specified \emph{before} \meta{item-placement}.
%
% \subsubsection{Encapsulation} \label{sec:parentheses} 
% \DescribeMacro{\glxparendefault}
% \DescribeMacro{\glxparenlistdefault}
% When using |t| for \meta{item-placement}, the second part is
% encapsulated within \meta{lparen} on the left and \meta{rparen} on
% the right. 
% \begin{definition}
% |\glxparendefault{|\meta{list}|}{|\meta{lparen}|}{|\meta{rparen}|}|
% \end{definition} 
% sets this option on package level. The options |roundparen| and
% |squareparen| may be used as well.
% \begin{definition}
% |\glxparenlistdefault{|\meta{list}|}{|\meta{lparen}|}{|\meta{rparen}|}|
% \end{definition}
% sets this option on \meta{list}-level. On \meta{item}-level these
% are supplied to |\ac| and |\acf| just like |\ac,(,),{foo}| or
% |\acf,--,--,<lt>{bar}|. It may look strange, but I was out of
% parentheses.
%
% \subsection{Cross-References}
% \DescribeMacro{\glxref}
% \DescribeMacro{\glxref*}
% \begin{definition}
% |\glxref|\opt{|*|}|{|\meta{item}|}|
% \end{definition}
% It may be useful to use cross-references in entries. Assume
% you have referenced |\glosstex{ascii}| which describes the term
% \ac{ASCII}. You may also want to include \ac*{EBCDIC} as an
% example for another character encoding. To achieve this, write this
% into the definition of \ac{ASCII}
%
% \begin{example}
% |See also \glxref{ebcdic}.|
% \end{example}
%
% and \GlossTeX{} then produces ``See also EBCDIC'' and also includes
% the definition for \ac*{EBCDIC} into the same list \ac{ASCII}
% appears in. Note 
% that |\glxref| is only available within the \meta{text} argument in
% the |.gdf|-file since it only makes sense within a
% \meta{list}. There is also a starred version |\glxref*| that doesn't
% produce typeset output.
%
% \subsection{\GlossTeX{} and \package{nomencl}}
% It is possible to use \package{nomencl} and \GlossTeX{} in one
% document without problems. The following commands show how to deal with documents using both
% \GlossTeX{} and \textsf{nomencl}.
% \begin{example}
% |latex thesis|\\
% |glosstex thesis thesis.gdf |\\
% |makeindex thesis.gxs -o thesis.glx -s glosstex.ist|\\
% |makeindex thesis.glo -o thesis.gls -s nomencl.ist|\\
% |latex thesis|
% \end{example}
%
% \section{Customizing}
% \subsection{Global}
% \GlossTeX{} can be customized by using the file |glosstex.cfg| which
% is automatically loaded if it is present. The file |glosstex.std| is
% the default configuration file that is absolutely mandatory to
% \GlossTeX{}'s proper working. It
% shows all aspects that are meant to be customized, so let's discuss
% it now.
%
% Each term that gets typeset either goes through |\GLX@output@short|
% or |\GLX@output@long|, depending whether it's the \meta{item} or
% \meta{long-form}. These macros each take 3 arguments and get called
% this way:
% \begin{definition}
%   |\GLX@output@short{|\meta{label}|}{|\meta{list}|}{|\meta{item}|}|\\
%   |\GLX@output@long{|\meta{label}|}{|\meta{list}|}{|\meta{long-form}|}|
% \end{definition}
%
% \begin{macro}{\GLX@output@short}
% \begin{macro}{\GLX@output@long}
% We just output \meta{item} as it is. See section
% \ref{sec:customizing_local} for some more elaborate implementation
% of this macro.
%    \begin{macrocode}
%<*std>
\newcommand{\GLX@output@short}[3]{#3}
\newcommand{\GLX@output@long}[3]{#3}
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\glosstexpage}
% This is used to typeset the page at the end of a definition. It uses
% |\pagename| so that should be defined elsewhere.
%    \begin{macrocode}
\newcommand{\glosstexpage}[1]{\nobreak{\itshape\pagename~#1}\nobreak}
%    \end{macrocode}
% \end{macro}
%
% \DescribeMacro{\glxgldefault}
% \DescribeMacro{\glxacdefault}
% These macros set the defaults for \meta{list} and
% \meta{pageref-mode} which the commands starting with |\gl| (except for
% |\glxref|, of course) and |\ac| are
% using.
%    \begin{macrocode}
\glxgldefault{glo}{p}
\glxacdefault{acr}{n}
%    \end{macrocode}
%
% \DescribeMacro{\glxitemorderdefault}
% \DescribeMacro{\glxitemplacementdefault}
% These macros set the defaults concerning \meta{item-placement} and
% \meta{item-order} in \meta{list}. We specify no default on
% \meta{list}-level.
%    \begin{macrocode}
\glxitemorderdefault{glo}{}
\glxitemplacementdefault{glo}{}
\glxitemorderdefault{acr}{}
\glxitemplacementdefault{acr}{}
%    \end{macrocode}
%
% \DescribeMacro{\glxparendefault}
% \DescribeMacro{\glxparenlistdefault}
% These macros set the defaults concerning \meta{lparen} and
% \meta{rparen} on package and \meta{list}-level, respectively. To set
% \meta{paren} on package level, you may as well use the options
% |roundparen| and |squareparen|. Because |roundparen| is the default
% option, this command is not used. As long as there is no
% \meta{paren}-default on \meta{list}-level, the default on
% package-level is used. So therefor, |\glxparenlistdefault| is not
% used here as well.
%    \begin{macrocode}
%\glxparendefault{(}{)}
%\glxparenlistdefault{glo}{-*}{*-}
%    \end{macrocode}
%
% \begin{macro}{\GLX@benv@glo}
% \begin{macro}{\GLX@eenv@glo}
% \begin{macro}{\GLX@item@glo}
% \begin{macro}{\GLX@benv@acr}
% \begin{macro}{\GLX@eenv@acr}
% \begin{macro}{\GLX@item@acr}
% Each \meta{list} gets embedded into |\GLX@benv@|\meta{list} and
% |\GLX@eenv@|\meta{list}, so these macros should provide a reasonable
% environment. Each line itself is typeset using
% |\GLX@item@|\meta{list} which gets called with 7 arguments.
% \begin{definition}
% |\GLX@item@|\meta{list}|{|\meta{label}|}||{|\meta{list}|}||{|\meta{long-form}|}||{|\meta{text}|}||{|\meta{list}|}||{|\meta{list-mode}|}||{|\meta{page-stuff}|}|
% \end{definition}
%    \begin{macrocode}
\newcommand{\GLX@benv@glo}{\begin{description}}
\newcommand{\GLX@eenv@glo}{\end{description}}
\newcommand{\GLX@item@glo}[7]{%
  \item[#2]\ifx#3\empty\else\emph{#3}\space\fi#4\space#7}
\newcommand{\GLX@item@acr@label}[1]{\mbox{#1}\dotfill}
\newcommand{\GLX@benv@acr}{
  \begin{list}{}{%
      \renewcommand{\makelabel}{\GLX@item@acr@label}%
      \setlength{\labelwidth}{7em}%
      \leftmargin\labelwidth \advance\leftmargin by \labelsep}}
\newcommand{\GLX@eenv@acr}{\end{list}}
\newcommand{\GLX@item@acr}[7]{%
  \item[\textsc{#2}]%
    \ifx#3\empty\else#3\quad\fi\ifx#4\empty\else#4\space\fi#7}
%    \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\glossaryname}
% \begin{macro}{\listacronymname}
% \begin{macro}{\pagename}
% These are defined to contain some default strings if they're not
% already defined (|\pagename| e.g.\ is defined trough \package{babel}).
%    \begin{macrocode}
\ifx\glossaryname\@undefined
  \def\glossaryname{Glossary}
\fi
\ifx\listacronymname\@undefined
  \def\listacronymname{List of Acronyms}
\fi
\ifx\pagename\@undefined
  \def\pagename{page}
\fi
%    \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \DescribeMacro{\glxheading}
% Each \meta{list} starts with an appropriate heading which is defined
% by 
% \begin{definition}
%   |\glxheading[|\meta{list}|]{|\meta{definition}|}|.
% \end{definition}
%    \begin{macrocode}
\ifx\chapter\@undefined
  \glxheading{glo}{\section*{\glossaryname}}
  \glxheading{acr}{\section*{\listacronymname}}
\else
  \glxheading{glo}{\chapter*{\glossaryname}}
  \glxheading{acr}{\chapter*{\listacronymname}}
\fi
%</std>
%    \end{macrocode}
%
% \subsection{Local}
% \label{sec:customizing_local}
% Now we need a local configuration file for this document. This is
% done by using a file named |glosstex.cfg|. 
% In |\GLX@output@short| we test whether we are in the list of acronyms
% (|GLX@acdef@list|) and typeset \meta{item} with caps and small caps
% if we are. Otherwise, just typeset \meta{item}.
% We also define a call
%  to |\index| in |\GLX@output@short|. As sort-key, we use
% \meta{label}. Instead of the usual |@| we use |=| for designating
% the appearance part of the index entry.
%    \begin{macrocode}
%<*cfg>
\renewcommand{\GLX@output@short}[3]{%
  \ifthenelse{\equal{#2}{\GLX@acdef@list}}{%
    \textsc{#3}}{#3}\index{#1=#3}}
%</cfg>
%    \end{macrocode}
%
% \section{Some Details}
% While reading the |.aux|-file, \GlossTeX{} only considers the first
% appearance of one \meta{item} for each \meta{list}. All subsequent
%  entries are silently ignored. 
% (Almost silently, because the |.gxg|-file will contain detailed
% information about this, and more.) But if the first entry says 
% not to produce a page reference and a following one says to do so, then
% the latter will supersede the former. The same applies if a
% term is referenced without the option not to generate a list-entry
% (all commands containing a |*|, e.g.\ |\gl*|), but a following tells
% to do so.
%
% While reading one or more |.gdf|-files, only the first definition is
% used, all other entries are ignored. This fact can be utilised
% in some way. Assume you have a |master.gdf| which contains general
% terms and a file |thesis.gdf| which only contains terms that are
% intended for use in your thesis. Whenever an entry is present in both
% |.gdf|-files, the one from |thesis.gdf| should be taken. To achieve
% this, specify |thesis.gdf| \emph{before} |master.gdf|.
%
% Additionally, see the file |TODO| in this package for
% known bugs (also called features) and not yet implemented features
% (also called bugs).
%
% \section{Acknowledgments}
% I would like to thank these people who have contributed to the
%  development of \GlossTeX{}: 
%
% {\scshape
% Daniel Courjon, Stefan A.~Deutscher, Michael Friendly, Olaf Michelsson 
% }
%
% \StopEventually{\printglosstex[a]}
% 
% \section{The Implementation}
% \subsection{The Package \package{glosstex.sty}}
%
% First, we identify ourselves.
%    \begin{macrocode}
%<*package>
\NeedsTeXFormat{LaTeX2e}[1996/12/01] \ProvidesPackage{glosstex}
[\filedate\space\fileversion\space GlossTeX package]
%    \end{macrocode}
%
% The \package{ifthen} package is needed for some |\ifthenelse|-constructs.
%    \begin{macrocode}
\RequirePackage{ifthen}
\newif\if@GLX@pagerefmode
\newif\if@GLX@itemfirst
\newif\if@GLX@footnote
\newif\if@GLX@roundparen
\newif\if@GLX@squareparen
%    \end{macrocode}
%
% \begin{macro}{\GlossTeX}
% This is used to typeset a nice logo for this package, which looks
% like ``\GlossTeX{}''.
%    \begin{macrocode}
\newcommand{\GlossTeX}{Gloss\TeX}
%    \end{macrocode}
% \end{macro}
%
% First, we make sure that the |.glx|-file is input in all cases. We
% need this to expand acronyms in case the user generates no typeset
% list. We create a dummy list |GLX@Null@List|. This assumes, of course, that
% you have no entries for list |GLX@Null@List|. But who would, anyhow?
%    \begin{macrocode}
\AtBeginDocument{%
  \glxheading{GLX@Null@List}{}%
  \printglosstex(GLX@Null@List)}
%    \end{macrocode}
%
% We want to remind the user to run \GlossTeX\ when there were
% undefined terms in the document.
%    \begin{macrocode}
\AtEndDocument{%
  \ifx\GLX@undefined@term\@undefined\else %
    \PackageWarningNoLine{glosstex}%
    {There were undefined terms.\MessageBreak
      You should (re)run GlossTeX}\fi}
%    \end{macrocode}
%
% \begin{macro}{\GlossTeXPage}
% Call |\glosstexpage| depending on |#1| (\meta{pageref-mode}) for
% each entry,
% |\GLX@theglosstex@pagerefmode| for each list and
% |\if@GLX@pagerefmode| for the whole package.
%    \begin{macrocode}
\newcommand{\GlossTeXPage}[2]{\ignorespaces%
  \ifthenelse{\boolean{@GLX@pagerefmode}}%
    {% refpage true
      \ifthenelse{%
        \equal{\GLX@theglosstex@pagerefmode}{a}}{\glosstexpage{#2}}{%
        \ifthenelse{\equal{\GLX@theglosstex@pagerefmode}{n}}{}{%
          \ifthenelse{\equal{#1}{a}}{\glosstexpage{#2}}{}%
          \ifthenelse{\equal{#1}{p}}{\glosstexpage{#2}}{}%
          \ifthenelse{\equal{#1}{n}}{}{}}}}%
    {% refpage false
      \ifthenelse{%
        \equal{\GLX@theglosstex@pagerefmode}{a}}{\glosstexpage{#2}}{%
        \ifthenelse{\equal{\GLX@theglosstex@pagerefmode}{n}}{}{%
          \ifthenelse{\equal{#1}{a}}{\glosstexpage{#2}}{}%
          \ifthenelse{\equal{#1}{p}}{}{}%
          \ifthenelse{\equal{#1}{n}}{}{}}}}%
    }%
%    \end{macrocode}
% \end{macro}
%
% Now declare the options this package accepts and execute the
% standard options.
%    \begin{macrocode}
\DeclareOption{refpage}{\@GLX@pagerefmodetrue}
\DeclareOption{norefpage}{\@GLX@pagerefmodefalse}
\DeclareOption{itemfirst}{\@GLX@itemfirsttrue}
\DeclareOption{longfirst}{\@GLX@itemfirstfalse}
\DeclareOption{text}{\@GLX@footnotefalse}
\DeclareOption{footnote}{\@GLX@footnotetrue}
\DeclareOption{roundparen}{\gdef\GLX@paren@l{(}\gdef\GLX@paren@r{)}}
\DeclareOption{squareparen}{\gdef\GLX@paren@l{[}\gdef\GLX@paren@r{]}}
\ExecuteOptions{norefpage,itemfirst,text,roundparen}
\ProcessOptions
%    \end{macrocode}
%
% \begin{macro}{\GlossTeXNull}
% This one is used as a dummy to work around a feature in
% \MakeIndex{}.
%    \begin{macrocode}
\newcommand{\GlossTeXNull}[1]{}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\glosstex}
% \begin{definition}
% |\glosstex|\opt{|(|\meta{list}|)|}\opt{|[|\meta{pageref-mode}|]|}|{|\meta{label}|}|.
% \end{definition}
%    \begin{macrocode}
\DeclareRobustCommand\glosstex{\GLX@glosstex}
\newcommand{\GLX@glosstex}{%
  \@ifnextchar({\GLX@@glosstexr}{%
    \@ifnextchar[{\GLX@@glosstexs(\GLX@gldef@list)}{%
      \GLX@@@glosstex(\GLX@gldef@list)[\GLX@gldef@page]}}}
\newcommand{\GLX@@glosstexr}{}
\def\GLX@@glosstexr(#1){%
  \@ifnextchar[{\GLX@@glosstexs(#1)}{\GLX@@@glosstex(#1)[\GLX@gldef@page]}}
\newcommand{\GLX@@glosstexs}{}
\def\GLX@@glosstexs(#1)[#2]{%
  \GLX@@@glosstex(#1)[#2]}
\newcommand{\GLX@@@glosstex}{}
\def\GLX@@@glosstex(#1)[#2]#3{\GLX@do@glosstex{#3}{#2}{#1}{a}}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\acronym}
% \begin{definition}
% |\acronym|\opt{|(|\meta{list}|)|}\opt{|[|\meta{pageref-mode}|]|}|{|\meta{label}|}| 
% \end{definition}
%    \begin{macrocode}
\DeclareRobustCommand\acronym{\GLX@acronym}
\newcommand{\GLX@acronym}{%
  \@ifnextchar({\GLX@@acronymr}{%
    \@ifnextchar[{\GLX@@acronyms(\GLX@acdef@list)}{%
      \GLX@@@acronym(\GLX@acdef@list)[\GLX@acdef@page]}}}
\newcommand{\GLX@@acronymr}{}
\def\GLX@@acronymr(#1){%
  \@ifnextchar[{\GLX@@acronyms(#1)}{\GLX@@@acronym(#1)[\GLX@acdef@page]}}
\newcommand{\GLX@@acronyms}{}
\def\GLX@@acronyms(#1)[#2]{%
  \GLX@@@acronym(#1)[#2]}
\newcommand{\GLX@@@acronym}{}
\def\GLX@@@acronym(#1)[#2]#3{\GLX@do@glosstex{#3}{#2}{#1}{a}}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\gls}
% \begin{macro}{\gls*}
% \begin{definition}
% |\gls|\opt{|*|}\opt{|(|\meta{list}|)|}\opt{|[|\meta{pageref-mode}|]|}|{|\meta{label}|}| 
% \end{definition}
%    \begin{macrocode}
\DeclareRobustCommand\gls{%
  \@ifstar{\GLX@glsS}{\GLX@gls}}
\newcommand{\GLX@gls}{%
  \@ifnextchar({\GLX@@glsr}{%
    \@ifnextchar[{\GLX@@glss(\GLX@gldef@list)}{%
      \GLX@@@gls(\GLX@gldef@list)[\GLX@gldef@page]}}}
\newcommand{\GLX@@glsr}{}
\def\GLX@@glsr(#1){%
  \@ifnextchar[{\GLX@@glss(#1)}{\GLX@@@gls(#1)[\GLX@gldef@page]}}
\newcommand{\GLX@@glss}{}
\def\GLX@@glss(#1)[#2]{%
  \GLX@@@gls(#1)[#2]}
\newcommand{\GLX@@@gls}{}
\def\GLX@@@gls(#1)[#2]#3{\GLX@do@glosstex{#3}{#2}{#1}{a}\GLX@do@acs{#3}{#1}}
\newcommand{\GLX@glsS}{%
  \@ifnextchar({\GLX@@glsSr}{%
    \@ifnextchar[{\GLX@@glsSs(\GLX@gldef@list)}{%
      \GLX@@@glsS(\GLX@gldef@list)[\GLX@gldef@page]}}}
\newcommand{\GLX@@glsSr}{}
\def\GLX@@glsSr(#1){%
  \@ifnextchar[{\GLX@@glsSs(#1)}{\GLX@@@glsS(#1)[\GLX@gldef@page]}}
\newcommand{\GLX@@glsSs}{}
\def\GLX@@glsSs(#1)[#2]{%
  \GLX@@@glsS(#1)[#2]}
\newcommand{\GLX@@@glsS}{}
\def\GLX@@@glsS(#1)[#2]#3{\GLX@do@glosstex{#3}{#2}{#1}{n}\GLX@do@acs{#3}{#1}}
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\ac}
% \begin{macro}{\ac*}
% \begin{definition}
%   |\ac|\opt{|*|}\opt{|,|\meta{lparen}|,|\meta{rparen}|,|}\opt{|<|\meta{form}|>|}\opt{|(|\meta{list}|)|}\opt{|[|\meta{pageref-mode}|]|}|{|\meta{label}|}|\\
% \end{definition}
%    \begin{macrocode}
\DeclareRobustCommand\ac{%
  \@ifstar{\GLX@acS}{\GLX@ac}}
\newcommand{\GLX@ac}{%
  \@ifnextchar,{\GLX@@acc}{%
    \@ifnextchar<{\GLX@@aca,\relax,\relax,}{%
      \@ifnextchar({\GLX@@acr,\relax,\relax,<>}{%
        \@ifnextchar[{\GLX@@acs,\relax,\relax,<>(\GLX@acdef@list)}{%
          \GLX@@@ac,\relax,\relax,<>(\GLX@acdef@list)[\GLX@acdef@page]}}}}}
\newcommand{\GLX@@acc}{}
\def\GLX@@acc,#1,#2,{%
  \@ifnextchar<{\GLX@@aca,#1,#2,}{%
    \@ifnextchar({\GLX@@acr,#1,#2,<>}{%
      \@ifnextchar[{\GLX@@acs,#1,#2,<>(\GLX@acdef@list)}{%
        \GLX@@@ac,#1,#2,<>(\GLX@acdef@list)[\GLX@acdef@page]}}}}
\newcommand{\GLX@@aca}{}
\def\GLX@@aca,#1,#2,<#3>{%
  \@ifnextchar({\GLX@@acr,#1,#2,<#3>}{%
    \@ifnextchar[{\GLX@@acs,#1,#2,<#3>(\GLX@acdef@list)}{%
      \GLX@@@ac,#1,#2,<#3>(\GLX@acdef@list)[\GLX@acdef@page]}}}
\newcommand{\GLX@@acr}{}
\def\GLX@@acr,#1,#2,<#3>(#4){%
  \@ifnextchar[{\GLX@@acs,#1,#2,<#3>(#4)}{%
    \GLX@@@ac,#1,#2,<#3>(#4)[\GLX@acdef@page]}}
\newcommand{\GLX@@acs}{}
\def\GLX@@acs,#1,#2,<#3>(#4)[#5]{%
  \GLX@@@ac,#1,#2,<#3>(#4)[#5]}
\newcommand{\GLX@@@ac}{}
\def\GLX@@@ac,#1,#2,<#3>(#4)[#5]#6{%
  \GLX@do@glosstex{#6}{#5}{#4}{a}\GLX@do@ac{#6}{#4}{#3}{#1}{#2}}
\newcommand{\GLX@acS}{%
  \@ifnextchar,{\GLX@@acSc}{%
    \@ifnextchar<{\GLX@@acSa,\relax,\relax,}{%
      \@ifnextchar({\GLX@@acSr,\relax,\relax,<>}{%
        \@ifnextchar[{\GLX@@acSs,\relax,\relax,<>(\GLX@acdef@list)}{%
          \GLX@@@acS,\relax,\relax,<>(\GLX@acdef@list)[\GLX@acdef@page]}}}}}
\newcommand{\GLX@@acSc}{}
\def\GLX@@acSc,#1,#2,{%
  \@ifnextchar<{\GLX@@acSa,#1,#2,}{%
    \@ifnextchar({\GLX@@acSr,#1,#2,<>}{%
      \@ifnextchar[{\GLX@@acSs,#1,#2,<>(\GLX@acdef@list)}{%
        \GLX@@@acS,#1,#2,<>(\GLX@acdef@list)[\GLX@acdef@page]}}}}
\newcommand{\GLX@@acSa}{}
\def\GLX@@acSa,#1,#2,<#3>{%
  \@ifnextchar({\GLX@@acSr,#1,#2,<#3>}{%
    \@ifnextchar[{\GLX@@acSs,#1,#2,<#3>(\GLX@acdef@list)}{%
      \GLX@@@acS,#1,#2,<#3>(\GLX@acdef@list)[\GLX@acdef@page]}}}
\newcommand{\GLX@@acSr}{}
\def\GLX@@acSr,#1,#2,<#3>(#4){%
  \@ifnextchar[{\GLX@@acSs,#1,#2,<#3>(#4)}{%
    \GLX@@@acS,#1,#2,<#3>(#4)[\GLX@acdef@page]}}
\newcommand{\GLX@@acSs}{}
\def\GLX@@acSs,#1,#2,<#3>(#4)[#5]{%
  \GLX@@@acS,#1,#2,<#3>(#4)[#5]}
\newcommand{\GLX@@@acS}{}
\def\GLX@@@acS,#1,#2,<#3>(#4)[#5]#6{%
  \GLX@do@glosstex{#6}{#5}{#4}{n}\GLX@do@ac{#6}{#4}{#3}{#1}{#2}}
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\acs}
% \begin{macro}{\acs*}
% \begin{definition}
%   |\acs|\opt{|*|}\opt{|(|\meta{list}|)|}\opt{|[|\meta{pageref-mode}|]|}|{|\meta{label}|}|\\
% \end{definition}
%    \begin{macrocode}
\DeclareRobustCommand\acs{%
  \@ifstar{\GLX@acsS}{\GLX@acs}}
\newcommand{\GLX@acs}{%
  \@ifnextchar({\GLX@@acsr}{%
    \@ifnextchar[{\GLX@@acss(\GLX@acdef@list)}{%
      \GLX@@@acs(\GLX@acdef@list)[\GLX@acdef@page]}}}
\newcommand{\GLX@@acsr}{}
\def\GLX@@acsr(#1){%
  \@ifnextchar[{\GLX@@acss(#1)}{\GLX@@@acs(#1)[\GLX@acdef@page]}}
\newcommand{\GLX@@acss}{}
\def\GLX@@acss(#1)[#2]{%
  \GLX@@@acs(#1)[#2]}
\newcommand{\GLX@@@acs}{}
\def\GLX@@@acs(#1)[#2]#3{\GLX@do@glosstex{#3}{#2}{#1}{a}\GLX@do@acs{#3}{#1}}
\newcommand{\GLX@acsS}{%
  \@ifnextchar({\GLX@@acsSr}{%
    \@ifnextchar[{\GLX@@acsSs(\GLX@acdef@list)}{%
      \GLX@@@acsS(\GLX@acdef@list)[\GLX@acdef@page]}}}
\newcommand{\GLX@@acsSr}{}
\def\GLX@@acsSr(#1){%
  \@ifnextchar[{\GLX@@acsSs(#1)}{\GLX@@@acsS(#1)[\GLX@acdef@page]}}
\newcommand{\GLX@@acsSs}{}
\def\GLX@@acsSs(#1)[#2]{%
  \GLX@@acsS(#1)[#2]}
\newcommand{\GLX@@@acsS}{}
\def\GLX@@@acsS(#1)[#2]#3{\GLX@do@glosstex{#3}{#2}{#1}{n}\GLX@do@acs{#3}{#1}}
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\acl}
% \begin{macro}{\acl*}
% \begin{definition}
%   |\acl|\opt{|*|}\opt{|(|\meta{list}|)|}\opt{|[|\meta{pageref-mode}|]|}|{|\meta{label}|}|\\
% \end{definition}
%    \begin{macrocode}
\DeclareRobustCommand\acl{%
  \@ifstar{\GLX@aclS}{\GLX@acl}}
\newcommand{\GLX@acl}{%
  \@ifnextchar({\GLX@@aclr}{%
    \@ifnextchar[{\GLX@@acls(\GLX@acdef@list)}{%
      \GLX@@@acl(\GLX@acdef@list)[\GLX@acdef@page]}}}
\newcommand{\GLX@@aclr}{}
\def\GLX@@aclr(#1){%
  \@ifnextchar[{\GLX@@acls(#1)}{\GLX@@@acl(#1)[\GLX@acdef@page]}}
\newcommand{\GLX@@acls}{}
\def\GLX@@acls(#1)[#2]{%
  \GLX@@@acl(#1)[#2]}
\newcommand{\GLX@@@acl}{}
\def\GLX@@@acl(#1)[#2]#3{\GLX@do@glosstex{#3}{#2}{#1}{a}\GLX@do@acl{#3}{#1}}
\newcommand{\GLX@aclS}{%
  \@ifnextchar({\GLX@@aclSr}{%
    \@ifnextchar[{\GLX@@aclSs(\GLX@acdef@list)}{%
      \GLX@@@aclS(\GLX@acdef@list)[\GLX@acdef@page]}}}
\newcommand{\GLX@@aclSr}{}
\def\GLX@@aclSr(#1){%
  \@ifnextchar[{\GLX@@aclSs(#1)}{\GLX@@@aclS(#1)[\GLX@acdef@page]}}
\newcommand{\GLX@@aclSs}{}
\def\GLX@@aclSs(#1)[#2]{%
  \GLX@@@aclS(#1)[#2]}
\newcommand{\GLX@@@aclS}{}
\def\GLX@@@aclS(#1)[#2]#3{\GLX@do@glosstex{#3}{#2}{#1}{n}\GLX@do@acl{#3}{#1}}
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\acf}
% \begin{macro}{\acf*}
% \begin{definition}
%   |\acf|\opt{|*|}\opt{|,|\meta{lparen}|,|\meta{rparen}|,|}\opt{|<|\meta{form}|>|}\opt{|(|\meta{list}|)|}\opt{|[|\meta{pageref-mode}|]|}|{|\meta{label}|}|
% \end{definition}
%    \begin{macrocode}
\DeclareRobustCommand\acf{%
  \@ifstar{\GLX@acfS}{\GLX@acf}}
\newcommand{\GLX@acf}{%
  \@ifnextchar,{\GLX@@acfc}{%
    \@ifnextchar<{\GLX@@acfa,\relax,\relax,}{%
      \@ifnextchar({\GLX@@acfr,\relax,\relax,<>}{%
        \@ifnextchar[{\GLX@@acfs,\relax,\relax,<>(\GLX@acdef@list)}{%
          \GLX@@@acf,\relax,\relax,<>(\GLX@acdef@list)[\GLX@acdef@page]}}}}}
\newcommand{\GLX@@acfc}{}
\def\GLX@@acfc,#1,#2,{%
  \@ifnextchar<{\GLX@@acfa,#1,#2,}{%
    \@ifnextchar({\GLX@@acfr,#1,#2,<>}{%
      \@ifnextchar[{\GLX@@acfs,#1,#2,<>(\GLX@acdef@list)}{%
        \GLX@@@acf,#1,#2,<>(\GLX@acdef@list)[\GLX@acdef@page]}}}}
\newcommand{\GLX@@acfa}{}
\def\GLX@@acfa,#1,#2,<#3>{%
  \@ifnextchar({\GLX@@acfr,#1,#2,<#3>}{%
    \@ifnextchar[{\GLX@@acfs,#1,#2,<#3>(\GLX@acdef@list)}{%
      \GLX@@@acf,#1,#2,<#3>(\GLX@acdef@list)[\GLX@acdef@page]}}}
\newcommand{\GLX@@acfr}{}
\def\GLX@@acfr,#1,#2,<#3>(#4){%
  \@ifnextchar[{\GLX@@acfs,#1,#2,<#3>(#4)}{%
    \GLX@@@acf,#1,#2,<#3>(#4)[\GLX@acdef@page]}}
\newcommand{\GLX@@acfs}{}
\def\GLX@@acfs,#1,#2,<#3>(#4)[#5]{%
  \GLX@@@acf,#1,#2,<#3>(#4)[#5]}
\newcommand{\GLX@@@acf}{}
\def\GLX@@@acf,#1,#2,<#3>(#4)[#5]#6{%
  \GLX@do@glosstex{#6}{#5}{#4}{a}\GLX@do@acf{#6}{#4}{#3}{#1}{#2}}
\newcommand{\GLX@acfS}{%
  \@ifnextchar,{\GLX@@acfSc}{%
    \@ifnextchar<{\GLX@@acfSa,\relax,\relax,}{%
      \@ifnextchar({\GLX@@acfSr,\relax,\relax,<>}{%
        \@ifnextchar[{\GLX@@acfSs,\relax,\relax,<>(\GLX@acdef@list)}{%
          \GLX@@@acfS,\relax,\relax,<>(\GLX@acdef@list)[\GLX@acdef@page]}}}}}
\newcommand{\GLX@@acfSc}{}
\def\GLX@@acfSc,#1,#2,{%
  \@ifnextchar<{\GLX@@acfSa,#1,#2,}{%
    \@ifnextchar({\GLX@@acfSr,#1,#2,<>}{%
      \@ifnextchar[{\GLX@@acfSs,#1,#2,<>(\GLX@acdef@list)}{%
        \GLX@@@acfS,#1,#2,<>(\GLX@acdef@list)[\GLX@acdef@page]}}}}
\newcommand{\GLX@@acfSa}{}
\def\GLX@@acfSa,#1,#2,<#3>{%
  \@ifnextchar({\GLX@@acfSr,#1,#2,<#3>}{%
    \@ifnextchar[{\GLX@@acfSs,#1,#2,<#3>(\GLX@acdef@list)}{%
      \GLX@@@acfS,#1,#2,<#3>(\GLX@acdef@list)[\GLX@acdef@page]}}}
\newcommand{\GLX@@acfSr}{}
\def\GLX@@acfSr,#1,#2,<#3>(#4){%
  \@ifnextchar[{\GLX@@acfSs,#1,#2,<#3>(#4)}{%
    \GLX@@@acfS,#1,#2,<#3>(#4)[\GLX@acdef@page]}}
\newcommand{\GLX@@acfSs}{}
\def\GLX@@acfSs,#1,#2,<#3>(#4)[#5]{%
  \GLX@@@acfS,#1,#2,<#3>(#4)[#5]}
\newcommand{\GLX@@@acfS}{}
\def\GLX@@@acfS,#1,#2,<#3>(#4)[#5]#6{%
  \GLX@do@glosstex{#6}{#5}{#4}{n}\GLX@do@acf{#6}{#4}{#3}{#1}{#2}}
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\GLX@entry}
% This is the control-sequence written into the |.aux|-file which is
% to be read by \GlossTeX{}. This
% macro is defined so that it takes 5 arguments and expands to
% |\relax| when the |.aux|-file is reread by \TeX{}.
%    \begin{macrocode}
\newcommand{\GLX@entry}[5]{\relax}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\GLX@do@glosstex}
% This macro writes lines of the format
% \begin{definition}
%   |\GLX@entry{|\meta{label}|}{|\meta{pageref-mode}|}{|\meta{list}|}{|\meta{list-mode}|}{|\meta{page}|}|
% \end{definition}
% into the |.aux|-file.
%    \begin{macrocode}
\newcommand{\GLX@do@glosstex}[4]{%
  \protected@write\@auxout{}%
  {\string\GLX@entry{#1}{#2}{#3}{#4}{\thepage}}}
%    \end{macrocode}
% \end{macro}
%
% The following commands create macros so that |\GLX@term@|\meta{label} contains
% the short-form of \meta{label} |#1|, |\GLX@term@@|\meta{label} contains the \meta{long-form}
% of \meta{label} |#1| and |\GLX@terml@|\meta{label} expands to |x| if the \meta{long-form} of
% \meta{label} |#1| has already been used. This is heavily borrowed from
% \package{acronym}.
%
% \begin{macro}{\GLX@do@acs}
% Output the short-form \meta{item} of \meta{label} |#1| in
% \meta{list} |#2|.
%    \begin{macrocode}
\newcommand{\GLX@do@acs}[2]{%
  \expandafter\ifx\csname GLX@term@#1\endcsname\relax%
    \textbf{#1!}%
    \PackageWarning{glosstex}{Term `#1' is not defined}%
    \gdef\GLX@undefined@term{x}%
    \expandafter\gdef\csname GLX@term@#1\endcsname{\textbf{#1!}}%
  \else%
    \GLX@output@short{#1}{#2}{\csname GLX@term@#1\endcsname}%
  \fi}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\GLX@do@acl}
% Output the \meta{long-form} of \meta{label} |#1| in \meta{list} |#2|.
%    \begin{macrocode}
\newcommand{\GLX@do@acl}[2]{%
  \expandafter\ifx\csname GLX@term@@#1\endcsname\relax%
    \textbf{#1!}%
    \PackageWarning{glosstex}{Term `#1' has no long form}%
    \expandafter\gdef\csname GLX@term@@#1\endcsname{\textbf{#1!}}%
  \else%
    \GLX@output@long{#1}{#2}{\csname GLX@term@@#1\endcsname}%
  \fi}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\GLX@do@acf}
% Output \meta{short} |(|\meta{long}|)| of \meta{label} |#1| by calling
% |\GLX@do@acs| and |GLX@do@acl|.
% \begin{definition}
% |\GLX@do@acf||{|\meta{label}|}||{|\meta{list}|}||{|\meta{form}|}||{|\meta{lparen}|}||{|\meta{rparen}|}|
% \end{definition}
%    \begin{macrocode}
\newcommand{\GLX@do@acf}[5]{%
  \begingroup%
  \ifthenelse{\equal{#3}{i}}{\def\GLX@il{i}\def\GLX@tf{-}}{%
    \ifthenelse{\equal{#3}{l}}{\def\GLX@il{l}\def\GLX@tf{-}}{%
      \ifthenelse{\equal{#3}{it}}{\def\GLX@il{i}\def\GLX@tf{t}}{%
        \ifthenelse{\equal{#3}{if}}{\def\GLX@il{i}\def\GLX@tf{f}}{%
          \ifthenelse{\equal{#3}{lt}}{\def\GLX@il{l}\def\GLX@tf{t}}{%
            \ifthenelse{\equal{#3}{lf}}{\def\GLX@il{l}\def\GLX@tf{f}}{%
              \ifthenelse{\equal{#3}{t}}{\def\GLX@il{-}\def\GLX@tf{t}}{%
                \ifthenelse{\equal{#3}{f}}{\def\GLX@il{-}\def\GLX@tf{f}}{%
                  \def\GLX@il{-}\def\GLX@tf{-}}%
                }}}}}}}%
  \ifthenelse{\boolean{@GLX@itemfirst}}%
  {% itemfirst true
    \ifthenelse{%
      \equal{\GLX@itemorder{#2}}{i}}{\def\GLX@itemorder@{i}}{%
      \ifthenelse{\equal{\GLX@itemorder{#2}}{l}}{\def\GLX@itemorder@{l}}{%
        \ifthenelse{\equal{\GLX@il}{i}}{\def\GLX@itemorder@{i}}{}%
        \ifthenelse{\equal{\GLX@il}{-}}{\def\GLX@itemorder@{i}}{}%
        \ifthenelse{\equal{\GLX@il}{l}}{\def\GLX@itemorder@{l}}{}}}}%
  {% itemfirst false
    \ifthenelse{%
      \equal{\GLX@itemorder{#2}}{i}}{\def\GLX@itemorder@{i}}{%
      \ifthenelse{\equal{\GLX@itemorder{#2}}{l}}{\def\GLX@itemorder@{l}}{%
        \ifthenelse{\equal{\GLX@il}{i}}{\def\GLX@itemorder@{i}}{}%
        \ifthenelse{\equal{\GLX@il}{-}}{\def\GLX@itemorder@{l}}{}%
        \ifthenelse{\equal{\GLX@il}{l}}{\def\GLX@itemorder@{l}}{}}}}%
  \ifthenelse{\boolean{@GLX@footnote}}%
  {% footnote true
    \ifthenelse{%
      \equal{\GLX@itemplacement{#2}}{t}}{\def\GLX@itemplacement@{t}}{%
      \ifthenelse{\equal{\GLX@itemplacement{#2}}{f}}{\def\GLX@itemplacement@{f}}{%
        \ifthenelse{\equal{\GLX@tf}{t}}{\def\GLX@itemplacement@{t}}{}%
        \ifthenelse{\equal{\GLX@tf}{-}}{\def\GLX@itemplacement@{f}}{}%
        \ifthenelse{\equal{\GLX@tf}{f}}{\def\GLX@itemplacement@{f}}{}}}}%
  {% footnote false
    \ifthenelse{%
      \equal{\GLX@itemplacement{#2}}{t}}{\def\GLX@itemplacement@{t}}{%
      \ifthenelse{\equal{\GLX@itemplacement{#2}}{f}}{\def\GLX@itemplacement@{f}}{%
        \ifthenelse{\equal{\GLX@tf}{t}}{\def\GLX@itemplacement@{t}}{}%
        \ifthenelse{\equal{\GLX@tf}{-}}{\def\GLX@itemplacement@{t}}{}%
        \ifthenelse{\equal{\GLX@tf}{f}}{\def\GLX@itemplacement@{f}}{}}}}%
  %
  \ifthenelse{\equal{\GLX@itemorder@}{i}}%
  {% itemorder i
    \ifthenelse{\equal{\GLX@itemplacement@}{f}}%
    {\GLX@do@acf@if{#1}{#2}}%
    {\GLX@do@acf@it{#1}{#2}{#4}{#5}}}%
  {% itemorder l
    \ifthenelse{\equal{\GLX@itemplacement@}{f}}%
    {\GLX@do@acf@lf{#1}{#2}}%
    {\GLX@do@acf@lt{#1}{#2}{#4}{#5}}}%
  \endgroup}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\GLX@do@ac}
% Either call |\GLX@do@acf| or |\GLX@do@acs|, depending on
% |\GLX@terml@#1| $==$ |x|.
% \begin{definition}
% |\GLX@do@ac||{|\meta{label}|}||{|\meta{list}|}||{|\meta{form}|}||{|\meta{lparen}|}||{|\meta{rparen}|}|
% \end{definition}
%    \begin{macrocode}
\newcommand{\GLX@do@ac}[5]{%
  \begingroup%
  \ifthenelse{\equal{#3}{i}}{\def\GLX@il{i}\def\GLX@tf{-}}{%
    \ifthenelse{\equal{#3}{l}}{\def\GLX@il{l}\def\GLX@tf{-}}{%
      \ifthenelse{\equal{#3}{it}}{\def\GLX@il{i}\def\GLX@tf{t}}{%
        \ifthenelse{\equal{#3}{if}}{\def\GLX@il{i}\def\GLX@tf{f}}{%
          \ifthenelse{\equal{#3}{lt}}{\def\GLX@il{l}\def\GLX@tf{t}}{%
            \ifthenelse{\equal{#3}{lf}}{\def\GLX@il{l}\def\GLX@tf{f}}{%
              \ifthenelse{\equal{#3}{t}}{\def\GLX@il{-}\def\GLX@tf{t}}{%
                \ifthenelse{\equal{#3}{f}}{\def\GLX@il{-}\def\GLX@tf{f}}{%
                  \def\GLX@il{-}\def\GLX@tf{-}}%
                }}}}}}}%
  \ifthenelse{\boolean{@GLX@itemfirst}}%
  {% itemfirst true
    \ifthenelse{%
      \equal{\GLX@itemorder{#2}}{i}}{\def\GLX@itemorder@{i}}{%
      \ifthenelse{\equal{\GLX@itemorder{#2}}{l}}{\def\GLX@itemorder@{l}}{%
        \ifthenelse{\equal{\GLX@il}{i}}{\def\GLX@itemorder@{i}}{}%
        \ifthenelse{\equal{\GLX@il}{-}}{\def\GLX@itemorder@{i}}{}%
        \ifthenelse{\equal{\GLX@il}{l}}{\def\GLX@itemorder@{l}}{}}}}%
  {% itemfirst false
    \ifthenelse{%
      \equal{\GLX@itemorder{#2}}{i}}{\def\GLX@itemorder@{i}}{%
      \ifthenelse{\equal{\GLX@itemorder{#2}}{l}}{\def\GLX@itemorder@{l}}{%
        \ifthenelse{\equal{\GLX@il}{i}}{\def\GLX@itemorder@{i}}{}%
        \ifthenelse{\equal{\GLX@il}{-}}{\def\GLX@itemorder@{l}}{}%
        \ifthenelse{\equal{\GLX@il}{l}}{\def\GLX@itemorder@{l}}{}}}}%
  \ifthenelse{\boolean{@GLX@footnote}}%
  {% footnote true
    \ifthenelse{%
      \equal{\GLX@itemplacement{#2}}{t}}{\def\GLX@itemplacement@{t}}{%
      \ifthenelse{\equal{\GLX@itemplacement{#2}}{f}}{\def\GLX@itemplacement@{f}}{%
        \ifthenelse{\equal{\GLX@tf}{t}}{\def\GLX@itemplacement@{t}}{}%
        \ifthenelse{\equal{\GLX@tf}{-}}{\def\GLX@itemplacement@{f}}{}%
        \ifthenelse{\equal{\GLX@tf}{f}}{\def\GLX@itemplacement@{f}}{}}}}%
  {% footnote false
    \ifthenelse{%
      \equal{\GLX@itemplacement{#2}}{t}}{\def\GLX@itemplacement@{t}}{%
      \ifthenelse{\equal{\GLX@itemplacement{#2}}{f}}{\def\GLX@itemplacement@{f}}{%
        \ifthenelse{\equal{\GLX@tf}{t}}{\def\GLX@itemplacement@{t}}{}%
        \ifthenelse{\equal{\GLX@tf}{-}}{\def\GLX@itemplacement@{t}}{}%
        \ifthenelse{\equal{\GLX@tf}{f}}{\def\GLX@itemplacement@{f}}{}}}}%
  %
  \ifthenelse{\equal{\GLX@itemorder@}{i}}%
  {% itemorder i
    \ifthenelse{\equal{\GLX@itemplacement@}{f}}%
    {\expandafter\ifx\csname GLX@terml@#1\endcsname\relax%
        \GLX@do@acf@if{#1}{#2}%
        \expandafter\gdef\csname GLX@terml@#1\endcsname{x}%
      \else%
        \GLX@do@acs{#1}{#2}%
      \fi}%
    {\expandafter\ifx\csname GLX@terml@#1\endcsname\relax%
        \GLX@do@acf@it{#1}{#2}{#4}{#5}%
        \expandafter\gdef\csname GLX@terml@#1\endcsname{x}%
      \else%
        \GLX@do@acs{#1}{#2}%
      \fi}}%
  {% itemorder l
    \ifthenelse{\equal{\GLX@itemplacement@}{f}}%
    {\expandafter\ifx\csname GLX@terml@#1\endcsname\relax%
        \GLX@do@acf@lf{#1}{#2}%
        \expandafter\gdef\csname GLX@terml@#1\endcsname{x}%
      \else%
        \GLX@do@acs{#1}{#2}%
      \fi}%
    {\expandafter\ifx\csname GLX@terml@#1\endcsname\relax%
        \GLX@do@acf@lt{#1}{#2}{#4}{#5}%
        \expandafter\gdef\csname GLX@terml@#1\endcsname{x}%
      \else%
        \GLX@do@acs{#1}{#2}%
      \fi}}%
  \endgroup}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\GLX@do@acf@it}
% \begin{definition}
% |\GLX@do@acf@it||{|\meta{label}|}||{|\meta{list}|}||{|\meta{lparen}|}||{|\meta{rparen}|}|
% \end{definition}
%    \begin{macrocode}
\newcommand{\GLX@do@acf@it}[4]{%
  \GLX@do@acs{#1}{#2}%
  \expandafter\ifx\csname GLX@term@@#1\endcsname\relax%
  \else\nolinebreak[3]\space%
  \ifthenelse{\equal{#3}{\relax}}{%
    \expandafter\ifx\csname GLX@paren@l@#2\endcsname\relax%
      \GLX@paren@l%
    \else%
      \expandafter\csname GLX@paren@l@#2\endcsname%
    \fi}{#3}%
  \GLX@do@acl{#1}{#2}%
  \ifthenelse{\equal{#4}{\relax}}{%
    \expandafter\ifx\csname GLX@paren@r@#2\endcsname\relax%
      \GLX@paren@r%
    \else%
      \expandafter\csname GLX@paren@r@#2\endcsname%
    \fi}{#4}%
  \fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\GLX@do@acf@if}
% \begin{definition}
% |\GLX@do@acf@if||{|\meta{label}|}||{|\meta{list}|}|
% \end{definition}
%    \begin{macrocode}
\newcommand{\GLX@do@acf@if}[2]{%
  \GLX@do@acs{#1}{#2}%
  \expandafter\ifx\csname GLX@term@@#1\endcsname\relax%
  \else\nolinebreak[3]\footnote{\GLX@do@acl{#1}{#2}}\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\GLX@do@acf@lt}
% \begin{definition}
% |\GLX@do@acf@lt||{|\meta{label}|}||{|\meta{list}|}||{|\meta{lparen}|}||{|\meta{rparen}|}|
% \end{definition}
%    \begin{macrocode}
\newcommand{\GLX@do@acf@lt}[4]{%
  \expandafter\ifx\csname GLX@term@@#1\endcsname\relax%
  \else\GLX@do@acl{#1}{#2}\fi%
  \nolinebreak[3]\space%
  \ifthenelse{\equal{#3}{\relax}}{%
    \expandafter\ifx\csname GLX@paren@l@#2\endcsname\relax%
      \GLX@paren@l%
    \else%
      \expandafter\csname GLX@paren@l@#2\endcsname%
    \fi}{#3}%
  \GLX@do@acs{#1}{#2}%
  \ifthenelse{\equal{#4}{\relax}}{%
    \expandafter\ifx\csname GLX@paren@r@#2\endcsname\relax%
      \GLX@paren@r%
    \else%
      \expandafter\csname GLX@paren@r@#2\endcsname%
    \fi}{#4}}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\GLX@do@acf@lf}
% \begin{definition}
% |\GLX@do@acf@lf||{|\meta{label}|}||{|\meta{list}|}|
% \end{definition}
%    \begin{macrocode}
\newcommand{\GLX@do@acf@lf}[2]{%
  \expandafter\ifx\csname GLX@term@@#1\endcsname\relax%
  \else\GLX@do@acl{#1}{#2}\fi%
  \footnote{\GLX@do@acs{#1}{#2}}}%
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\GLX@newterm}
% This macro defines |\GLX@term@#1| and |\GLX@term@@|\meta{label} so that they expand to
% their appropriate meaning.
% \begin{definition}
% |\GLX@newterm||{|\meta{label}|}||{|\meta{item}|}||{|\meta{long-form}|}|
% \end{definition}
%    \begin{macrocode}
\newcommand{\GLX@newterm}[3]{%
  \expandafter\gdef\csname GLX@term@#1\endcsname{#2}%
  \ifx#3\empty%
  \else\expandafter\gdef\csname GLX@term@@#1\endcsname{#3}\fi}%
%    \end{macrocode}
% \end{macro}
%
% \begin{environment}{theglosstex}
% This environment is used for typesetting the lists generated by
% \GlossTeX{}. These are the meanings of the parameters:
%
% \begin{description}
% \item[\#1] This \meta{list}
% \item[\#2] This \meta{pageref-mode}
% \item[\#\#1] \meta{label}
% \item[\#\#2] \meta{item}
% \item[\#\#3] \meta{long-form}
% \item[\#\#4] \meta{text}
% \item[\#\#5] \meta{list}
% \item[\#\#6] \meta{list-mode}
% \item[\#\#7] \meta{page-stuff}
% \end{description}
%
% The whole list is encapsulated into the environment defined by the
% macros |\GLX@benv@|\meta{list} and |\GLX@eenv@|\meta{list}. These
% contain |\begin{description}| and |\end{description}| for
% \meta{list} $==$ |glo| as default. Each |\GlossTeXEntry| is only
% processed if its \meta{list} is identical to the environment's
% \meta{list} and it's \meta{list-mode} $==$
% |a|. |\GLX@item@|\meta{list} is called for each of these entries.
% \begin{definition}
% |theglosstex||{|\meta{list}|}||{|\meta{pageref-mode}|}|
% \end{definition}
%    \begin{macrocode}
\newenvironment{theglosstex}[2]{%
%    \end{macrocode}
% First, we define some macros which correspond to the arguments given
% to this environment. We need |\GLX@theglosstex@list| when closing the
% current environment. |\GLX@theglosstex@pagerefmode| wouldn't really
% necessary if I weren't that lazy. Having this as global data makes
% |theglosstex| non reentrant, but we don't need nested glossaries. So
% we save passing all these arguments around.
%    \begin{macrocode}
  \gdef\GLX@theglosstex@list{#1}%
  \gdef\GLX@theglosstex@pagerefmode{#2}%
%    \end{macrocode}
% Next, we expand |\GLX@benv@|\meta{list} to start the environment.
%    \begin{macrocode}
  \csname GLX@benv@#1\endcsname%
%    \end{macrocode}
%
% \begin{macro}{\glxref}
% \begin{macro}{\glxrefS}
% This one produces an entry in the current \meta{list} (stored in
% |\GLX@theglosstex@list|). 
% \begin{definition}
% |\glxref||{|\meta{label}|}|
% \end{definition}
%    \begin{macrocode}
  \DeclareRobustCommand{\glxref}{%
    \@ifstar{\GLX@glxrefS}{\GLX@glxref}}%
  \newcommand{\GLX@glxref}[1]{%
    \GLX@do@glosstex{##1}{n}{\GLX@theglosstex@list}{a}%
    \GLX@do@acs{##1}{\GLX@theglosstex@list}}%
  \newcommand{\GLX@glxrefS}[1]{%
    \GLX@do@glosstex{##1}{n}{\GLX@theglosstex@list}{a}}%
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% Define the corresponding macros for \meta{label} using \meta{item}
% and \meta{long-form} and also write out the macro call for the
% definition into the |.aux|-file so that they are defined at the next
% run early. Then, check if the current \meta{label} is to appear in
% the active \meta{list} and check if it is to appear in this
% \meta{list} at all. If these checks all succeed, call
% |\GLX@item@|\meta{label} to typeset the current \meta{label}.
%    \begin{macrocode}
  \newcommand{\GlossTeXEntry}[7]{%
    \GLX@newterm{##1}{##2}{##3}%
    \write\@auxout{\string\GLX@newterm{##1}{##2}{##3}}%
    \ifthenelse{\equal{#1}{##5}}{%
      \ifthenelse{\equal{a}{##6}}{%
        \csname GLX@item@#1\endcsname%
        {##1}{##2}{##3}{##4}{##5}{##6}{##7}}{}%
      }{}}}{%
  \csname GLX@eenv@\GLX@theglosstex@list\endcsname}%
%    \end{macrocode}
% \end{environment}
%
% \begin{macro}{\printglosstex}
% The optional arguments are the \meta{list} to be typeset and the
% \meta{pageref-mode}. First, 
% |\GLX@heading@|\meta{list} is called (defaults to something like
% |\section{\glossaryname}|) to produce a proper heading. Then, if
% present, the |.glx|-file is included into a |theglosstex|
% environment.
% \begin{definition}
% |\printglosstex|\opt{|(|\meta{list}|)|}\opt{|[|\meta{pageref-mode}|]|}
% \end{definition}
%    \begin{macrocode}
\DeclareRobustCommand\printglosstex{\GLX@printglosstex}
\newcommand{\GLX@printglosstex}{%
  \@ifnextchar({\GLX@@printglosstexr}{%
    \@ifnextchar[{\GLX@@printglosstexs(glo)}{%
      \GLX@@@printglosstex[p](glo)}}}
\newcommand{\GLX@@printglosstexr}{}
\def\GLX@@printglosstexr(#1){%
  \@ifnextchar[{\GLX@@printglosstexs(#1)}{%
    \GLX@@@printglosstex(#1)[p]}}
\newcommand{\GLX@@printglosstexs}{}
\def\GLX@@printglosstexs(#1)[#2]{%
  \GLX@@@printglosstex(#1)[#2]}
\newcommand{\GLX@@@printglosstex}{}
\def\GLX@@@printglosstex(#1)[#2]{\GLX@do@printglosstex{#1}{#2}}
\newcommand{\GLX@do@printglosstex}[2]{%
  \expandafter\ifx\csname GLX@heading@#1\endcsname\relax%
    \textbf{#1!}%
    \PackageWarning{glosstex}{Heading for list `#1' is not defined}%
    \expandafter\gdef\csname GLX@heading@#1\endcsname{\textbf{#1!}}%
  \else%
    \csname GLX@heading@#1\endcsname%
    \IfFileExists{\jobname.glx}{%
      \begin{theglosstex}{#1}{#2}%
        \input{\jobname.glx}%
      \end{theglosstex}}%
    {\typeout{No file \jobname.glx}}%
  \fi}
%    \end{macrocode}
% \end{macro}
%
% That was the hard part. The following macros are really trivial, so
% lean back now. They are primarily meant for convenience for using
% the |.std| and |.cfg| files.
%
% \begin{macro}{\glxgldefault}
% \begin{macro}{\glxacdefault}
% The commands set the default \meta{list} and \meta{pageref-mode} for
% the commands starting with |\gl| and |\ac| excluding |\glxref|, respectively.
%    \begin{macrocode}
\newcommand{\glxgldefault}[2]{%
  \gdef\GLX@gldef@list{#1}%
  \gdef\GLX@gldef@page{#2}}
\newcommand{\glxacdefault}[2]{%
  \gdef\GLX@acdef@list{#1}%
  \gdef\GLX@acdef@page{#2}}
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\glxitemorderdefault}
% \begin{macro}{\glxitemplacementdefault}
% These macros set the defaults concerning \meta{item-placement} and
% \meta{item-order} in \meta{list}.
%    \begin{macrocode}
\newcommand{\glxitemorderdefault}[2]{%
  \expandafter\gdef\csname GLX@itemorder@#1\endcsname{#2}}
\newcommand{\glxitemplacementdefault}[2]{%
  \expandafter\gdef\csname GLX@itemplacement@#1\endcsname{#2}}
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\GLX@itemorder}
% \begin{macro}{\GLX@itemplacement}
% These expand to |\GLX@itemorder@#1| and |GLX@itemplacement@|\meta{list}.
%    \begin{macrocode}
\newcommand{\GLX@itemorder}[1]{%
  \expandafter\ifx\csname GLX@itemorder@#1\endcsname\relax%
    \PackageWarning{glosstex}{Item order for list `#1' not defined}%
    \expandafter\gdef\csname GLX@itemorder@#1\endcsname{\textbf{#1!}}%
  \else%
    \csname GLX@itemorder@#1\endcsname%
  \fi}
\newcommand{\GLX@itemplacement}[1]{%
  \expandafter\ifx\csname GLX@itemplacement@#1\endcsname\relax%
    \PackageWarning{glosstex}{Item placement for list `#1' not defined}%
    \expandafter\gdef\csname GLX@itemplacement@#1\endcsname{\textbf{#1!}}%
  \else%
    \csname GLX@itemplacement@#1\endcsname%
  \fi}
%    \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\glxparendefault}
% Set the default for \meta{paren} on package-level.
%    \begin{macrocode}
\newcommand{\glxparendefault}[2]{%
  \gdef\GLX@paren@l{#1}%
  \gdef\GLX@paren@r{#2}}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\glxparenlistdefault}
% Set the default for \meta{paren} on \meta{list}-level.
%    \begin{macrocode}
\newcommand{\glxparenlistdefault}[3]{%
  \expandafter\gdef\csname GLX@paren@l@#1\endcsname{#2}%
  \expandafter\gdef\csname GLX@paren@r@#1\endcsname{#3}}
%    \end{macrocode}
% \end{macro}
%
% \begin{macro}{\glxheading}
% This macro sets the headings to be used typesetting a \meta{list}.
%    \begin{macrocode}
\newcommand*{\glxheading}[2]{%
  \expandafter\gdef\csname GLX@heading@#1\endcsname{#2}}
%    \end{macrocode}
% \end{macro}
%
% And finally, include the mandatory standard configuration file |glosstex.std|
% and an optional |.cfg|-file.
%    \begin{macrocode}
\InputIfFileExists{glosstex.std}{%
  \typeout{Using the standard configuration file glosstex.std}}{%
  \PackageWarning{glosstex}{%
    File glosstex.std not found. I can't stand it no more}}
\InputIfFileExists{glosstex.cfg}{%
  \typeout{Using the configuration file glosstex.cfg}}{}
%</package>
%    \end{macrocode}
%
% \subsection{The \MakeIndex{} Style-File \file{glosstex.ist}}
%
% It is very important to use an appropriate \gls{ist-file} for \MakeIndex\
% to be able to read and write files in the correct format. \GlossTeX\
% comes with |glosstex.ist| which has to be used as style-file for
% \MakeIndex{}. The file |glosstex.ist| should not be modified since
% it is tightly coupled to the features of \MakeIndex{}. Note the use
% of ``|~|'' as |quote| to enable german word-ordering using the |-g|
% option to \MakeIndex{}. So if you want a ``|~|'' in your |.gdf|-file,
% you have to type ``|~~|''
%
%    \begin{macrocode}
%<*ist>
keyword        "\\GlossTeXEntry"
quote          '~'                     
delim_0        ""                      
group_skip     "\n"
indent_length  0
indent_space   ""
item_0         "\n\\GlossTeXEntry"
postamble      "\n"
preamble       "\n"
%</ist>
%    \end{macrocode}
%
% \Finale
\endinput