summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/l3kernel/l3doc.cls
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2019-07-26 20:49:26 +0000
committerKarl Berry <karl@freefriends.org>2019-07-26 20:49:26 +0000
commit74fa963e66ff62baef03b36472b23b04a6747f11 (patch)
treed54eb8ac1a894db3056a48f37011ba04a3b71210 /Master/texmf-dist/tex/latex/l3kernel/l3doc.cls
parentc6b7d46ff1b9b5e7edbed8ee6f65a00d8376222f (diff)
l3kernel (26jul19)
git-svn-id: svn://tug.org/texlive/trunk@51745 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/l3kernel/l3doc.cls')
-rw-r--r--Master/texmf-dist/tex/latex/l3kernel/l3doc.cls34
1 files changed, 28 insertions, 6 deletions
diff --git a/Master/texmf-dist/tex/latex/l3kernel/l3doc.cls b/Master/texmf-dist/tex/latex/l3kernel/l3doc.cls
index e1f1aad315d..111e14befe9 100644
--- a/Master/texmf-dist/tex/latex/l3kernel/l3doc.cls
+++ b/Master/texmf-dist/tex/latex/l3kernel/l3doc.cls
@@ -72,6 +72,7 @@
\tl_new:N \l__codedoc_index_macro_tl
\tl_new:N \l__codedoc_index_key_tl
\tl_new:N \l__codedoc_index_module_tl
+\tl_new:N \l__codedoc_macro_do_not_index_tl
\bool_new:N \l__codedoc_index_internal_bool
\tl_new:N \g__codedoc_module_name_tl
\tl_const:Nn \c__codedoc_iow_rule_tl
@@ -117,6 +118,7 @@
\cs_generate_variant:Nn \tl_remove_all:Nn { Nx }
\cs_generate_variant:Nn \tl_replace_all:Nnn { Nx , Nnx, No , Nno }
\cs_generate_variant:Nn \tl_replace_once:Nnn { Noo }
+\cs_generate_variant:Nn \tl_set_rescan:Nnn { NnV }
\cs_generate_variant:Nn \tl_to_str:n { f , o }
\cs_generate_variant:Nn \prop_get:NnNTF { Nx }
\cs_generate_variant:Nn \prop_put:Nnn { Nx }
@@ -1345,6 +1347,9 @@
verb .bool_set:N = \l__codedoc_names_verb_bool ,
module .tl_set:N = \l__codedoc_override_module_tl ,
documented-as .tl_set:N = \l__codedoc_macro_documented_tl ,
+ do-not-index .value_required:n = true ,
+ do-not-index .tl_set:N = \l__codedoc_macro_do_not_index_tl ,
+ % do-not-index .default:n = \q_no_value ,
}
\cs_new_protected:Npn \__codedoc_macro:nnw #1#2
{
@@ -1353,6 +1358,7 @@
\keys_set:nn { l3doc/macro } {#1}
\__codedoc_names_get_seq:nN {#2} \l__codedoc_names_seq
\__codedoc_names_parse:
+ \__codedoc_macro_exclude_index:
\__codedoc_macro_save_names:
\__codedoc_names_typeset:
\__codedoc_macro_dump:
@@ -1401,6 +1407,20 @@
}
\cs_new_protected:Npn \__codedoc_macro_save_names_aux:n #1
{ \seq_gput_right:Nn \g__codedoc_nested_names_seq {#1} }
+\cs_new_protected:Npn \__codedoc_macro_exclude_index:
+ {
+ \tl_if_empty:NF \l__codedoc_macro_do_not_index_tl
+ {
+ \tl_set_rescan:NnV \l__codedoc_macro_do_not_index_tl
+ { \MakePrivateLetters \catcode`\\12 }
+ \l__codedoc_macro_do_not_index_tl
+ \exp_args:NNV \seq_set_from_clist:Nn
+ \l__codedoc_tmpa_seq \l__codedoc_macro_do_not_index_tl
+ \tl_set:Nx \l__codedoc_macro_do_not_index_tl
+ { \seq_use:Nn \l__codedoc_tmpa_seq { , } }
+ \exp_args:NV \DoNotIndex \l__codedoc_macro_do_not_index_tl
+ }
+ }
\cs_new_protected:Npn \__codedoc_macro_dump:
{
\topsep\MacroTopsep
@@ -1822,10 +1842,12 @@
\@tempswatrue
\if@partsw
\@tempswafalse
- \cs_set:Npx \@tempb{#1}
- \@for\@tempa:=\@partlist\do
+ \cs_set:Npx \@tempb {#1}
+ \clist_map_inline:Nn \@partlist
{
- \ifx\@tempa\@tempb\@tempswatrue\fi
+ \if_meaning:w \@tempa \@tempb
+ \@tempswatrue
+ \fi:
}
\fi
\if@tempswa
@@ -1933,7 +1955,7 @@
}
\cs_new_protected:Npn \__codedoc_xmacro_code:w #1 < @ @ = #2 >
{
- % Add code before <__codedoc=...>
+ % Add code before <@@=...>
\tl_set:Nn \l__codedoc_tmpb_tl {#1}
\__codedoc_detect_internals:N \l__codedoc_tmpb_tl
\__codedoc_replace_at_at:N \l__codedoc_tmpb_tl
@@ -1941,7 +1963,7 @@
% Check for \q_recursion_tail
\quark_if_recursion_tail_stop_do:nn {#2}
{ \tl_use:N \l__codedoc_tmpa_tl }
- % Change module name and add <__codedoc=#2> to typeset output
+ % Change module name and add <@@=#2> to typeset output
\tl_gset:Nn \g__codedoc_module_name_tl {#2}
\tl_put_right:Nn \l__codedoc_tmpa_tl { < \text { \verbatim@font @ @ = #2 } > }
% Loop
@@ -2215,7 +2237,7 @@
}
\cs_new_protected:Npn \__codedoc_quote_special_char:N #1
{
- \tl_map_inline:nn { \quotechar \actualchar \encapchar \levelchar }
+ \tl_map_inline:nn { \quotechar \actualchar \encapchar \levelchar \bslash }
{
\tl_replace_all:Nxn #1
{ \tl_to_str:N ##1 } { \quotechar \tl_to_str:N ##1 }