aboutsummaryrefslogtreecommitdiff
path: root/icite.dtx
blob: 0cdb8decffcfa8172fe313d98e27a90c0c049c97 (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
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
% \iffalse meta-comment
% icite -- Indices locorum citatorum
% Copyright (C) 2019--2021  Robert Alesssi
%
% Please send error reports and suggestions for improvements to Robert
% Alessi <alessi@robertalessi.net>
%
% 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 3 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, see
% <http://www.gnu.org/licenses/>.
% \fi
%
% \iffalse
%<*driver>
\ProvidesFile{icite.dtx}
%</driver>
%<package>\NeedsTeXFormat{LaTeX2e}[1999/12/01]
%<package>\ProvidesPackage{icite}
%<*package>
    [2021/07/07 v1.4-dev Make Indices locorum citatorum]
%</package>
%<*driver>
\documentclass{ltxdoc}
\usepackage{filecontents}
\begin{filecontents*}{\jobname.xdy}
(merge-rule "\*" "" :eregexp)
(markup-locclass-list :open "\tabto{3.5cm}" :sep ", ")
\end{filecontents*}
\begin{filecontents*}{\jobname.bib}
@Book{Aristotle:Politica,
  title =	 {Politica},
  date =	 1964,
  author =	 {Aristotle},
  editor =	 {Ross, W. D.},
  origdate =	 1957,
  entrysubtype = {classical},
  publisher =	 {Clarendon Press},
  location =	 {Oxford}
}

@Book{Bürgel2016,
  shorttitle =	 {Ärztliches Leben\ldots},
  editortype =	 {reviser},
  editor =	 {Käs, Fabian},
  number =	 135,
  series =	 {Islamic History and Civilization},
  location =	 {Leiden},
  publisher =	 {Brill},
  date =	 2016,
  title =	 {Ärztliches Leben und Denken im arabischen
                  Mittelalter},
  author =	 {Bürgel, Johann Christoph}
}

@Software{classics,
  title =	 {The Classics package},
  subtitle =	 {Cite classic works},
  author =	 {Lourenço de Lima, Eduardo C.},
  publisher =	 {CTAN},
  url =		 {http://www.ctan.org/pkg/classics},
  date =	 {2013-02-02},
  version =	 {0.1}
}

@Article{Dols1987,
  author =	 {Dols, Michael W.},
  title =	 {The Origins of the Islamic Hospital: Myth and
                  Reality},
  shorttitle =	 {The Origins of the Islamic Hospital},
  journaltitle = {Bulletin of the History of Medicine},
  date =	 1987,
  volume =	 61,
  pages =	 {367--390}
}

@InBook{Endress1992,
  title =	 {Die Wissenschaftliche Literatur},
  date =	 1992,
  author =	 {Endress, Gerhard},
  booktitle =	 {Grundriß der arabischen Philologie},
  editor =	 {Fisher, Wolfdietrich},
  volume =	 3,
  note =	 {Supplement},
  publisher =	 {Reichert},
  location =	 {Wiesbaden},
  pages =	 {3--152}
}

@Book{IAUMuller,
  sortname =	 {{ibn abi usaybia}},
  editor =	 {Müller, August},
  author =	 {\prname{ibn 'abI 'u.saybi`aT}},
  shorteditor =	 {Müller},
  date =	 {1882/1884},
  title =	 {\arb[trans]{\uc{`u}yUn al-'anbA' fI .tabaqAt
                  al-'a.tibbA'}},
  shorttitle =	 {\arb[trans]{\uc{`u}yUn al-'anbA'}},
  shorthand =	 {\prname{ibn 'abI 'u.saybi`aT},
                  \arb[trans]{\uc{`u}yUn al-'anbA'}},
  entrysubtype = {classical},
  location =	 {Königsberg and Cairo},
  volumes =	 2
}

@Software{imakeidx,
  title =	 {The Imakeidx package},
  subtitle =	 {A package for producing multiple indexes},
  author =	 {Gregorio, Enrico and Beccari, Claudio},
  publisher =	 {CTAN},
  url =		 {http://www.ctan.org/pkg/imakeidx},
  date =	 {2016-10-15},
  version =	 {1.3e}
}

@Book{RaziShukuk,
  author =	 {\prname{al-rAziyy}, \prname{mu.hammad ibn
                  zakariyyA'}},
  title =	 {\arb[trans]{\uc{k}itAb al-^sukUk `al_A
                  \uc{^g}AlInUs}},
  indextitle =	 {\arb[trans]{\uc{^s}ukUk}},
  sortname =	 {razi},
  date =	 1993,
  shorthand =	 {\prname{al-rAziyy}, \arb[trans]{\uc{^s}ukUk}},
  editor =	 {Mehdi Mohaghegh},
  publisher =	 {International Institute of Islamic Thought and
                  Civilization},
  location =	 {Tehran},
  entrysubtype = {classical}
}

@Book{Ullmann1970,
  location =	 {Leiden},
  publisher =	 {Brill},
  title =	 {Die Medizin im Islam},
  date =	 1970,
  author =	 {Ullmann, Manfred},
}

@MVBook{al-Nadim,
  author =	 {\prname{ibn al-nadIm}},
  title =	 {\arb[trans]{\uc{f}ihrist}},
  sortname =	 {{ibn al-nadim}},
  date =	 {1871/1872},
  shorthand =	 {\arb[trans]{\uc{f}ihrist}},
  editor =	 {Flügel, Gustav},
  volumes =	 2,
  location =	 {Leipzig},
  entrysubtype = {classical}
}

@Book{al-Qifti,
  sortname =	 {{ibn al-qifti}},
  entrysubtype = {classical},
  shorthand =	 {\prname{al-qif.tiyy}, \arb[trans]{\uc{t}a'rI_h}},
  location =	 {Leipzig},
  editor =	 {Lippert, Julius},
  date =	 1903,
  title =	 {\arb[trans]{\uc{t}a'rI_h al-.hukamA'}},
  author =	 {\prname{ibn al-qif.tiyy}}
}

@Software{usebib,
  title =	 {The Usebib package},
  subtitle =	 {A simple bibliography processor},
  author =	 {Gregorio, Enrico},
  publisher =	 {CTAN},
  url =		 {http://www.ctan.org/pkg/usebib},
  date =	 {2012-04-13},
  version =	 {1.0a}
}
\end{filecontents*}
\usepackage{fontspec}
\usepackage[american]{babel}
\usepackage[letterpaper,margin=25mm,left=50mm,nohead]{geometry}
\babelfont{rm}{Old Standard}
\babelfont{sf}{NewComputerModernSans10}
\babelfont{tt}{NewComputerModernMono10}
\usepackage{arabluatex}
\SetTranslitConvention{loc}
\usepackage[obeyspaces]{url}
\usepackage[nospace,american]{varioref}
\labelformat{section}{sect.~#1}
\labelformat{subsection}{sect.~#1}
\labelformat{subsubsection}{sect.~#1}
\labelformat{figure}{fig.~#1}
\newcommand\phts{\phantomsection}
\usepackage{latexcolors}
\usepackage[numbered]{hypdoc}
\usepackage[loadlang=en]{metastr}
\hypersetup{
  colorlinks,
  allcolors=cinnamon,
  linktocpage=true,
  pdftype={Text}
}
\metaset{titletext}{%
  \metapick[#1]{title}%
  \metacompose[#1]{subtitle}{\metaget[sep]{subtitle}}{}{}}
\metaset[print]{titletext}{%
  \metatitleline[print]{title}%
  \metatitleline[print]{subtitle}%
  \metatitleline[print]{author}%
  \metatitleline[print]{contactemail}%
  \metatitlelinetwo[print]{date}[print]{draft}}
\metaset[skip]{subtitle}{\vspace{1ex}}
\metaset[skip]{author}{\vspace{2ex}}
\metaset[skip]{date}{\vspace{1ex}}
\metaset[style]{title}{\LARGE}
\metaset[style]{author}{\large}
\metaset[sep]{draft}{ -- }
\metasetlang{en-US}
\metaset{title}{icite}
\metaset[print]{title}{\textsf{icite}}
\metaset{date}{\filedate}
\metaset{draft}{\fileversion}
\metaset{subject}{Indices locorum citatorum}
\metaset{subtitle}{Indices locorum citatorum}
\metaset[print]{subtitle}{\emph{Indices locorum citatorum}}
\metaset{author}{Robert Alessi}
\metaset{keywords}{LaTeX, Lua, bibliography, index}
\metaset{contactemail}{alessi@roberalessi.net}
\metaset[print]{contactemail}{\mailto[icite]{alessi@robertalessi.net}}
\metaset{contacturl}{http://www.roberalessi.net}
\metaset{partof}{The icite Package}
\metaset[print]{partof}{The \textsf{icite} Package}
\metaset{copyrightowner}{\metapick[#1]{author}}
\metaset{copyrightdate}{2019--2021}
\metaset{licensemessage}{Permission is granted to copy, distribute
  and/or modify this document under the terms of the GNU Free
  Documentation License, Version 1.3 or any later version published by
  the Free Software Foundation; with no Invariant Sections, no
  Front-Cover Texts, and no Back-Cover Texts.  A copy of the license
  is included in the section entitled ``GNU Free Documentation
  License''.}
\metaset{licenseurl}{https://www.gnu.org/licenses/fdl-1.3.html}
\metaset[print]{licenseurl}{%
  \url{https://www.gnu.org/licenses/fdl-1.3.html}}
\metaset[cmd]{licenselogo}{\includegraphics[scale=0.75]{#1}}
\metawritepdfinfo
\metawritepdfaux
\metawritepdfpreamble
\metawritepdfcontact
\metawritepdfrights

\usepackage{uri}

\CodelineIndex
\usepackage[citecmd=autocite,defaultindex]{\jobname}
\IndexSubtypeAs{classical}{primary}
\bibinput{icite}
\usepackage[nonewpage,xindy]{imakeidx}
\newcommand{\donothing}[1]{}
\indexsetup{level=\donothing}
\makeindex
\makeindex[name=loccit]
\makeindex[name=primary]
\usepackage{needspace}
\usepackage{tabto}
\usepackage{classics}
\newclassic{iau}{\classicsRoman{#1}|, #1|.#1}
\newclassic{razi}{#1|.#1}
\newclassic{nadim}{\classicsRoman{#1}|.#1|, #1}
\newclassic{aristotle}{#1|\textit{#1}|#1}
\usepackage[scale=1.5]{ccicons}
%^^A dox does not work with the latest latex-dev:
\ifdefined\SpecialMacroIndex
  \NewDocElement{Option}{option}
\else
  \usepackage{dox}
  \doxitem{Option}{option}{options}
\fi
\usepackage{enumitem}
\setlist{nosep}
\setlist[itemize]{label=\textendash}
\setlist[enumerate,1]{label=(\alph*)}
\setlist[enumerate,2]{label=\roman*.}
\usepackage[shortcuts, nospacearound]{extdash}
\usepackage[lot]{multitoc}
\usepackage{nameref}
\usepackage{csquotes}
\usepackage[style=oxnotes, hyperref=false]{biblatex}
\DeclareFieldFormat{postnote}{\mkpageprefix[pagination][\mknormrange]{#1}}
\addbibresource{icite.bib}
\usepackage{hologo,metalogox}
\usepackage{relsize}
\usepackage{units}
\usepackage{minted}
\usepackage[contents]{colordoc}
\newcommand{\pkg}[1]{\textsf{#1}\index{#1=#1 (package)}}
\usepackage{tikz}
\usepackage[breakable, skins, xparse, minted]{tcolorbox}
\tcbset{colback=white, boxrule=.15mm, colframe=cinnamon,
  breakable}
\newtcblisting{example}{minted options={linenos, numbersep=0mm}}
\newtcblisting{pkgcode}{minted options={linenos, numbersep=0mm}, listing
  only}
\NewDocumentCommand{\newfeature}{o}{%
  \leavevmode
  \IfNoValueTF{#1}
  {\marginpar{\hfill\emph{New feature}}}
  {\marginpar{\hfill\emph{New feature} #1}}%
  \ignorespaces
}
\usepackage{etoc}
\etocsettocdepth{paragraph}
\newcommand{\icitetableofcontents}{%
  \begingroup
  \etocsetstyle{section}{}{}
  {\etocsavedsectiontocline{%
      \numberline{\etocnumber}\etocname}{\etocpage}}{}
  \etocsetstyle{subsection}{}{}
  {\etocsavedsubsectiontocline{%
      \numberline{\etocnumber}\etocname}{\etocpage}}{}%
  \etocsetstyle{subsubsection}{}{}
  {\etocsavedsubsubsectiontocline{%
      \numberline{\etocnumber}\etocname}{\etocpage}}{}%
  \etocsetstyle{paragraph}{}{\leftskip2cm\rightskip 2.2em \parfillskip
    0pt plus 1fil\relax \nobreak}
  {\noindent\etocname{} \etocpage{} }{\par}%
  \etocmulticolstyle[2]{\section*{Contents}}
  \pdfbookmark[1]{Contents}{toc}
  \tableofcontents
  \endgroup}
\EnableCrossrefs
 %\CodelineIndex
\RecordChanges
 %\OnlyDescription
\begin{document}
 \DocInput{\jobname.dtx}
 \PrintChanges
 \section{Index}
 \indexprologue{Numbers written in italic refer to the page where the
   corresponding entry is described; numbers underlined refer to the
   code line of the definition; numbers in roman refer to the code
   lines where the entry is used.}
 \printindex
 %\PrintIndex
\end{document}
%</driver>
% \fi
%
% \CheckSum{0}
%
% \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         \~}
%
%   \makeatletter
%   \let\org@changes@\changes@
%   \def\my@changes v#1.#2.#3\@nil{%
%   \org@changes@{v#1.\six@digits{#2}.#3=v#1.#2.#3}%
% }%
%   \newcommand*{\six@digits}[1]{%
%   \ifnum#1<100000 0\fi
%   \ifnum#1<10000 0\fi
%   \ifnum#1<1000 0\fi
%   \ifnum#1<100 0\fi
%   \two@digits{#1}%
% }%
%   \renewcommand*{\changes@}[1]{%
%   \my@changes#1.\@nil
% }%
%   \makeatother
%
% \GetFileInfo{\jobname.dtx}
% \DoNotIndex{\newcommand,\newenvironment}
% 
% \pdfbookmark[1]{\metaterm{title}}{title}
% \begin{tcolorbox}[
%   colframe=black,
%   enhanced,
%   drop lifted shadow,
%   colback=white,
%   boxrule=.25mm,
%   halign=center,
%   center
%   ]
%   \metapick[print]{titletext}
% \end{tcolorbox}
%
% \footnotesize
% \icitetableofcontents
% \normalsize
%
% \changes{v1.00}{2019/03/07}{First public release}
%
% \begin{abstract}
%   \pkg{icite} is designed to produce from \hologo{BibTeX} or
%   Bib\LaTeX\ bibliographical databases the different indices of
%   authors and works cited which are called \emph{indices locorum
%   citatorum}. It relies on a specific \cs{icite} command and can
%   operate with either \hologo{BibTeX} or Bib\LaTeX.
% \end{abstract}
%
% \section*{License and Disclaimer}
% \addcontentsline{toc}{section}{License and disclamer}
% \subsection*{License Applicable to this Document}
% \pdfbookmark[2]{Licence applicable to this document}{copyright-doc}
% \leavevmode\marginpar{\hfill\texttt{fdl1.3}}
% \metapick[print]{rightstext} (See below \vref{sec:fdl}.)
%
% \subsection*{License Applicable to the Software}
% \pdfbookmark[2]{Licence applicable to the software}{copyright-soft}
% \label{sec:license-software}
%
% \pkg{icite} --- \metapick[print]{subtitle}
% \metapick[print]{copyrightstatement}
%
% Please send error reports and suggestions for improvements to Robert
% Alessi:
% \begin{itemize}
% \item email: \mailto[icite package]{Robert Alessi <alessi@roberalessi.net>}
% \item website: \url{http://www.robertalessi.net/icite}
% \item development: \url{http://git.robertalessi.net/icite}
% \item comments, feature requests, bug reports:
% \url{https://gitlab.com/ralessi/icite/issues}
% \end{itemize}
%
% \leavevmode\marginpar{\hfill\texttt{gpl3+}}
% 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 3 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, see
% \href{http://www.gnu.org/licenses}%
% {\texttt{<http://www.gnu.org/licenses/>}}.
%
% This release of \pkg{icite} consists of the following
% source files:
% \begin{itemize}
% \item |icite.dtx|
% \item |icite.ins|
% \item |Makefile|
% \end{itemize}
% 
% \section{Introduction}
% \label{sec:introduction}
% Bib\LaTeX\ features a very powerful internal mechanism which
% supports indexing of citations and bibliographic entries and can be
% activated by a simple |indexing| option in the preamble. However, by
% default, only the authors and the works cited are inserted in the
% index. Furthermore, authors and works are indexed separately and
% only inserted in the global index that is generated by
% \cs{makeindex}. Another limitation is that the references are also
% excluded from the index.
%
% Notwithstanding these limitations, it is quite possible to typeset
% \emph{indices locorum citatorum} with Bib\LaTeX, but this remains an
% intricate business and requires knowing how to redefine and/or patch
% standard and internal Bib\LaTeX\ commands.
%
% The \pkg{icite} package is but a modest piece of software which
% addresses this situation. It relies on citation commands, but does
% not require Bib\LaTeX. Instead, \hologo{BibTeX}, or even no
% bibliographic engine, can be used as \pkg{icite} uses the
% \pkg{usebib} package\footnote{\cite{usebib}} to build the indices by
% drawing directly from the bibliographical database.
%
%
% \section[The \pkg{icite} package]{The \textsf{icite} Package}
% The \pkg{icite} package is loaded as usual like so:---
% \iffalse
%<*example>
% \fi
\begin{pkgcode}
  \usepackage[<options>]{icite}
\end{pkgcode}
% \iffalse
%</example>
% \fi
%
% \pkg{icite} may be loaded with three optional \enquote*{named
% arguments} either of which is set using the syntax
% \meta{key}$=$\meta{value}. The description of the optional arguments
% follows:---
%
% \DescribeOption{citecmd}\label{ref:citecmd}
% |citecmd|$=$\meta{command}\hfill\tcboxverb{Default: cite}\\
% \meta{command} may be any citation command accepted by
% \hologo{BibTeX} or Bib\LaTeX. This option is used by the \cs{icite}
% command that is described below. By default, \cs{icite} uses the
% \cs{cite} command to insert citations in the body text.
%
% \DescribeOption{defaultindex}
% |defaultindex|$=$|none|\verb+|+\meta{index\_name}\hfill%
% \tcboxverb{Default: not set}\\
% \meta{index\_name} is the name of the index in which all passages
% cited with the \cs{icite} command are to be found by default. As
% this option is not initially set, \cs{icite} naturally inserts cited
% passages in the default general index, unless |defaultindex| is set
% to the value |none|, in which case indexing is disabled. It must be
% noted that this named argument does not need a value as it defaults
% to |loccit| if used alone. This is an easy way to have all passages
% cited indexed in a separate index named |loccit|.
%
% \DescribeOption{nobibengine}\newfeature[v1.1]
% \changes{v1.1}{2019/03/12}{New global option \texttt{nobibengine}}%
% |nobibengine|$=$|true|\verb+|+|false|\hfill%
% \tcboxverb{Default: not set}\\
% This named argument does not need a value as it defaults to |true|
% if used. When this option is activated, \pkg{icite} does not use
% \hologo{BibTeX} or Bib\LaTeX\ to insert the citations in the body
% text\---even if either be loaded in the preamble\---and pulls the
% necessary information directly from the bibliographical
% database. For this reason, \cs{bibinput} described below is of
% course still required.  The citations inserted consist of the
% elements described below \vref{sec:entry-fields}
% \vpageref{sec:entry-fields}. However, it must be noted that if the
% entry field |shorthand| of any author/work be set in the database,
% it takes precedence over the fields used to define author names and
% titles.
%
% \paragraph{Bibliographical Database}
% \DescribeMacro{\bibinput} Once \pkg{icite} is loaded, it must be
% connected to at least one bibliographic |.bib| file. To that end,
% \pkg{icite} uses the same \cs{bibinput} command as
% \pkg{usebib}.\footnote{Please refer to \cite[1]{usebib} for
% more detailed information on how to use this command.} An example
% follows:--- %
% \iffalse
%<*example>
% \fi
\begin{pkgcode}
  % load icite, have \icite use \autocite by default, and insert cited
  % passages in a separate index named 'loccit':
  \usepackage[citecmd=autocite, defaultindex]{icite}
  % note that the .bib file must be stripped of its extension:
  \bibinput{bibliography} % that is: load bibliography.bib
\end{pkgcode}
% \iffalse
%</example>
% \fi
%
% \subsection{Preamble-only Commands}
% The following commands may be found in the preamble only.
% \paragraph{Styling the Titles}
% \DescribeMacro{\SetTitleStyle} By default, \pkg{icite} prints
% the titles of the works cited in italics.\\
% \cs{SetTitleStyle}\marg{formatting directives} can be used in the
% preamble only to customize the way titles are displayed in the
% indices, like so:--- %
% \iffalse
%<*example>
% \fi
\begin{pkgcode}
  \SetTitleStyle{\textbf{#1}}
\end{pkgcode}
% \iffalse
%</example>
% \fi
% As this example shows, |#1| is the token that is replaced with the
% actual title in the formatting directives of the \cs{SetTitleStyle}
% command.
% 
% \paragraph{Delimiters}
% \DescribeMacro{\AuthorTitleDelim}\newfeature[v1.2]
% \cs{AuthorTitleDelim}\marg{delimiter} sets the delimiter between
% authors and titles in the body text when the |nobibengine| option is
% set to |true|. The default delimiter is a comma and a space.
%
% \DescribeMacro{\TitlePageDelim}
% \cs{TitlePageDelim}\marg{delimiter} sets the delimiter between
% titles and pages in the body text when the |nobibengine| option is
% set to |true|. The default delimiter is a comma and a space.
%
% \subsection[\textsf{icite} for the Impatient]%
% {\pkg{icite} for the Impatient}
% Read \href{samples/icite-minimal.pdf}{\texttt{icite-minimal.pdf}}.
%
% \subsection{Entry Fields}
% \label{sec:entry-fields}
% \subsubsection{Author Names}
% To process author names, \pkg{icite} uses the following entry
% fields:
% \begin{description}
% \item[author] As for example in |author = {Ullmann, Manfred}|, which
% is satisfactory in most cases.
% \item[indexauthor] This field is not set by Bib\LaTeX. However, it
% may be used as a fallback field for multiple or complex names.
% \item[sortname] This standard Bib\LaTeX\ field which is never
%   printed may be used to modify the sorting order of the index
%   entries.
% \end{description}
%
% \paragraph{Example}
% From a given entry such as: \\[1ex]%
% |author = {|\prname{.hunayn ibn 'is.hAq al-`ibAdiyy, 'abU
% zayd}|}|\\[1ex]%
% it may prove useful to define an additional |indexauthor| field to
% have printed in the index only the relevant part of the name, like
% so: \\[1ex]%
% |indexauthor = {|\prname{.hunayn ibn 'is.hAq}|}| or
% |indexauthor = {|\prname{.hunayn}|}|\\[1ex]
% But in the end, the |sortname| field is also needed because the
% diacritics must be discarded so that the name be sorted
% properly:\\[1ex]%
% |sortname = {{|Hunayn ibn Ishaq|}}|
%
% \subsection{Titles}
% To process titles, \pkg{icite} uses the following entry fields:
% \begin{description}
% \item[title] The full title of the work.
% \item[shorttitle] The title in an abriged form. If this entry be
% set, it takes precedence over the |title| field in the printed index.
% \item[indextitle] This field may be used to have a title such as
% \emph{The {\TeX}Book} printed in the index as \emph{{\TeX}Book, The}.
% \item[indexsorttitle] Like |sortname| for author names, this field is
% used for sorting only and is never printed. From the previous
% example, it may be used like so: \\%
% |indexsorttitle = {TEXBook}|
% \end{description}
% 
% \section{Basic Use}
% \DescribeMacro{\icite} \pkg{icite} provides the \cs{icite}
% command which both inserts a formatted citation in the body text and
% an entry corresponding to the passage cited in the index. This
% command is to be used in place of any \hologo{BibTeX} or Bib\LaTeX\
% citation command the syntax of which is
% \cs{command}\oarg{pre}\oarg{post}\marg{key}. It must be noted that
% only standard citation commands are supported, with the exception of
% those mentioned as qualified citation lists or so-called
% \enquote*{multicite} commands. The full syntax of \cs{icite}
% follows:--- %
% \iffalse
%<*example>
% \fi
\begin{pkgcode}
  \icite[<pre>][<post>]{<key>}[<command>]
\end{pkgcode}
% \iffalse
%</example>
% \fi
% Where \oarg{command} can be used as a further optional argument to
% specify a standard citation command that \cs{icite} should emulate
% instead of the default \cs{cite} command or any other command set as
% default in the preamble by means of the |citecmd| global
% option.\footnote{See above, \vref{ref:citecmd}.}
%
% \paragraph{List of References} \newfeature[v1.4]
% \changes{v1.4}{2021/07/07}{\textsf{icite} now indexes separately
% lists of references} The references inserted in the \meta{post}
% argument of \cs{icite} may consist of single numbers\---as in |25|,
% |vii| or |XIV|\---ranges of numbers\---as in |34--38| or
% |iv--x|\---or lists of numbers. In the latter case, references must
% be separated from one another by semicolons (|;|), like so: |12;|
% |21;| |34--38|.
%
% \paragraph{Example} The following example illustrates how
% \pkg{icite} can be used in combination with Bib\LaTeX\ and the
% \pkg{imakeidx} package to have the passages cited sorted and
% printed in a separate, specific \enquote*{Index of Passages
% Cited}:--- %
% \iffalse
%<*example>
% \fi
\begin{pkgcode}
  % preamble
  % load icite, have \icite use \autocite by default, and insert cited
  % passages in a separate index named 'loccit':
  \usepackage[citecmd=autocite, defaultindex]{icite}
  % load bibliography.bib
  \bibinput{bibliography}

 % load biblatex (with oxnotes, \autocite acts as \footcite)
 \usepackage[style=oxnotes]{biblatex}
 \addbibresource{bibliography.bib} % mind the extension here

 % load imakeidx and use xindy to have the numbers sorted properly
 \usepackage[xindy]{imakeidx}
 \makeindex[name=loccit, title=Index of Passages Cited (modern authors)]
\end{pkgcode}
% \iffalse
%</example>
% \fi
%
% Then \cs{icite} can be used like so:--- %
% \iffalse
%<*example>
% \fi
\begin{pkgcode}
  \section*{\cs{icite} in Action}
  Let us start with four citations of the same reference, to make sure
  that they are all indexed and sorted properly: one\icite[123;
  141--148; 245]{Ullmann1970}, two\icite[231]{Ullmann1970},
  three\icite[81]{Ullmann1970} and four\icite[18]{Ullmann1970}.

  Let us continue with four other citations out of two other
  references: one\icite[90]{Bürgel2016}, two\icite[370]{Dols1987},
  three\icite[205]{Bürgel2016} and four\icite[380]{Dols1987}.

  Finally, let us have \cs{icite} use \cs{textcite} to cite
  \icite[123]{Endress1992}[textcite], and again, this time in a
  footnote\icite[86]{Endress1992}.
\end{pkgcode}
% \iffalse
%</example>
% \fi
% 
% \begin{tcblisting}{text only}
%   \section*{\cs{icite} in Action}
%   Let us start with four citations of the same reference, to make
%   sure that they are all indexed and sorted properly: one\icite[123;
%   141--148; 245]{Ullmann1970}, two\icite[231]{Ullmann1970},
%   three\icite[81]{Ullmann1970} and four\icite[18]{Ullmann1970}.
%
%   Let us continue with four other citations out of two other
%   references: one\icite[90]{Bürgel2016}, two\icite[370]{Dols1987},
%   three\icite[205]{Bürgel2016} and four\icite[380]{Dols1987}.
%
%   Finally, let us have \cs{icite} use \cs{textcite} to cite
%   \icite[123]{Endress1992}[textcite], and again, this time in a
%   footnote\icite[86]{Endress1992}.
% \end{tcblisting}
% 
% All indices and the contents of the \hologo{BibTeX} file that has
% been used can be found below in the appendix
% (\vrefrange{ref:indices}{ref:icite-bib} respectively). As can be
% seen by comparing the bibliography generated in the footnotes with
% the text printed in the index, \pkg{icite} prints as expected
% the abridged forms of the titles when they are
% available. Furthermore, as a default citation command set in the
% preamble, the \enquote*{oxnotes} Bib\LaTeX\ option of
% \pkg{biblatex-oxref} style package makes \cs{autocite} behave
% like \cs{footcite}. Finally, the page numbers in the index are
% sorted properly: for example, two-digit numbers, like 81, are listed
% before 123.
%
% \section{Refined Use}
% When references are made not only to modern authors but also to
% authors and works from classical antiquity or from the Middle Ages,
% it is commonly agreed that at least two separate indices of passages
% cited should be made. Another option is not to index passages cited
% from modern authors at all.
%
% \DescribeMacro{\IndexSubtypeAs} \pkg{icite} is able to
% differentiate between sources by drawing from the bibliographical
% database the exact string that may be found in the |entrysubtype|
% entry field. To that end, the \cs{IndexSubtypeAs} command is
% provided. It takes to mandatory arguments, like so:--- %
% \iffalse
%<*example>
% \fi
\begin{pkgcode}
  \IndexSubtypeAs{<subtype>}{<index_name>}
\end{pkgcode}
% \iffalse
%</example>
% \fi
% Where |<subtype>| is any given string used to specify an
% |entrysubtype| in the bibliographical database, and |<index_name>|
% the name of the index which the authors matching that subtype must
% go into. This command is to be found in the preamble only.
%
% Of course different subtypes can be associated with a single index
% or with different indices. That said, one should keep in mind that
% any entry the actual subtype of which is not associated with an
% index is processed as if it had no subtype at all. Examples
% follow:--- %
% \iffalse
%<*example>
% \fi
\begin{pkgcode}
  % load icite, and have cited authors indexed in an index named
  % 'secondary':
  \usepackage[defaultindex=secondary]{icite}
  % except for authors whose 'entrysubtype' field matches the string
  % 'classical': have them indexed in an index named 'primary':
  \IndexSubtypeAs{classical}{primary}
  % authors whose 'entrysubtype' field matches the string 'medieval'
  % should go into the same index:
  \IndexSubtypeAs{medieval}{primary}
\end{pkgcode}
% \iffalse
%</example>
% \fi
% Or:
% \iffalse
%<*example>
% \fi
\begin{pkgcode}
  % load icite, but do not index passages cited with \icite:
  \usepackage[defaultindex=none]{icite}
  % except for authors whose 'entrysubtype' field matches the string
  % 'classical': have them indexed in an index named 'primary':
  \IndexSubtypeAs{classical}{primary}
  % authors whose 'entrysubtype' field matches the string 'medieval'
  % should go into the same index:
  \IndexSubtypeAs{medieval}{primary}
\end{pkgcode}
% \iffalse
%</example>
% \fi
%
% \paragraph{Example} In the following example, modern authors, namely
% those whose |entrysubtype| field does not match the string
% |classical| should go into the default |loccit| index. As for those
% whose |entrysubtype| matches |classical|, they should to into an
% index named |primary|. \label{ref:classics-pkg}Furthermore, the
% \pkg{classics} package is used to format references in which a
% volume number is used.\footnote{For more information, see below
% \vref{sec:classics-usage}.} In this way, \pkg{xindy} only has
% numbers to handle:--- %
% \iffalse
%<*example>
% \fi
\begin{pkgcode}
  % preamble
  \usepackage[style=oxnotes]{biblatex}
  \addbibresource{bibliography.bib}

  \usepackage[xindy]{imakeidx}
  \makeindex[name=loccit, title=Index of passages cited (modern authors)]
  \makeindex[name=primary, title=\emph{Index locorum citatorum}]

  \usepackage{classics}
  \newclassic{iau}{\classicsRoman{#1}|, #1|.#1}
  \newclassic{razi}{#1|.#1}
  \newclassic{nadim}{\classicsRoman{#1}|.#1|, #1}
  
  \usepackage[citecmd=autocite,defaultindex]{icite}
  \IndexSubtypeAs{classical}{primary}
\end{pkgcode}
% \iffalse
%</example>
% \fi
% 
% Then \cs{icite} can be used like so:--- %
% \iffalse
%<*example>
% \fi
\begin{pkgcode}
  \section*{\cs{icite} in Action}
  Let us start with four citations of the same reference, to make sure
  that they are all indexed and sorted properly: one\icite[123;
  141--148; 245]{Ullmann1970}, two\icite[231]{Ullmann1970},
  three\icite[81]{Ullmann1970} and four\icite[18]{Ullmann1970}.

  Let us continue with four other citations out of two other
  references: one\icite[90]{Bürgel2016}, two\icite[370]{Dols1987},
  three\icite[205]{Bürgel2016} and four\icite[380]{Dols1987}.

  Before concluding, let us insert a few references to medieval Arabic
  authors: one\icite[\iau{1}[81][32]]{IAUMuller},
  two\icite[\razi{5}[7--10]]{RaziShukuk}, three\icite[133]{al-Qifti},
  four\icite[\nadim{3}[7][286]]{al-Nadim},
  five\icite[\iau{2}[214][20]]{IAUMuller},
  six\icite[\razi{1}[6--20]]{RaziShukuk},
  seven\icite[126.15--20]{al-Qifti} and
  eight\icite[\nadim{3}[7][291]]{al-Nadim}.

  Finally, let us have \cs{icite} use \cs{textcite} to cite
  \icite[123]{Endress1992}[textcite], and again, this time in a
  footnote\icite[86]{Endress1992}.
\end{pkgcode}
% \iffalse
%</example>
% \fi
%
% \begin{tcblisting}{text only}
%   \section*{\cs{icite} in Action}
%   Let us start with four citations of the same reference, to make
%   sure that they are all indexed and sorted properly: one\icite[123;
%   141--148; 245]{Ullmann1970}, two\icite[231]{Ullmann1970},
%   three\icite[81]{Ullmann1970} and four\icite[18]{Ullmann1970}.
%
%   Let us continue with four other citations out of two other
%   references: one\icite[90]{Bürgel2016}, two\icite[370]{Dols1987},
%   three\icite[205]{Bürgel2016} and four\icite[380]{Dols1987}.
%
%   Before concluding, let us insert a few references to medieval
%   Arabic authors: one\icite[\iau{1}[81][32]]{IAUMuller},
%   two\icite[\razi{5}[7--10]]{RaziShukuk},
%   three\icite[133]{al-Qifti},
%   four\icite[\nadim{3}[7][286]]{al-Nadim},
%   five\icite[\iau{2}[214][20]]{IAUMuller},
%   six\icite[\razi{1}[6--20]]{RaziShukuk},
%   seven\icite[126.15--20]{al-Qifti} and
%   eight\icite[\nadim{3}[7][291]]{al-Nadim}.
%
%   Finally, let us have \cs{icite} use \cs{textcite} to cite
%   \icite[123]{Endress1992}[textcite], and again, this time in a
%   footnote\icite[86]{Endress1992}.
% \end{tcblisting}
%
% As already said above, all indices and the contents of the
% \hologo{BibTeX} file that has been used can be found below in the
% appendix (\vrefrange{ref:indices}{ref:icite-bib} respectively). As
% one can see, \prname{al-rAziyy} has been sorted under the letter R
% and references to classical works have been formatted properly.
%
%
% \subsection[The \textsf{classics} package]%
% {The \pkg{classics} Package} %
% \label{sec:classics-usage}
% As said above \vpageref{ref:classics-pkg}, it is advisable to use
% the \pkg{classics} package to format volume, page, column, line
% numbers and the like which are inserted in the \meta{post} optional
% argument of the \cs{icite} command\autocite{classics}. An example of
% using \pkg{classics} to format references to Aristotle according
% to Bekker pagination follows:\footnote{See \cite[2]{classics} for
% more information.}--- %
% \iffalse
%<*example>
% \fi
\begin{pkgcode}
  % preamble:
  \usepackage{classics}
  \newclassic{aristotle}{#1|\textit{#1}|#1}
\end{pkgcode}
% \iffalse
%</example>
% \fi
% \iffalse
%<*example>
% \fi
\begin{example}
  In \emph{Politics}, Aristotle says that man is by nature a political
  animal in the following passages: \aristotle{1253}[a][2--9] (Book~1)
  and again in \aristotle{1278}[b][19] (Book~3). The latter passage
  shows that one should read the whole section of Book~1 concerning
  household management and the control of slaves
  (\aristotle*{1253}[b][1]{1253}[b][39]).
\end{example}
% \iffalse
%</example>
% \fi
% The following prints the same body text while using \pkg{icite}
% to have the passages cited inserted in the \emph{Index locorum
% citatorum} (see below \vref{sec:index-loc-cit}):--- %
% \iffalse
%<*example>
% \fi
\begin{example}
  In \emph{Politics}, Aristotle says that man is by nature a political
  animal in the following passages:
  \icite[\aristotle{1253}[a][2--9]]{Aristotle:Politica}[notecite]
  (Book~1) and again in \icite[\aristotle{1278}[b][19]]%
  {Aristotle:Politica}[notecite] (Book~3). The latter passage shows
  that one should read the whole section of Book~1 concerning
  household management and the control of slaves
  \icite[\aristotle*{1253}[b][1]{1253}[b][39]]%
  {Aristotle:Politica}[pnotecite].
\end{example}
% \iffalse
%</example>
% \fi
% As can be seen, the \cs{notecite} and \cs{pnotecite} commands have
% been used to insert only the references in the body text.
%
% It is also advisable to use \pkg{xindy} to compile indices of
% passages cited because \pkg{xindy}, unlike \pkg{makeindex}
% or \pkg{xindex}, is able to sort numbers properly: for example,
% with \pkg{xindy}, such a number as 81 will come before 100, but
% will be sorted after 100 with the other two engines.
% \begin{tcblisting}{text only, title=Caveat}
%   \pkg{xindy} (actually |texindy|) is also designed to ignore
%   \TeX\ commands by default. However, due to a missing line in
%   |xindy/modules/base/tex.xdy|,\footnote{As the time of writing, in
%   \pkg{xindy} v2.5.1.} this does not apply to so-called
%   \enquote*{starred} \TeX\ commands, such as \cs{aristotle*} from
%   the example above.
% \end{tcblisting}
% One easy way to get around this issue is to create a style file with
% a single line that instructs \pkg{xindy} to ignore the asterisk
% when processing the index, like so:--- %
% \iffalse
%<*example>
% \fi
\begin{tcblisting}{minted language=lisp, listing only, title=icite.xdy}
  (merge-rule "\*" "" :eregexp)
\end{tcblisting}
% \iffalse
%</example>
% \fi
% 
% The following example shows how this simple rule can be
% applied:--- %
% \iffalse
%<*example>
% \fi
\begin{pkgcode}
  % preamble:
  \usepackage[xindy]{imakeidx}
  \makeindex[name=loccit, options=-M icite.xdy]
  % document:
  \printindex[loccit]
\end{pkgcode}
% \iffalse
%</example>
% \fi
% Of course, the document itself must be compiled with
% |--shell-escape|.\footnote{See \cite[2--4]{imakeidx}.}
%
% \section{Appendix}
% Designing the layout of indices is out of the scope of this
% documentation. For information, the \pkg{tabto} package has been
% used in the preamble in combination with the following |xindy| style
% file:--- %
% \iffalse
%<*example>
% \fi
\begin{tcblisting}{minted language=lisp, listing only,
    title=icite.xdy}
(markup-locclass-list :open "\tabto{3.5cm}" :sep ", ")
\end{tcblisting}
% \iffalse
%</example>
% \fi
%
% \subsection{Indices}
% \label{ref:indices}
% \subsubsection{Index of Passages Cited (Modern Authors)}
% \printindex[loccit]
% \needspace{8\baselineskip}
% \subsubsection{\emph{Index locorum citatorum}}
% \label{sec:index-loc-cit}
% \printindex[primary]
% 
% \subsection{\texorpdfstring{\hologo{BibTeX}
% File Used in this Document}{BibTeX File Used in this Document}}
% \label{ref:icite-bib}
% \tcbinputlisting{minted options={linenos, numbersep=1.5mm}, minted
% language=bibtex, listing file=icite.bib, listing only}
%
% \section{GNU Free Documentation License}
% \label{sec:fdl}
% \textbf{Version 1.3, 3 November 2008}
% 
% \begin{center}
%   Version 1.3, 3 November 2008
%   
%   Copyright \copyright{} 2000, 2001, 2002, 2007, 2008 Free
%   Software Foundation, Inc.
%   
%   \bigskip
%   
%   \url{https://fsf.org/}
%   
%   \bigskip
%   
%   Everyone is permitted to copy and distribute verbatim copies
%   of this license document, but changing it is not allowed.
% \end{center}
% 
% \needspace{3\baselineskip}
% \begin{center}
%   {\bf\large Preamble}
% \end{center}
% 
% The purpose of this License is to make a manual, textbook, or other
% functional and useful document \enquote{free} in the sense of
% freedom: to assure everyone the effective freedom to copy and
% redistribute it, with or without modifying it, either commercially
% or noncommercially.  Secondarily, this License preserves for the
% author and publisher a way to get credit for their work, while not
% being considered responsible for modifications made by others.
% 
% This License is a kind of \enquote{copyleft}, which means that
% derivative works of the document must themselves be free in the same
% sense.  It complements the GNU General Public License, which is a
% copyleft license designed for free software.
% 
% We have designed this License in order to use it for manuals for
% free software, because free software needs free documentation: a
% free program should come with manuals providing the same freedoms
% that the software does.  But this License is not limited to software
% manuals; it can be used for any textual work, regardless of subject
% matter or whether it is published as a printed book.  We recommend
% this License principally for works whose purpose is instruction or
% reference.
% 
% \needspace{3\baselineskip}
% \begin{center}
%   {\large\bf 1. APPLICABILITY AND DEFINITIONS\par}
% \end{center}
% 
% This License applies to any manual or other work, in any medium,
% that contains a notice placed by the copyright holder saying it can
% be distributed under the terms of this License.  Such a notice
% grants a world-wide, royalty-free license, unlimited in duration, to
% use that work under the conditions stated herein.  The
% \enquote{\textbf{Document}}, below, refers to any such manual or
% work.  Any member of the public is a licensee, and is addressed as
% \enquote{\textbf{you}}.  You accept the license if you copy, modify
% or distribute the work in a way requiring permission under copyright
% law.
% 
% A \enquote{\textbf{Modified Version}} of the Document means any work
% containing the Document or a portion of it, either copied verbatim,
% or with modifications and/or translated into another language.
% 
% A \enquote{\textbf{Secondary Section}} is a named appendix or a
% front-matter section of the Document that deals exclusively with the
% relationship of the publishers or authors of the Document to the
% Document's overall subject (or to related matters) and contains
% nothing that could fall directly within that overall subject.
% (Thus, if the Document is in part a textbook of mathematics, a
% Secondary Section may not explain any mathematics.)  The
% relationship could be a matter of historical connection with the
% subject or with related matters, or of legal, commercial,
% philosophical, ethical or political position regarding them.
% 
% The \enquote{\textbf{Invariant Sections}} are certain Secondary
% Sections whose titles are designated, as being those of Invariant
% Sections, in the notice that says that the Document is released
% under this License.  If a section does not fit the above definition
% of Secondary then it is not allowed to be designated as Invariant.
% The Document may contain zero Invariant Sections.  If the Document
% does not identify any Invariant Sections then there are none.
% 
% The \enquote{\textbf{Cover Texts}} are certain short passages of
% text that are listed, as Front-Cover Texts or Back-Cover Texts, in
% the notice that says that the Document is released under this
% License.  A Front-Cover Text may be at most 5 words, and a
% Back-Cover Text may be at most 25 words.
% 
% A \enquote{\textbf{Transparent}} copy of the Document means a
% machine-readable copy, represented in a format whose specification
% is available to the general public, that is suitable for revising
% the document straightforwardly with generic text editors or (for
% images composed of pixels) generic paint programs or (for drawings)
% some widely available drawing editor, and that is suitable for input
% to text formatters or for automatic translation to a variety of
% formats suitable for input to text formatters.  A copy made in an
% otherwise Transparent file format whose markup, or absence of
% markup, has been arranged to thwart or discourage subsequent
% modification by readers is not Transparent.  An image format is not
% Transparent if used for any substantial amount of text.  A copy that
% is not \enquote{Transparent} is called \enquote{\textbf{Opaque}}.
% 
% Examples of suitable formats for Transparent copies include plain
% ASCII without markup, Texinfo input format, LaTeX input format, SGML
% or XML using a publicly available DTD, and standard-conforming
% simple HTML, PostScript or PDF designed for human modification.
% Examples of transparent image formats include PNG, XCF and JPG.
% Opaque formats include proprietary formats that can be read and
% edited only by proprietary word processors, SGML or XML for which
% the DTD and/or processing tools are not generally available, and the
% machine-generated HTML, PostScript or PDF produced by some word
% processors for output purposes only.
% 
% The \enquote{\textbf{Title Page}} means, for a printed book, the
% title page itself, plus such following pages as are needed to hold,
% legibly, the material this License requires to appear in the title
% page.  For works in formats which do not have any title page as
% such, \enquote{Title Page} means the text near the most prominent
% appearance of the work's title, preceding the beginning of the body
% of the text.
% 
% The \enquote{\textbf{publisher}} means any person or entity that
% distributes copies of the Document to the public.
% 
% A section \enquote{\textbf{Entitled XYZ}} means a named subunit of
% the Document whose title either is precisely XYZ or contains XYZ in
% parentheses following text that translates XYZ in another language.
% (Here XYZ stands for a specific section name mentioned below, such
% as \enquote{\textbf{Acknowledgements}},
% \enquote{\textbf{Dedications}}, \enquote{\textbf{Endorsements}}, or
% \enquote{\textbf{History}}.)  To \enquote{\textbf{Preserve the
% Title}} of such a section when you modify the Document means that it
% remains a section \enquote{Entitled XYZ} according to this
% definition.
% 
% The Document may include Warranty Disclaimers next to the notice
% which states that this License applies to the Document.  These
% Warranty Disclaimers are considered to be included by reference in
% this License, but only as regards disclaiming warranties: any other
% implication that these Warranty Disclaimers may have is void and has
% no effect on the meaning of this License.
% 
% \needspace{3\baselineskip}
% \begin{center}
%   {\large\bf 2. VERBATIM COPYING\par}
% \end{center}
% 
% You may copy and distribute the Document in any medium, either
% commercially or noncommercially, provided that this License, the
% copyright notices, and the license notice saying this License
% applies to the Document are reproduced in all copies, and that you
% add no other conditions whatsoever to those of this License.  You
% may not use technical measures to obstruct or control the reading or
% further copying of the copies you make or distribute.  However, you
% may accept compensation in exchange for copies.  If you distribute a
% large enough number of copies you must also follow the conditions in
% section~3.
% 
% You may also lend copies, under the same conditions stated above,
% and you may publicly display copies.
% 
% \needspace{3\baselineskip}
% \begin{center}
%   {\large\bf 3. COPYING IN QUANTITY\par}
% \end{center}
% 
% If you publish printed copies (or copies in media that commonly have
% printed covers) of the Document, numbering more than 100, and the
% Document's license notice requires Cover Texts, you must enclose the
% copies in covers that carry, clearly and legibly, all these Cover
% Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on
% the back cover.  Both covers must also clearly and legibly identify
% you as the publisher of these copies.  The front cover must present
% the full title with all words of the title equally prominent and
% visible.  You may add other material on the covers in addition.
% Copying with changes limited to the covers, as long as they preserve
% the title of the Document and satisfy these conditions, can be
% treated as verbatim copying in other respects.
% 
% If the required texts for either cover are too voluminous to fit
% legibly, you should put the first ones listed (as many as fit
% reasonably) on the actual cover, and continue the rest onto adjacent
% pages.
% 
% If you publish or distribute Opaque copies of the Document numbering
% more than 100, you must either include a machine-readable
% Transparent copy along with each Opaque copy, or state in or with
% each Opaque copy a computer-network location from which the general
% network-using public has access to download using public-standard
% network protocols a complete Transparent copy of the Document, free
% of added material.  If you use the latter option, you must take
% reasonably prudent steps, when you begin distribution of Opaque
% copies in quantity, to ensure that this Transparent copy will remain
% thus accessible at the stated location until at least one year after
% the last time you distribute an Opaque copy (directly or through
% your agents or retailers) of that edition to the public.
% 
% It is requested, but not required, that you contact the authors of
% the Document well before redistributing any large number of copies,
% to give them a chance to provide you with an updated version of the
% Document.
% 
% \needspace{3\baselineskip}
% \begin{center}
%   {\large\bf 4. MODIFICATIONS\par}
% \end{center}
% 
% You may copy and distribute a Modified Version of the Document under
% the conditions of sections 2 and 3 above, provided that you release
% the Modified Version under precisely this License, with the Modified
% Version filling the role of the Document, thus licensing
% distribution and modification of the Modified Version to whoever
% possesses a copy of it.  In addition, you must do these things in
% the Modified Version:
% 
% \begin{itemize}
% \item[A.]  Use in the Title Page (and on the covers, if any) a title
%   distinct from that of the Document, and from those of previous
%   versions (which should, if there were any, be listed in the
%   History section of the Document).  You may use the same title as a
%   previous version if the original publisher of that version gives
%   permission.
%    
%  \item[B.]  List on the Title Page, as authors, one or more persons
%    or entities responsible for authorship of the modifications in
%    the Modified Version, together with at least five of the
%    principal authors of the Document (all of its principal authors,
%    if it has fewer than five), unless they release you from this
%    requirement.
%    
%  \item[C.]  State on the Title page the name of the publisher of the
%    Modified Version, as the publisher.
%    
%  \item[D.]  Preserve all the copyright notices of the Document.
%    
%  \item[E.]  Add an appropriate copyright notice for your
%    modifications adjacent to the other copyright notices.
%    
%  \item[F.]  Include, immediately after the copyright notices, a
%    license notice giving the public permission to use the Modified
%    Version under the terms of this License, in the form shown in the
%    Addendum below.
%    
%  \item[G.]  Preserve in that license notice the full lists of
%    Invariant Sections and required Cover Texts given in the
%    Document's license notice.
%    
%  \item[H.]  Include an unaltered copy of this License.
%    
%  \item[I.]  Preserve the section Entitled \enquote{History},
%    Preserve its Title, and add to it an item stating at least the
%    title, year, new authors, and publisher of the Modified Version
%    as given on the Title Page.  If there is no section Entitled
%    \enquote{History} in the Document, create one stating the title,
%    year, authors, and publisher of the Document as given on its
%    Title Page, then add an item describing the Modified Version as
%    stated in the previous sentence.
%    
%  \item[J.]  Preserve the network location, if any, given in the
%    Document for public access to a Transparent copy of the Document,
%    and likewise the network locations given in the Document for
%    previous versions it was based on.  These may be placed in the
%    \enquote{History} section.  You may omit a network location for a
%    work that was published at least four years before the Document
%    itself, or if the original publisher of the version it refers to
%    gives permission.
%    
%  \item[K.]  For any section Entitled \enquote{Acknowledgements} or
%    \enquote{Dedications}, Preserve the Title of the section, and
%    preserve in the section all the substance and tone of each of the
%    contributor acknowledgements and/or dedications given therein.
%    
%  \item[L.]  Preserve all the Invariant Sections of the Document,
%    unaltered in their text and in their titles.  Section numbers or
%    the equivalent are not considered part of the section titles.
%    
%  \item[M.]  Delete any section Entitled \enquote{Endorsements}.
%    Such a section may not be included in the Modified Version.
%    
%  \item[N.]  Do not retitle any existing section to be Entitled
%    \enquote{Endorsements} or to conflict in title with any Invariant
%    Section.
%    
%  \item[O.]  Preserve any Warranty Disclaimers.
% \end{itemize}
% 
% If the Modified Version includes new front-matter sections or
% appendices that qualify as Secondary Sections and contain no
% material copied from the Document, you may at your option designate
% some or all of these sections as invariant.  To do this, add their
% titles to the list of Invariant Sections in the Modified Version's
% license notice.  These titles must be distinct from any other
% section titles.
% 
% You may add a section Entitled \enquote{Endorsements}, provided it
% contains nothing but endorsements of your Modified Version by
% various parties---for example, statements of peer review or that the
% text has been approved by an organization as the authoritative
% definition of a standard.
% 
% You may add a passage of up to five words as a Front-Cover Text, and
% a passage of up to 25 words as a Back-Cover Text, to the end of the
% list of Cover Texts in the Modified Version.  Only one passage of
% Front-Cover Text and one of Back-Cover Text may be added by (or
% through arrangements made by) any one entity.  If the Document
% already includes a cover text for the same cover, previously added
% by you or by arrangement made by the same entity you are acting on
% behalf of, you may not add another; but you may replace the old one,
% on explicit permission from the previous publisher that added the
% old one.
% 
% The author(s) and publisher(s) of the Document do not by this
% License give permission to use their names for publicity for or to
% assert or imply endorsement of any Modified Version.
% 
% \needspace{3\baselineskip}
% \begin{center}
%   {\large\bf 5. COMBINING DOCUMENTS\par}
% \end{center}
% 
% You may combine the Document with other documents released under
% this License, under the terms defined in section~4 above for
% modified versions, provided that you include in the combination all
% of the Invariant Sections of all of the original documents,
% unmodified, and list them all as Invariant Sections of your combined
% work in its license notice, and that you preserve all their Warranty
% Disclaimers.
% 
% The combined work need only contain one copy of this License, and
% multiple identical Invariant Sections may be replaced with a single
% copy.  If there are multiple Invariant Sections with the same name
% but different contents, make the title of each such section unique
% by adding at the end of it, in parentheses, the name of the original
% author or publisher of that section if known, or else a unique
% number.  Make the same adjustment to the section titles in the list
% of Invariant Sections in the license notice of the combined work.
% 
% In the combination, you must combine any sections Entitled
% \enquote{History} in the various original documents, forming one
% section Entitled \enquote{History}; likewise combine any sections
% Entitled \enquote{Acknowledgements}, and any sections Entitled
% \enquote{Dedications}.  You must delete all sections Entitled
% \enquote{Endorsements}.
% 
% \needspace{3\baselineskip}
% \begin{center}
%   {\large\bf 6. COLLECTIONS OF DOCUMENTS\par}
% \end{center}
% 
% You may make a collection consisting of the Document and other
% documents released under this License, and replace the individual
% copies of this License in the various documents with a single copy
% that is included in the collection, provided that you follow the
% rules of this License for verbatim copying of each of the documents
% in all other respects.
% 
% You may extract a single document from such a collection, and
% distribute it individually under this License, provided you insert a
% copy of this License into the extracted document, and follow this
% License in all other respects regarding verbatim copying of that
% document.
% 
% \needspace{3\baselineskip}
% \begin{center}
% {\large\bf 7. AGGREGATION WITH INDEPENDENT WORKS\par}
% \end{center}
% 
% A compilation of the Document or its derivatives with other separate
% and independent documents or works, in or on a volume of a storage
% or distribution medium, is called an \enquote{aggregate} if the
% copyright resulting from the compilation is not used to limit the
% legal rights of the compilation's users beyond what the individual
% works permit.  When the Document is included in an aggregate, this
% License does not apply to the other works in the aggregate which are
% not themselves derivative works of the Document.
% 
% If the Cover Text requirement of section~3 is applicable to these
% copies of the Document, then if the Document is less than one half
% of the entire aggregate, the Document's Cover Texts may be placed on
% covers that bracket the Document within the aggregate, or the
% electronic equivalent of covers if the Document is in electronic
% form.  Otherwise they must appear on printed covers that bracket the
% whole aggregate.
% 
% \needspace{3\baselineskip}
% \begin{center}
%   {\large\bf 8. TRANSLATION\par}
% \end{center}
% 
% Translation is considered a kind of modification, so you may
% distribute translations of the Document under the terms of
% section~4.  Replacing Invariant Sections with translations requires
% special permission from their copyright holders, but you may include
% translations of some or all Invariant Sections in addition to the
% original versions of these Invariant Sections.  You may include a
% translation of this License, and all the license notices in the
% Document, and any Warranty Disclaimers, provided that you also
% include the original English version of this License and the
% original versions of those notices and disclaimers.  In case of a
% disagreement between the translation and the original version of
% this License or a notice or disclaimer, the original version will
% prevail.
% 
% If a section in the Document is Entitled \enquote{Acknowledgements},
% \enquote{Dedications}, or \enquote{History}, the requirement
% (section~4) to Preserve its Title (section~1) will typically require
% changing the actual title.
% 
% \needspace{3\baselineskip}
% \begin{center}
%   {\large\bf 9. TERMINATION\par}
% \end{center}
% 
% You may not copy, modify, sublicense, or distribute the Document
% except as expressly provided under this License.  Any attempt
% otherwise to copy, modify, sublicense, or distribute it is void, and
% will automatically terminate your rights under this License.
% 
% However, if you cease all violation of this License, then your
% license from a particular copyright holder is reinstated (a)
% provisionally, unless and until the copyright holder explicitly and
% finally terminates your license, and (b) permanently, if the
% copyright holder fails to notify you of the violation by some
% reasonable means prior to 60 days after the cessation.
% 
% Moreover, your license from a particular copyright holder is
% reinstated permanently if the copyright holder notifies you of the
% violation by some reasonable means, this is the first time you have
% received notice of violation of this License (for any work) from
% that copyright holder, and you cure the violation prior to 30 days
% after your receipt of the notice.
% 
% Termination of your rights under this section does not terminate the
% licenses of parties who have received copies or rights from you
% under this License.  If your rights have been terminated and not
% permanently reinstated, receipt of a copy of some or all of the same
% material does not give you any rights to use it.
% 
% \needspace{3\baselineskip}
% \begin{center}
%   {\large\bf 10. FUTURE REVISIONS OF THIS LICENSE\par}
% \end{center}
% 
% The Free Software Foundation may publish new, revised versions of
% the GNU Free Documentation License from time to time.  Such new
% versions will be similar in spirit to the present version, but may
% differ in detail to address new problems or concerns.  See
% \url{https://www.gnu.org/licenses/}.
% 
% Each version of the License is given a distinguishing version
% number.  If the Document specifies that a particular numbered
% version of this License \enquote{or any later version} applies to
% it, you have the option of following the terms and conditions either
% of that specified version or of any later version that has been
% published (not as a draft) by the Free Software Foundation.  If the
% Document does not specify a version number of this License, you may
% choose any version ever published (not as a draft) by the Free
% Software Foundation.  If the Document specifies that a proxy can
% decide which future versions of this License can be used, that
% proxy's public statement of acceptance of a version permanently
% authorizes you to choose that version for the Document.
% 
% \needspace{3\baselineskip}
% \begin{center}
%   {\large\bf 11. RELICENSING\par}
% \end{center}
% 
% \enquote{Massive Multiauthor Collaboration Site} (or \enquote{MMC
% Site}) means any World Wide Web server that publishes copyrightable
% works and also provides prominent facilities for anybody to edit
% those works.  A public wiki that anybody can edit is an example of
% such a server.  A \enquote{Massive Multiauthor Collaboration} (or
% \enquote{MMC}) contained in the site means any set of copyrightable
% works thus published on the MMC site.
% 
% \enquote{CC-BY-SA} means the Creative Commons Attribution-Share
% Alike 3.0 license published by Creative Commons Corporation, a
% not-for-profit corporation with a principal place of business in San
% Francisco, California, as well as future copyleft versions of that
% license published by that same organization.
% 
% \enquote{Incorporate} means to publish or republish a Document, in
% whole or in part, as part of another Document.
% 
% An MMC is \enquote{eligible for relicensing} if it is licensed under
% this License, and if all works that were first published under this
% License somewhere other than this MMC, and subsequently incorporated
% in whole or in part into the MMC, (1) had no cover texts or
% invariant sections, and (2) were thus incorporated prior to November
% 1, 2008.
% 
% The operator of an MMC Site may republish an MMC contained in the
% site under CC-BY-SA on the same site at any time before August 1,
% 2009, provided the MMC is eligible for relicensing.
% 
% \needspace{3\baselineskip}
% \begin{center}
%   {\large\bf ADDENDUM: How to use this License for your documents\par}
% \end{center}
% 
% To use this License in a document you have written, include a copy
% of the License in the document and put the following copyright and
% license notices just after the title page:
% 
% \bigskip
% \begin{quote}
%   Copyright \copyright{} YEAR YOUR NAME.  Permission is granted to
%   copy, distribute and/or modify this document under the terms of
%   the GNU Free Documentation License, Version 1.3 or any later
%   version published by the Free Software Foundation; with no
%   Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
%   A copy of the license is included in the section entitled
%   \enquote{GNU Free Documentation License}.
% \end{quote}
% \bigskip
%     
% If you have Invariant Sections, Front-Cover Texts and Back-Cover
% Texts, replace the \enquote{with \dots\ Texts.}\ line with this:
% 
% \bigskip
% \begin{quote}
%   with the Invariant Sections being LIST THEIR TITLES, with the
%   Front-Cover Texts being LIST, and with the Back-Cover Texts being LIST.
% \end{quote}
% \bigskip
%     
% If you have Invariant Sections without Cover Texts, or some other
% combination of the three, merge those two alternatives to suit the
% situation.
% 
% If your document contains nontrivial examples of program code, we
% recommend releasing these examples in parallel under your choice of
% free software license, such as the GNU General Public License,
% to permit their use in free software.
%
%
%\StopEventually{}
%
% \section{Implementation}
%
% \iffalse
%<*package>
% \fi
% Declare the global options, and define them:
%    \begin{macrocode}
\RequirePackage{xkeyval}
\DeclareOptionX{citecmd}[cite]{\def\ic@dfltcit{#1}}
\newif\ifdefault@index
\newif\ifno@index
\DeclareOptionX{defaultindex}[loccit]{
  \edef\@tempa{#1}
  \edef\@none{none}
  \ifx\@tempa\@none
  \no@indextrue
  \else
  \default@indextrue
  \def\ic@dfltind{#1}
  \fi
}
\newif\ifno@bibengine
\define@boolkey{icite.sty}[@pkg@]{nobibengine}[true]{%
  \if@pkg@nobibengine\no@bibenginetrue\else\fi}
\ExecuteOptionsX{citecmd}
\ProcessOptionsX\relax
%    \end{macrocode}
% The following packages are required by \pkg{icite}:
%    \begin{macrocode}
\RequirePackage{xparse}
\RequirePackage{datatool}
\RequirePackage{usebib}
%    \end{macrocode}
% If |nobibengine| is set to true, then \cs{ic@dfltcit} will be
% redefined by \cs{icite} to \cs{ic@nullcmd} which does nothing.
%    \begin{macrocode}
\NewDocumentCommand{\ic@nullcmd}{O{}O{}m}{}
%    \end{macrocode}
% Define fields to be used by \pkg{icite}:
%    \begin{macrocode}
\define@reuse@key{author}
\define@reuse@key{indexauthor}
\define@reuse@key{sortname}
\define@reuse@key{title}
\define@reuse@key{shorttitle}
\define@reuse@key{indextitle}
\define@reuse@key{indexsorttitle}
\define@reuse@key{entrysubtype}
\define@reuse@key{shorthand}
%    \end{macrocode}
% This is the same as \cs{usebibentry} from \pkg{ebib}, but it
% does not return an error if the entry field is not found:
%    \begin{macrocode}
\def\get@bibentry#1#2{\@ifundefined{reuse@#1@#2}{}
  {\@nameuse{reuse@#1@#2}}}
%    \end{macrocode}
% Create a new database which \pkg{icite} will use to connect
% Bib\LaTeX\ \enquote*{subtypes} to indices.
%    \begin{macrocode}
\DTLnewdb{icite@indices}
%    \end{macrocode}
% \DescribeMacro{\IndexSubtypeAs} \cs{IndexSubtypeAs} takes two
% mandatory arguments: 1. Any given keyword used to specify an
% \enquote*{entrysubtype} in the bibliographical database and 2. The
% index which the authors matching that subtype must go into. This
% command is to be found in the preamble only.
%    \begin{macrocode}
\NewDocumentCommand{\IndexSubtypeAs}{m m}{%
  \DTLnewrow{icite@indices}
  \DTLnewdbentry{icite@indices}{subtype}{#1}
  \DTLnewdbentry{icite@indices}{index}{#2}
}
\@onlypreamble\IndexSubtypeAs
%    \end{macrocode}
% \DescribeMacro{\SetTitleStyle} By default, titles are printed in
% italics. This can be changed in the preamble by \cs{SetTitleStyle}.
%    \begin{macrocode}
\NewDocumentCommand{\TitleStyle}{m}{\emph{#1}}
\NewDocumentCommand{\SetTitleStyle}{m}{%
  \RenewDocumentCommand{\TitleStyle}{m}{#1}
}
\@onlypreamble\SetTitleStyle
%    \end{macrocode}
% \DescribeMacro{\AuthorTitleDelim}
% \changes{v1.2}{2019/03/17}{\cs{AuthorTitleDelim}: delimiter
% between authors and titles}\cs{AuthorTitleDelim}\marg{delimiter}
% sets the delimiter between authors and titles in the body text when
% the |nobibengine| option is set to |true|. The default delimiter is
% a comma.
%    \begin{macrocode}
\def\ic@authtitdelim{, }
\NewDocumentCommand{\AuthorTitleDelim}{m}{%
  \def\ic@authtitdelim{#1}
}
\@onlypreamble\AuthorTitleDelim
%    \end{macrocode}
% \DescribeMacro{\TitlePageDelim}
% \changes{v1.2}{2019/03/17}{\cs{TitlePageDelim}: the delimiter
% between titles and pages}\cs{TitlePageDelim}\marg{delimiter} sets
% the delimiter between titles and pages in the body text when the
% |nobibengine| option is set to |true|. The default delimiter is a
% comma.
%    \begin{macrocode}
\def\ic@titpgdelim{, }
\NewDocumentCommand{\TitlePageDelim}{m}{%
  \def\ic@titpgdelim{#1}
}
\@onlypreamble\TitlePageDelim
%    \end{macrocode} 
% \DescribeMacro{\icite} \cs{icite} both inserts a formatted citation
% and an entry in the \emph{index locorum citatorum}. It is to be used
% in place of any \hologo{BibTeX} or Bib\LaTeX\ citation command the
% syntax of which is
% \cs{command}\oarg{pre}\oarg{post}\marg{key}. \cs{icite} further
% accepts an optional argument should one wish to specify the
% citation command to be used, like so:\\
% \cs{icite}\oarg{pre}\oarg{post}\marg{key}\oarg{command}\\
% Only standard citation commands are accepted, with the exception of
% qualified citation lists or so-called \enquote*{multicite}
% commands. As of v1.4, \pkg{icite} can process separate index entries
% from lists of numbers inserted in the \meta{postnote} argument of
% \cs{icite}. For this mechanism to work, the indexing commands used
% by \cs{icite} must be defined beforehand:---
%    \begin{macrocode}
\NewDocumentCommand{\icite@dflt@index}{m}{%
  \index[\ic@dfltind]{\@sortedauthor!\@sortedtitle!#1}}
\NewDocumentCommand{\icite@std@index}{m}{%
  \index[\icite@index]{\@sortedauthor!\@sortedtitle!#1}}
\NewDocumentCommand{\icite@nodflt@index}{m}{%
  \index{\@sortedauthor!\@sortedtitle!#1}}
%    \end{macrocode}
% Then \cs{process@index@list} is used to split the argument of
% |<postnote>| at each occurrence of the |;| punctuation mark:---
%    \begin{macrocode}
\NewDocumentCommand{\process@index@list}
                   {m > { \SplitList { ; } } m}{%
  \def\@tempa{#1}%
  \def\@dflt{dflt}%
  \def\@std{std}%
  \def\@nodflt{nodflt}%
  \ifx\@tempa\@dflt
    \ProcessList {#2} { \icite@dflt@index }%
  \else
  \ifx\@tempa\@std
    \ProcessList {#2} { \icite@std@index }%
  \else
  \ifx\@tempa\@nodflt
    \ProcessList {#2} { \icite@nodflt@index }%
  \fi\fi\fi
}
%    \end{macrocode}
% The definition of \cs{icite} follows:---
%    \begin{macrocode}
\NewDocumentCommand{\icite}{o o m O{\ic@dfltcit}}{%
  \edef\ic@argiv{#4}%
  \edef\ic@null{ic@nullcmd}%
  \ifno@bibengine\let\ic@argiv\ic@null\else\fi%
  \edef\@shorthand{\get@bibentry{#3}{shorthand}}%
  \edef\@subtype{\get@bibentry{#3}{entrysubtype}}%
  \edef\@author{\get@bibentry{#3}{author}}%
  \edef\@indexauthor{\get@bibentry{#3}{indexauthor}}%
  \edef\@sortname{\get@bibentry{#3}{sortname}}%
  \edef\@indexsorttitle{\get@bibentry{#3}{indexsorttitle}}%
  \edef\@indextitle{\get@bibentry{#3}{indextitle}}%
  \edef\@shorttitle{\get@bibentry{#3}{shorttitle}}%
  \edef\@title{\get@bibentry{#3}{title}}%
  \ifx\@indexauthor\empty
      \def\@useauthor{\@author}%
    \else
      \def\@useauthor{\@indexauthor}%
    \fi
  \ifx\@sortname\empty
      \def\@sortedauthor{\@useauthor}%
    \else
      \def\@sortedauthor{{\@sortname}@\@useauthor}%
    \fi
  \ifx\@indextitle\empty
    \ifx\@shorttitle\empty
      \def\@usetitle{\@title}%
    \else
      \def\@usetitle{\@shorttitle}%
    \fi
  \else
    \def\@usetitle{\@indextitle}%
  \fi
  \ifx\@indexsorttitle\empty
    \def\@sortedtitle{{\@usetitle}@\TitleStyle{\@usetitle}}%
  \else
    \def\@sortedtitle{{\@indexsorttitle}@\TitleStyle{\@usetitle}}%
  \fi
  \IfNoValueTF{#1}%
  {\DTLifdbempty{icite@indices}{%
      \ifno@index\else
      \ifdefault@index%
      \index[\ic@dfltind]{\@sortedauthor!\@sortedtitle}%
      \else%
      \index{\@sortedauthor!\@sortedtitle}%
      \fi\fi%
    }{%
      \bgroup%
      \DTLforeach*{icite@indices}{%
        \icite@subtype=subtype,\icite@index=index}{%
        \ifx\@subtype\icite@subtype%
        \index[\icite@index]{\@sortedauthor!\@sortedtitle}%
        \dtlbreak%
        \else%
        \ifno@index\else
        \ifdefault@index%
        \index[\ic@dfltind]{\@sortedauthor!\@sortedtitle}%
        \else%
        \index{\@sortedauthor!\@sortedtitle}%
        \fi\fi%
        \fi}%
      \egroup}%
    \ifno@bibengine
    \ifx\@shorthand\empty%
    \@useauthor\ic@authtitdelim\TitleStyle{\@usetitle}%
    \else%
    \@shorthand%
    \fi%
    \else%
    \fi%
    \csname\ic@argiv\endcsname{#3}%
  }
  {\IfNoValueTF{#2}%
    {\DTLifdbempty{icite@indices}{%
        \ifno@index\else
        \ifdefault@index%
        \process@index@list{dflt}{#1}%
        %\index[\ic@dfltind]{\@sortedauthor!\@sortedtitle!#1}%
        \else%
        \process@index@list{nodflt}{#1}%
        %\index{\@sortedauthor!\@sortedtitle!#1}%
        \fi\fi%
      }{%
        \bgroup%
        \DTLforeach*{icite@indices}{%
          \icite@subtype=subtype,\icite@index=index}{%
          \ifx\@subtype\icite@subtype%
          \process@index@list{std}{#1}%
          %\index[\icite@index]{\@sortedauthor!\@sortedtitle!#1}%
          \dtlbreak%
          \else%
          \ifno@index\else
          \ifdefault@index%
          \process@index@list{dflt}{#1}%
          %\index[\ic@dfltind]{\@sortedauthor!\@sortedtitle!#1}%
          \else%
          \process@index@list{nodflt}{#1}%
          %\index{\@sortedauthor!\@sortedtitle!#1}%
          \fi\fi%
          \fi}%
        \egroup}%
      \ifno@bibengine
      \ifx\@shorthand\empty%
      \@useauthor\ic@authtitdelim\TitleStyle{\@usetitle}%
         \ic@titpgdelim{#1}%
      \else%
      \@shorthand\ic@titpgdelim{#1}%
      \fi%
      \else%
      \fi%
      \csname\ic@argiv\endcsname[{#1}]{#3}%
    }
    {\DTLifdbempty{icite@indices}{%
        \ifno@index\else
        \ifdefault@index%
        \process@index@list{dflt}{#2}%
        %\index[\ic@dfltind]{\@sortedauthor!\@sortedtitle!#2}%
        \else%
        \process@index@list{nodflt}{#2}%
        %\index{\@sortedauthor!\@sortedtitle!#2}%
        \fi\fi%
      }{%
        \bgroup%
        \DTLforeach*{icite@indices}{%
          \icite@subtype=subtype,\icite@index=index}{%
          \ifx\@subtype\icite@subtype%
          \process@index@list{std}{#2}%
          %\index[\icite@index]{\@sortedauthor!\@sortedtitle!#2}%
          \dtlbreak%
          \else%
          \ifno@index\else
          \ifdefault@index%
          \process@index@list{dflt}{#2}%
          %\index[\ic@dfltind]{\@sortedauthor!\@sortedtitle!#2}%
          \else%
          \process@index@list{nodflt}{#2}%
          %\index{\@sortedauthor!\@sortedtitle!#2}%
          \fi\fi%
          \fi}%
        \egroup}%
      \ifno@bibengine
      \ifx\@shorthand\empty%
      #1 \@useauthor\ic@authtitdelim\TitleStyle{\@usetitle}%
         \ic@titpgdelim{#2}%
      \else%
      #1 \@shorthand\ic@titpgdelim{#2}%
      \fi
      \else%
      \fi%
      \csname\ic@argiv\endcsname[#1][{#2}]{#3}%
    }%
  }%
}
%    \end{macrocode}
% \iffalse
%</package>
% \fi
%\Finale
\endinput