summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/expl3/l3candidates.dtx
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/source/latex/expl3/l3candidates.dtx')
-rw-r--r--Master/texmf-dist/source/latex/expl3/l3candidates.dtx53
1 files changed, 48 insertions, 5 deletions
diff --git a/Master/texmf-dist/source/latex/expl3/l3candidates.dtx b/Master/texmf-dist/source/latex/expl3/l3candidates.dtx
index 8051fb7f340..ba857b1a91e 100644
--- a/Master/texmf-dist/source/latex/expl3/l3candidates.dtx
+++ b/Master/texmf-dist/source/latex/expl3/l3candidates.dtx
@@ -1,5 +1,5 @@
% \iffalse
-%% File: l3candidates.dtx Copyright (C) 2005-2009 LaTeX3 project
+%% File: l3candidates.dtx Copyright (C) 2005-2010 LaTeX3 project
%%
%% It may be distributed and/or modified under the conditions of the
%% LaTeX Project Public License (LPPL), either version 1.3c of this
@@ -37,7 +37,7 @@
%</driver|package>
%\fi
\errorcontextlines=999
-\GetIdInfo$Id: l3candidates.dtx 1957 2010-06-15 06:33:43Z mittelba $
+\GetIdInfo$Id: l3candidates.dtx 2029 2010-09-19 13:59:02Z joseph $
{L3 Experimental 'extras' module}
%\iffalse
%<*driver>
@@ -75,7 +75,24 @@
% Beware, then, that loading this package and using its contents may cause your
% code to break down the track.
%
-% \section{Functions for functions}
+% \section{Functions for characters}
+%
+%
+% \begin{function}{\char_active_set:Npn|\char_active_gset:Npn}
+% \begin{syntax}
+% |\char_active_set:Npn|~<char>~<param>~<definition>
+% \end{syntax}
+% Makes <char> active and gives it the definition specified as if it were
+% a function.
+% \end{function}
+%
+% \begin{function}{\char_active_set_eq:NN|\char_active_gset_eq:NN}
+% \begin{syntax}
+% |\char_active_set:Npn|~<char>~<function>
+% \end{syntax}
+% Makes <char> active and makes it equal to <function>.
+% (Or another active char, etc.)
+% \end{function}
%
%
%
@@ -221,6 +238,32 @@
% \end{macrocode}
%
%
+% \begin{macro}{\char_active_set:Npn,\char_active_set:Npx,\char_active_gset:Npn,\char_active_gset:Npx}
+% \begin{macro}{\char_active_set_eq:NN,\char_active_gset_eq:NN}
+% \begin{macrocode}
+\group_begin:
+\char_make_active:N \^^@
+\cs_set:Npn \char_tmp:NN {
+ \cs_gnew:Npn #1 ##1 {
+ \char_make_active:n {`##1}
+ \group_begin:
+ \tex_lccode:D `\^^@ `##1
+ \tex_lowercase:D{\group_end: #2 ^^@}
+ }
+}
+\char_tmp:NN \char_active_set:Npn \cs_set:Npn
+\char_tmp:NN \char_active_set:Npx \cs_set:Npx
+\char_tmp:NN \char_active_gset:Npn \cs_gset:Npn
+\char_tmp:NN \char_active_gset:Npx \cs_gset:Npx
+\char_tmp:NN \char_active_set_eq:NN \cs_set_eq:NN
+\char_tmp:NN \char_active_gset_eq:NN \cs_gset_eq:NN
+\group_end:
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
+%
+%
% \begin{macro}{\tl_trim_spaces:n,\tl_trim_spaces:N}
% \begin{macrocode}
\cs_new:Npn \tl_trim_spaces:n #1 {
@@ -370,7 +413,7 @@
\prg_new_conditional:Nnn \clist_if_in_numrange:nn {TF,T,F} {
\bool_set_false:N \l_clist_numrange_bool
\clist_map_inline:nn {#2} {
- \_clist_numrange_parse:nw {#1} ##1 - \q_marker - \q_nil
+ \_clist_numrange_parse:nw {#1} ##1 - \q_nil - \q_stop
}
\bool_if:NTF \l_clist_numrange_bool \prg_return_true: \prg_return_false:
}
@@ -378,7 +421,7 @@
\bool_set_true:N \l_clist_numrange_bool
\clist_map_break:
}
-\cs_set:Npn \_clist_numrange_parse:nw #1 #2 - #3 - #4 \q_nil {
+\cs_set:Npn \_clist_numrange_parse:nw #1 #2 - #3 - #4 \q_stop {
\tl_if_empty:nTF {#4}{
\intexpr_compare:nT {#1=#2} {\_clist_numrange_success:}
}{