From 7ae99d0695886654063166819b1ee151f3e6d795 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Sat, 12 Feb 2022 21:17:31 +0000 Subject: knowledge (12feb22) git-svn-id: svn://tug.org/texlive/trunk@61991 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf-dist/doc/latex/knowledge/README.md | 4 +- .../texmf-dist/doc/latex/knowledge/knowledge.pdf | Bin 770976 -> 771140 bytes .../texmf-dist/doc/latex/knowledge/knowledge.tex | 40 +++++------ .../source/latex/knowledge/knowledge-code.dtx | 79 ++++++++++++++++----- .../texmf-dist/tex/latex/knowledge/knowledge.sty | 46 +++++++++--- 5 files changed, 118 insertions(+), 51 deletions(-) diff --git a/Master/texmf-dist/doc/latex/knowledge/README.md b/Master/texmf-dist/doc/latex/knowledge/README.md index 93d3a6adb0c..07b55368a00 100644 --- a/Master/texmf-dist/doc/latex/knowledge/README.md +++ b/Master/texmf-dist/doc/latex/knowledge/README.md @@ -3,8 +3,8 @@ This directory contains the package name: knowledge license: LaTeX Project Public License version 1.2 or above - version: v1.27 - date: 2022/01/12 + version: v1.28 + date: 2022/02/12 author: Thomas Colcombet mail: thomas.colcombet@irif.fr web: https://ctan.org/pkg/knowledge diff --git a/Master/texmf-dist/doc/latex/knowledge/knowledge.pdf b/Master/texmf-dist/doc/latex/knowledge/knowledge.pdf index 124bdf88cad..2e7e53daac5 100644 Binary files a/Master/texmf-dist/doc/latex/knowledge/knowledge.pdf and b/Master/texmf-dist/doc/latex/knowledge/knowledge.pdf differ diff --git a/Master/texmf-dist/doc/latex/knowledge/knowledge.tex b/Master/texmf-dist/doc/latex/knowledge/knowledge.tex index aca0ea97dd9..a821315e1b6 100644 --- a/Master/texmf-dist/doc/latex/knowledge/knowledge.tex +++ b/Master/texmf-dist/doc/latex/knowledge/knowledge.tex @@ -13,6 +13,8 @@ \GetFileInfo{knowledge.sty} \edef\knowledgeversiondate{\fileversion--\filedate} +\knowledgeconfigure{diagnose line=true} + % Depending on whether the file is included from knowledge-code.dtx % or not, some configuration changes. % This involves mainly the presence of the code. @@ -333,6 +335,7 @@ \knowledge{index key=}{directive} \knowledge{index parent key=}{directive} \knowledge{index style=}{directive} +\knowledge{index name=}{directive} \knowledge{label scope}[label scope=]{option} \knowledge{color=}{directive} \knowledge{cyclic color}{directive} @@ -359,9 +362,12 @@ \knowledge{quotation}[quotation=]{option} \knowledge{notion}{option} \knowledge{cyclic colors=}{option} + \knowledge{imakeidx}{option} \end{scope} + \knowledge{hyperref option}{link=hyperref,link scope=option} \knowledge{makeidx option}{link=makeidx,link scope=option} +\knowledge{imakeidx option}{link=imakeidx,link scope=option} \knowledge{cleveref option}{link=cleveref,link scope=option} \knowledge{scope option}{link=scope,link scope=option} \knowledge{xcolor option}{link=xcolor,link scope=option} @@ -409,6 +415,7 @@ \knowledge{standalone}{package,url={https://www.ctan.org/pkg/standalone}} \knowledge{xcolor}{package,url={https://www.ctan.org/pkg/xcolor}} \knowledge{makeidx}{package,url={https://www.ctan.org/pkg/makeidx}} + \knowledge{imakeidx}{package,url={https://www.ctan.org/pkg/imakeidx}} \knowledge{cleveref}{package,url={https://www.ctan.org/pkg/cleveref}} \knowledge{etoolbox}{package,url={https://www.ctan.org/pkg/etoolbox}} \knowledge{xparse}{package,url={https://www.ctan.org/pkg/xparse}} @@ -753,7 +760,7 @@ I have seen Till Tantau who explained me how to test whether a material is displ \item[2018-02-24] Documentation improvement for the environment "thebibliography@@env". \item[2018-05-17] Correction to be compatible with the latest version of "expl3@@package" (thanks to Leo Stefanesco). \item[2018-07-26] Compatibility with utf8 symbols in labels (thanks to Yves Guiraud). -\item[2018-11-22] Corrected bug for "makeidx@@package" (thanks to Sylvain Schmitz). V1.14 on "CTAN". +\item[2018-11-22] Corrected bug for "makeidx@@option" (thanks to Sylvain Schmitz). V1.14 on "CTAN". \item[2019-01-27] Minor improvement of the doc, and hiding links in it. V1.15. \item[2019-02-15] Correction of a placement problem with \cs\AP. V1.16. \item[2019-05-23] Adding of the "`\vbar'-notation" for the \cs{\knowledge} command. @@ -772,13 +779,14 @@ I have seen Till Tantau who explained me how to test whether a material is displ \item[2020-05-02] Doc update ("acmart@@package" colors, thanks to Daniela Petri\c san). \item[2020-09-22] Adding the "silent" option as suggested by Patrick Lambein-Monette. V1.24. \item[2021-03-31] Correcting a bug caused by a change of semantics in "expl3@@package". V1.25. -\item[2021-05-25] Added the \cs\kref, \cs\kpageref, \cs\kcref, and \cs\kCref\ commands a suggested by Ziv Scully. +\item[2021-05-25] Added the \cs\kref, \cs\kpageref, \cs\kcref, and \cs\kCref\ commands as suggested by Ziv Scully. \item[2021-05-26] Corrected wrongly used default parameter in \cs\knowledgedirective. \item[2021-05-27] The explicit text given in a \cs\kl-command now overrides the "text=" directive. \item[2021-07-18] Adding the "no index" directive. \item[2021-12-20] Adding options "anchor point shape", "anchor point color", "anchor point shift" (request of Rémi Morvan). \item[2021-12-27] Bug correction for corner shape, and doc update (thanks to Rémi Morvan). \item[2022-01-12] Minor changes. Removing dead link for the webpage. V1.27 +\item[2022-02-12] Adding support of "imakeidx@@package" and the directive "index name=" (request and code change by Maximilian Keßler). V1.28 \end{compactdesc} \normalsize %\restoregeometry @@ -1142,17 +1150,6 @@ The use of "variants of \cs{\kl}" is also useful for typesetting mathematics. I \section{Usage of the \kl(package){knowledge} package} \label{section:doc} -\iffalse -We shall now give a more complete description of the functionalities of the "knwoeldge@@package". -\ref{subsection:loading packages} -\ref{subsection:knowledge command} -\ref{subsection:kl command} -\ref{subsection:diagnose file} -\ref{subsection:hyperref package} -\ref{subsection:xcolor package} -\ref{subsection:makeidx package} -\fi - \subsection{Options and configuration} \label{subsection:loading packages} @@ -1167,7 +1164,7 @@ The options that can be used in the optional parameter of \cs{\usepackage} when \begin{compactdesc} \itemAP[Writing mode] The "paper", "electronic" or "composition" modes are possible ("composition" is by default) (see Section~\ref{subsubsection:writing modes} for more details). These modes change several rendering settings. -\itemAP[Other packages] some of the options concern the loading and the use of other packages (\kl(package){hyperref}, \kl(package){xcolor}, \kl (package){makeidx}, \dots). Note that these package can also be loaded before "knowledge@@package". This is explained in Section~\ref{subsubsection:packages-loading}. +\itemAP[Other packages] some of the options concern the loading and the use of other packages (\kl(package){hyperref}, \kl(package){xcolor}, \kl (package){makeidx}, \kl (package){imakeidx}, \kl (package){cleveref}, \dots). Note that these package can also be loaded before "knowledge@@package". This is explained in Section~\ref{subsubsection:packages-loading}. \itemAP[Configuration options] as used by the command \cs{\knowledgeconfigure} can be used when loading the package. \itemAP[Scoping] The \kl[scope option]{scope} "option@package option" makes the package aware at a fine level of the structure of the document (see Section~\ref{subsection:scoping} for explanations). This provides, for instance, the possibility to define pieces of "knowledge" that are attached to a sections of the document. \itemAP[Other] The "no patch" option prevents the "knowledge@@package" to apply some patches that are convenient by default. @@ -1220,7 +1217,7 @@ The following primitives are available to the user for "writing mode"-sensitive \label{subsubsection:packages-loading} A certain number of "package options" coincide with the loading of other packages. For the moment, the packages that are concerned are \kl(option){hyperref}, -\kl(option){xcolor}, and \kl(option){makeidx}. +\kl(option){xcolor}, \kl(option){makeidx}, and "imakeidx@@option". For activating these functionalities, it is sufficient, either to load the package \emph{before} the "knowledge@@package" package, or to name it explicitly as an "option@package option" for "knowledge@@package". Loading separately the package is convenient for setting options for it. For instance, @@ -1250,7 +1247,7 @@ Currently, the packages that can be loaded are: \begin{description} \itemAP[\kl(package){hyperref}] which activates all the (auto)referencing capabilities. \item[\kl(package){xcolor}] which activates coloring commands. -\item[\kl(package){makeidx}] for handling the index automatically. +\item[\kl(package){makeidx} and "imakeidx@@package"] for handling the index automatically. \end{description} \subsubsection{Configuring and \cs{\knowledgeconfigure}} @@ -1385,7 +1382,7 @@ A certain number of Boolean directives are available without any options. These (that leaves it in the default state, or the one determined by surrounding knowledges). The general boolean \kl[\knowledge directives]{directives} are the following: \begin{description} -\itemAP[\kl{autoref}] activates the ability to introduce once, use several times an instance. This is often used for defining links inside a document (see the "hyperref@@option" in \kCref*"hyperref@@option"). This can also be used for constructing the index (see the "makeidx@@option" in \kCref*"makeidx@@option"). It can simply be used for referencing the number of the environment or the proper page of introduction (see \cs\kref\ and \cs\kpageref\ commands and their more powerful "cleveref@@option" in \kCref*"cleveref@@option"). +\itemAP[\kl{autoref}] activates the ability to introduce once, use several times an instance. This is often used for defining links inside a document (see the "hyperref@@option" in \kCref*"hyperref@@option"). This can also be used for constructing the index (see the "makeidx@@option" and in "imakeidx@@option"\kCref*"makeidx@@option"). It can simply be used for referencing the number of the environment or the proper page of introduction (see \cs\kref\ and \cs\kpageref\ commands and their more powerful "cleveref@@option" in \kCref*"cleveref@@option"). \itemAP[\kl{autorefhere}] puts immediately a label at the location of the definition, and makes all \cs{\kl} occurrences of this \kl{knowledge} hyperlink to this location. \itemAP[\intro{emphasize}] forces the text to be emphasized using `\cs{\emph}', @@ -2405,16 +2402,17 @@ Finally, the "anchor points" reference point can be shifted, using: in which $x$ and $y$ are by default in unit \texttt{em} (note the use of curly braces and of no parenthesis, which is mandatory). -\subsubsection{The \kl{makeidx option}} +\subsubsection{The \kl(option){makeidx} and \kl(option){imakeidx} options} \label{subsection:makeidx option} -\subsubsubsection{Activating the \kl{makeidx option}} +\subsubsubsection{Activating the \kl(option){makeidx} and \kl(option){makeidx} options} -The \intro{makeidx option} loads the \intro(package){makeidx} package and triggers a certain number of link-related features. This is done either by the command: +The \intro{makeidx option} loads the \kl(package){imakeidx} package and triggers a certain number of link-related features. This is done either by the command: \begin{center} \smallcode{\cs{\usepackage}[\kl(option){makeidx}]\{\kl(package){knowledge}\}} \end{center}\noindent or by loading the \kl(package){makeidx} before the "knowledge@@package" package. +The same goes for the \intro{imakeidx option}. \subsubsubsection{Features} @@ -2428,6 +2426,7 @@ The following \kl[\knowledge directives]{directives} are to be used: \begin{code}[8cm] \cs\def\cs\knowledgeIntroIndexStyle\#1\{\cs\fbox\{\#1\}\} \end{code} +\itemAP[\intro{index name=}] requires to activate "imakeidx@@option", and allows to choose the index name in case of multiple indexes. \end{description} \AP The "directive" ""no index"", deactivates the index feature for a knowledge. This is meant to be used in a "style". @@ -3101,6 +3100,7 @@ If other kind of problems occur, report them to \texttt{thomas.colcombet@irif.fr %\item[\kl{import=}] (\kl{not implemented}) \item[\kl{index=}] Chooses the text to be displayed in the \kl{index=}. \item[\kl{index key=}] the key used to choose the place in the \kl{index}. +\item[\kl{index name=}] the name of the \kl{index} (requires "imakeidx@@option"). \item[\kl{index style=}] the \kl{style} to be used to display in the \kl{index}. \item[\kl{index parent key=}] the parent key in the \kl{index}. \item[\kl{intro style=}] Chooses the typesetting in case of an intro. diff --git a/Master/texmf-dist/source/latex/knowledge/knowledge-code.dtx b/Master/texmf-dist/source/latex/knowledge/knowledge-code.dtx index 0f66f049d19..2f6a4f0a129 100644 --- a/Master/texmf-dist/source/latex/knowledge/knowledge-code.dtx +++ b/Master/texmf-dist/source/latex/knowledge/knowledge-code.dtx @@ -23,7 +23,7 @@ % % \iffalse %\usepackage{expl3} -%\ProvidesExplPackage{knowledge}{2022/01/12}{1.27}{} +%\ProvidesExplPackage{knowledge}{2022/02/12}{1.28}{} %<*driver> \def\knowledgecode{active} \input{knowledge.tex} @@ -60,6 +60,7 @@ % \changes{1.25}{2021/03/31}{bug correction} % % \changes{1.26}{2021/12/20}{enhanced math+other functionalities+extra options} % % \changes{1.27}{2022/01/12}{doc changes} % +% \changes{1.28}{2022/02/12}{imakeidx support} % % \GetFileInfo{knowledge.sty} % % \DoNotIndex{} % @@ -79,8 +80,8 @@ This directory contains the package name: knowledge license: LaTeX Project Public License version 1.2 or above - version: v1.27 - date: 2022/01/12 + version: v1.28 + date: 2022/02/12 author: Thomas Colcombet mail: thomas.colcombet@irif.fr web: https://ctan.org/pkg/knowledge @@ -620,9 +621,16 @@ This directory contains the package % % \subsubsection{External package options} % -%\csintro{\knowledge_xcolor_active_bool}, \csintro{\knowledge_xcolor_syntax_bool}, -%\csintro{\knowledge_hyperref_active_bool}, \csintro{\knowledge_hyperref_syntax_bool}, -%\csintro{\knowledge_makeidx_active_bool}, \csintro{\knowledge_makeidx_syntax_bool} +%\csintro{\knowledge_xcolor_active_bool}, +% \csintro{\knowledge_xcolor_syntax_bool}, +%\csintro{\knowledge_hyperref_active_bool}, +%\csintro{\knowledge_hyperref_syntax_bool}, +%\csintro{\knowledge_makeidx_active_bool}, +%\csintro{\knowledge_makeidx_syntax_bool}, +%\csintro{\knowledge_imakeidx_active_bool}, +%\csintro{\knowledge_imakeidx_syntax_bool}. +% +% % % First, one tests the package available. % \csintro{\package_if_loaded:nTF} tests if a package is loaded. @@ -645,6 +653,7 @@ This directory contains the package \knowledge_option_aci_test_loaded:n{hyperref} \knowledge_option_aci_test_loaded:n{xcolor} \knowledge_option_aci_test_loaded:n{makeidx} +\knowledge_option_aci_test_loaded:n{imakeidx} \knowledge_option_aci_test_loaded:n{cleveref} % \end{macrocode} %\begin{quote}\tt @@ -690,6 +699,7 @@ This directory contains the package \knowledge_option_aci_define:n{hyperref} \knowledge_option_aci_define:n{xcolor} \knowledge_option_aci_define:n{makeidx} +\knowledge_option_aci_define:n{imakeidx} \knowledge_option_aci_define:n{cleveref} % \end{macrocode} % @@ -762,6 +772,7 @@ This directory contains the package \knowledge_option_aci_autoload:nnn{ hyperref }{}{} \knowledge_option_aci_autoload:nn{ xcolor }{} \knowledge_option_aci_autoload:nn{ makeidx }{} +\knowledge_option_aci_autoload:nn{ imakeidx }{} \knowledge_option_aci_autoload:nn{ cleveref }{} % \end{macrocode} % @@ -3988,7 +3999,7 @@ This directory contains the package % \end{macrocode} % % -% \subsubsection{The \kl{makeidx option}} +% \subsubsection{The \kl{makeidx option} and \kl{imakeidx} options} % % \begin{macrocode} %\bool_if:NT\knowledge_makeidx_active_bool{ @@ -4008,18 +4019,36 @@ This directory contains the package % }}}} %} % \end{macrocode} +% Since "imakeidx@@package" extends the syntax of "makeidx@@package", +% internally, activating the package or the syntax for "imakeidx@@package" +% does the same thing for "makeidx@@package". +% \begin{macrocode} +\bool_if:NT\knowledge_imakeidx_active_bool{\bool_set_true:N\knowledge_makeidx_active_bool} +\bool_if:NT\knowledge_imakeidx_syntax_bool{\bool_set_true:N\knowledge_makeidx_syntax_bool} +% \end{macrocode} +% The index option has to variant, depending on whether the name of the index is used or not. % \begin{macrocode} +\cs_new:Npn \knowledge_index:nn #1 #2{ + \tl_if_empty:nTF {#1} + {\index{#2}} + {\index[{#1}]{#2}} + } + +\cs_generate_variant:Nn \knowledge_index:nn {xx} + \cs_new:Nn\knowledge_kl_compute_code_makeidx:{ \bool_if:NF\knowledge_kl_noindex_bool{ \tl_if_exist_ne:NTF\knowledge_kl_index_tl - {\exp_args:Nx\index - {\tl_if_exist_ne:NTF\knowledge_kl_index_parent_key_tl - {\exp_not:V\knowledge_kl_index_parent_key_tl!}{} - \tl_if_exist_ne:NTF\knowledge_kl_index_key_tl - {\exp_not:V\knowledge_kl_index_key_tl@}{} + {\knowledge_index:xx + {\tl_if_exist_ne:NTF \knowledge_kl_index_name_tl + {\exp_not:V \knowledge_kl_index_name_tl}{}} + {\tl_if_exist_ne:NTF\knowledge_kl_index_parent_key_tl + {\exp_not:V\knowledge_kl_index_parent_key_tl!}{} + \tl_if_exist_ne:NTF\knowledge_kl_index_key_tl + {\exp_not:V\knowledge_kl_index_key_tl@}{} \expandafter\tl_to_str:n\expandafter{\knowledge_kl_index_tl} \tl_if_exist_ne:NTF\knowledge_kl_index_number_style_tl - {|\exp_not:V\knowledge_kl_index_number_style_tl}{} + {|\exp_not:V\knowledge_kl_index_number_style_tl}{} }}{} } } @@ -4034,12 +4063,26 @@ This directory contains the package {\knowledge_delay_directive:n{index={#1}}}}, index .default:n = {} } - -\NewKnowledgeParamTl*[\knowledge_kl_index_number_style_tl]{index~style} -\NewKnowledgeParamTl*[\knowledge_kl_index_parent_key_tl]{index~parent~key} -\NewKnowledgeParamTl*[\knowledge_kl_index_key_tl]{index~key} -\NewKnowledgeParamBool*{no~index}\knowledge_kl_noindex_bool + +\bool_if:NT\knowledge_makeidx_syntax_bool +{ \NewKnowledgeParamTl*[\knowledge_kl_index_number_style_tl]{index~style} + \NewKnowledgeParamTl*[\knowledge_kl_index_parent_key_tl]{index~parent~key} + \NewKnowledgeParamTl*[\knowledge_kl_index_key_tl]{index~key} + \NewKnowledgeParamBool*{no~index}\knowledge_kl_noindex_bool +} +\bool_if:NT\knowledge_imakeidx_syntax_bool { + \NewKnowledgeParamTl*[\knowledge_kl_index_name_tl]{index~name} +} % \end{macrocode} +% Activating error message is packages not loaded. +% \begin{macrocode} +\knowledge_directives_require_aci_package:nn + {index,index~key,index~parent~key,index~style}{makeidx} +\knowledge_directives_require_aci_package:nn + {index~name}{imakeidx} +% \end{macrocode} +% +% % % \subsubsection{The \kl{cleveref option}} % diff --git a/Master/texmf-dist/tex/latex/knowledge/knowledge.sty b/Master/texmf-dist/tex/latex/knowledge/knowledge.sty index 507ab282514..875271f7379 100644 --- a/Master/texmf-dist/tex/latex/knowledge/knowledge.sty +++ b/Master/texmf-dist/tex/latex/knowledge/knowledge.sty @@ -23,7 +23,7 @@ %% LaTeX version 1999/12/01 or later. %% \usepackage{expl3} -\ProvidesExplPackage{knowledge}{2022/01/12}{1.27}{} +\ProvidesExplPackage{knowledge}{2022/02/12}{1.28}{} %%%%%%%%%% \RequirePackage{l3keys2e} \RequirePackage{etoolbox} @@ -1104,6 +1104,7 @@ \knowledge_option_aci_test_loaded:n{hyperref} \knowledge_option_aci_test_loaded:n{xcolor} \knowledge_option_aci_test_loaded:n{makeidx} +\knowledge_option_aci_test_loaded:n{imakeidx} \knowledge_option_aci_test_loaded:n{cleveref} \cs_new:Nn\knowledge_option_aci_define:n{ \keys_define:nn{ knowledge~package~options } { @@ -1131,6 +1132,7 @@ \knowledge_option_aci_define:n{hyperref} \knowledge_option_aci_define:n{xcolor} \knowledge_option_aci_define:n{makeidx} +\knowledge_option_aci_define:n{imakeidx} \knowledge_option_aci_define:n{cleveref} \ProcessKeysOptions{knowledge~package~options} @@ -1179,6 +1181,7 @@ \knowledge_option_aci_autoload:nnn{ hyperref }{}{} \knowledge_option_aci_autoload:nn{ xcolor }{} \knowledge_option_aci_autoload:nn{ makeidx }{} +\knowledge_option_aci_autoload:nn{ imakeidx }{} \knowledge_option_aci_autoload:nn{ cleveref }{} \tl_const:Nn\scope_tl{SC@PE} \tl_const:Nn\scopept_tl{SC@PE2} @@ -3344,17 +3347,29 @@ \let\klTKS\knowledge_fake_klTKS } } +\bool_if:NT\knowledge_imakeidx_active_bool{\bool_set_true:N\knowledge_makeidx_active_bool} +\bool_if:NT\knowledge_imakeidx_syntax_bool{\bool_set_true:N\knowledge_makeidx_syntax_bool} +\cs_new:Npn \knowledge_index:nn #1 #2{ + \tl_if_empty:nTF {#1} + {\index{#2}} + {\index[{#1}]{#2}} + } + +\cs_generate_variant:Nn \knowledge_index:nn {xx} + \cs_new:Nn\knowledge_kl_compute_code_makeidx:{ \bool_if:NF\knowledge_kl_noindex_bool{ \tl_if_exist_ne:NTF\knowledge_kl_index_tl - {\exp_args:Nx\index - {\tl_if_exist_ne:NTF\knowledge_kl_index_parent_key_tl - {\exp_not:V\knowledge_kl_index_parent_key_tl!}{} - \tl_if_exist_ne:NTF\knowledge_kl_index_key_tl - {\exp_not:V\knowledge_kl_index_key_tl@}{} + {\knowledge_index:xx + {\tl_if_exist_ne:NTF \knowledge_kl_index_name_tl + {\exp_not:V \knowledge_kl_index_name_tl}{}} + {\tl_if_exist_ne:NTF\knowledge_kl_index_parent_key_tl + {\exp_not:V\knowledge_kl_index_parent_key_tl!}{} + \tl_if_exist_ne:NTF\knowledge_kl_index_key_tl + {\exp_not:V\knowledge_kl_index_key_tl@}{} \expandafter\tl_to_str:n\expandafter{\knowledge_kl_index_tl} \tl_if_exist_ne:NTF\knowledge_kl_index_number_style_tl - {|\exp_not:V\knowledge_kl_index_number_style_tl}{} + {|\exp_not:V\knowledge_kl_index_number_style_tl}{} }}{} } } @@ -3368,10 +3383,19 @@ index .default:n = {} } -\NewKnowledgeParamTl*[\knowledge_kl_index_number_style_tl]{index~style} -\NewKnowledgeParamTl*[\knowledge_kl_index_parent_key_tl]{index~parent~key} -\NewKnowledgeParamTl*[\knowledge_kl_index_key_tl]{index~key} -\NewKnowledgeParamBool*{no~index}\knowledge_kl_noindex_bool +\bool_if:NT\knowledge_makeidx_syntax_bool +{ \NewKnowledgeParamTl*[\knowledge_kl_index_number_style_tl]{index~style} + \NewKnowledgeParamTl*[\knowledge_kl_index_parent_key_tl]{index~parent~key} + \NewKnowledgeParamTl*[\knowledge_kl_index_key_tl]{index~key} + \NewKnowledgeParamBool*{no~index}\knowledge_kl_noindex_bool +} +\bool_if:NT\knowledge_imakeidx_syntax_bool { + \NewKnowledgeParamTl*[\knowledge_kl_index_name_tl]{index~name} +} +\knowledge_directives_require_aci_package:nn + {index,index~key,index~parent~key,index~style}{makeidx} +\knowledge_directives_require_aci_package:nn + {index~name}{imakeidx} \bool_if:NTF\knowledge_cleveref_active_bool{ \knowledgenewvariant\kcref{ namespace=default, -- cgit v1.2.3