summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/testidx/testidx.dtx
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/source/latex/testidx/testidx.dtx')
-rw-r--r--Master/texmf-dist/source/latex/testidx/testidx.dtx80
1 files changed, 62 insertions, 18 deletions
diff --git a/Master/texmf-dist/source/latex/testidx/testidx.dtx b/Master/texmf-dist/source/latex/testidx/testidx.dtx
index 39a48ed9fee..8b743807cec 100644
--- a/Master/texmf-dist/source/latex/testidx/testidx.dtx
+++ b/Master/texmf-dist/source/latex/testidx/testidx.dtx
@@ -1,17 +1,17 @@
%\iffalse
% testidx.dtx generated using makedtx version 1.2 (c) Nicola Talbot
% Command line args:
-% -author "Nicola Talbot"
-% -doc "testidx-codedoc.tex"
-% -setambles ".*\.bib=>\nopreamble\nopostamble"
-% -codetitle "Main Package Code"
% -src "(testidx.sty)\Z=>\1"
% -src "(testidx-.*.sty)\Z=>\1"
% -src "(testidx-glossaries.*\.tex)\Z=>\1"
% -src "(testidx-glossaries.*\.bib)\Z=>\1"
+% -setambles ".*\.bib=>\nopreamble\nopostamble"
+% -doc "testidx-codedoc.tex"
+% -codetitle "Main Package Code"
+% -author "Nicola Talbot"
% -macrocode ".*\.bib"
% testidx
-% Created on 2017/8/11 12:58
+% Created on 2019/9/29 13:53
%\fi
%\iffalse
%<*package>
@@ -34,7 +34,7 @@
%\fi
% \iffalse
% Doc-Source file to use with LaTeX2e
-% Copyright (C) 2017 Nicola Talbot, all rights reserved.
+% Copyright (C) 2019 Nicola Talbot, all rights reserved.
% \fi
% \iffalse
%<*driver>
@@ -45,6 +45,7 @@ testidx-codedoc.tex is a stub file used by makedtx to create
testidx.dtx
\fi
+\usepackage{metalogo}
\usepackage{fontspec}
\setromanfont{FreeSerif}
\setsansfont{FreeSans}[Scale=MatchLowercase]
@@ -61,7 +62,7 @@ testidx.dtx
\setcounter{IndexColumns}{2}
-\CheckSum{10076}
+\CheckSum{10168}
\begin{document}
\DocInput{testidx.dtx}
@@ -71,12 +72,12 @@ testidx.dtx
%\MakeShortVerb{"}
%\DeleteShortVerb{\|}
%
-% \title{Documented Code For testidx v1.1}
+% \title{Documented Code For testidx v1.2}
% \author{Nicola L.C. Talbot\\[10pt]
%Dickimaw Books\\
%\url{http://www.dickimaw-books.com/}}
%
-% \date{2017-08-11}
+% \date{2019-09-29}
% \maketitle
%
%\tableofcontents
@@ -106,7 +107,7 @@ testidx.dtx
%\section{Initialisation}
% \begin{macrocode}
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{testidx}[2017/08/11 v1.1 (NLCT)]
+\ProvidesPackage{testidx}[2019/09/29 v1.2 (NLCT)]
% \end{macrocode}
%To avoid as much conflict as possible, this package loads the
%bare minimum, so I'm not using useful packages like \styfmt{etoolbox} or
@@ -135,9 +136,10 @@ testidx.dtx
}
% \end{macrocode}
%\end{macro}
-%\begin{macro}{\@tstidx@ifutfviii}
+%\begin{macro}{\@@tstidx@ifutfviii}
+%\changes{1.2}{2019-09-29}{renamed from \cs{@tstidx@ifutfviii}}
% \begin{macrocode}
-\newcommand*{\@tstidx@ifutfviii}[2]{%
+\newcommand*{\@@tstidx@ifutfviii}[2]{%
\@tstidx@ifxelua{#1}
{%
\ifx\inputencodingname\@tstidx@utfviii#1\else#2\fi
@@ -146,6 +148,23 @@ testidx.dtx
\newcommand*{\@tstidx@utfviii}{utf8}
% \end{macrocode}
%\end{macro}
+%\begin{macro}{\@tstidx@ifutfviii}
+%\changes{1.2}{2019-09-29}{now let to \cs{@@tstidx@ifutfviii}}
+% \begin{macrocode}
+\let\@tstidx@ifutfviii\@@tstidx@ifutfviii
+% \end{macrocode}
+%\end{macro}
+%As from 2018, \LaTeX\ now automatically enables UTF-8 support, so provide
+%an option to use only ASCII in the test:
+%\changes{1.2}{2019-09-29}{added ascii and noascii options}
+% \begin{macrocode}
+\DeclareOption{ascii}{\let\@tstidx@ifutfviii\@secondoftwo}
+% \end{macrocode}
+%Provide option to counteract this (if document doesn't support
+%UTF-8 this won't make a difference):
+% \begin{macrocode}
+\DeclareOption{noascii}{\let\@tstidx@ifutfviii\@@tstidx@ifutfviii}
+% \end{macrocode}
%
%\begin{macro}{\tstidxprocessasciisort}
%The first argument is a control sequence in which to store the
@@ -301,6 +320,12 @@ testidx.dtx
}
% \end{macrocode}
%\end{macro}
+%Note that as from LaTeX 2019/10/01, UTF-8 characters no longer
+%expand as they are written to the indexing file. This means that
+%there won't be a difference if the sanitizing is on or off.
+%Similarly there's no difference with \XeLaTeX\ and \LuaLaTeX\ since
+%they natively support UTF-8 and don't make extended characters
+%active anyway.
%
%\begin{macro}{\iftestidxdiglyphs}
%\changes{1.1}{2017-08-11}{new}
@@ -3702,6 +3727,7 @@ testidx.dtx
%\end{macro}
%
%\begin{macro}{\@tidx@par@iii}
+%\changes{1.2}{2019-09-29}{added lonely sub-item}
% \begin{macrocode}
\tstidxnewblock
{%
@@ -3812,7 +3838,8 @@ testidx.dtx
any further sub-levels. Although \tstidxapp{xindy} allows more than
three levels (\tstidxapp{makeindex} doesn't), it's somewhat
\tstidxword{excessive} to go below a sub-sub-level.
- You'll have to add your own tests for anything deeper.%
+ You'll have to add your own tests for anything deeper.
+ Watch out for \tstidxsubword{sub-items}{lonely} sub-items.%
}
% \end{macrocode}
%\end{macro}
@@ -4676,7 +4703,7 @@ and then we can take a \tstidxword{ffotograff} of
%and then used in the dummy text.
% \begin{macrocode}
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{testidx-glossaries}[2017/08/11 v1.1 (NLCT)]
+\ProvidesPackage{testidx-glossaries}[2019/09/29 v1.2 (NLCT)]
% \end{macrocode}
%
%\begin{macro}{\tstidx@glossariespkg}
@@ -7728,9 +7755,10 @@ use the
any further sub-levels. Although \tstidxapp{xindy} allows more than
three levels (\tstidxapp{makeindex} doesn't), it's somewhat
\tstidxword{excessive} to go below a sub-sub-level.
- You'll have to add your own tests for anything deeper.%
-
+ You'll have to add your own tests for anything deeper.
+ Watch out for \tstidxsubword{sub-items}{lonely} sub-items.%
}
+
\let\@tidx@org@par@iii\@tidx@par@iii
\let\@tidx@par@iii\@tidx@gls@par@iii
% \end{macrocode}
@@ -8059,6 +8087,7 @@ design or provide new commands}
\tstidxnewword{people}{human individuals (or fictional
anthropomorphisms)}
\tstidxnewword{places}{particular areas or locations}
+\tstidxnewword{sub-items}{items that have a parent entry}
\tstidxnewword{applications}{computer programs}
\tstidxnewword{environments}{a marked-up block within the document
that requires special action or formatting}
@@ -8257,7 +8286,7 @@ something}
\tstidxnewword{thrilling}{exciting}
\tstidxnewword{quixotic}{impractically unselfish and idealist}
\tstidxnewword{sea}{large area of salt water}
-\tstidxnewword{seal}{seal-dwelling fish-eating mammal with flippers}
+\tstidxnewword{seal}{sea-dwelling fish-eating mammal with flippers}
\tstidxnewword{seaborne}{transported or travelling by sea}
\tstidxnewword{zither}{a type of stringed musical instrument}
\tstidxnewword{zealous}{having great enthusiasm for something}
@@ -8566,6 +8595,8 @@ story, especially fairy tales}
% \end{macrocode}
%Sub-entries (terms).
% \begin{macrocode}
+\tstidxnewsubword{sub-items}{lonely}{a sub-item that doesn't have
+any siblings}
\tstidxnewsubword{document}{properties}{attributes such as page size}
\tstidxnewsubword{font encoding}{OT1}{one of the original font
encodings supplied with \TeX}
@@ -10512,6 +10543,12 @@ some other languages}
description={particular areas or locations}
}
+@index{subitems,
+ category={word},
+ name={sub-items},
+ description={items that have a parent entry}
+}
+
@index{applications,
category={word},
description={computer programs}
@@ -11362,7 +11399,7 @@ something}
@index{seal,
category={word},
- description={seal-dwelling fish-eating mammal with flippers}
+ description={sea-dwelling fish-eating mammal with flippers}
}
@index{sea,
@@ -11591,6 +11628,13 @@ the sovereign}
description={attributes such as page size}
}
+@index{subitems.lonely,
+ name={lonely},
+ parent={subitems},
+ category={word},
+ description={a sub-item that doesn't have any siblings}
+}
+
@index{fontencoding.OT1,
name={OT1},
parent={fontencoding},