summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/l3experimental/l3str/l3flag.sty
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/l3experimental/l3str/l3flag.sty')
-rw-r--r--Master/texmf-dist/tex/latex/l3experimental/l3str/l3flag.sty100
1 files changed, 100 insertions, 0 deletions
diff --git a/Master/texmf-dist/tex/latex/l3experimental/l3str/l3flag.sty b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3flag.sty
new file mode 100644
index 00000000000..40e2c899682
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/l3experimental/l3str/l3flag.sty
@@ -0,0 +1,100 @@
+%%
+%% This is file `l3flag.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% l3flag.dtx (with options: `package')
+%%
+%% EXPERIMENTAL CODE
+%%
+%% Do not distribute this file without also distributing the
+%% source files specified above.
+%%
+%% Do not distribute a modified version of this file.
+%%
+%% File: l3flag.dtx Copyright (C) 2011 The 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
+%% license or (at your option) any later version. The latest version
+%% of this license is in the file
+%%
+%% http://www.latex-project.org/lppl.txt
+%%
+%% This file is part of the "l3experimental bundle" (The Work in LPPL)
+%% and all files in that bundle must be distributed together.
+%%
+%% The released version of this bundle is available from CTAN.
+%%
+%% -----------------------------------------------------------------------
+%%
+%% The development version of the bundle can be found at
+%%
+%% http://www.latex-project.org/svnroot/experimental/trunk/
+%%
+%% for those people who are interested.
+%%
+%%%%%%%%%%%
+%% NOTE: %%
+%%%%%%%%%%%
+%%
+%% Snapshots taken from the repository represent work in progress and may
+%% not work or may contain conflicting material! We therefore ask
+%% people _not_ to put them into distributions, archives, etc. without
+%% prior consultation with the LaTeX3 Project.
+%%
+%% -----------------------------------------------------------------------
+\RequirePackage{expl3}
+\GetIdInfo$Id: l3flag.dtx 3039 2011-12-08 09:22:35Z bruno $
+ {L3 Experimental Flags}
+\ProvidesExplPackage
+ {\ExplFileName}{\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription}
+\tl_new:N \g_flag_list_tl
+\cs_new_protected:Npn \flag_new:N #1
+ {
+ \tl_if_in:NnTF \g_flag_list_tl {#1}
+ {
+ \msg_kernel_error:nnx
+ { flag } { already-defined }
+ { \token_to_str:N #1 }
+ }
+ {
+ \tl_gput_right:Nn \g_flag_list_tl {#1}
+ \cs_new_eq:NN #1 \c_undefined:D
+ }
+ }
+\cs_generate_variant:Nn \flag_new:N { c }
+\prg_new_conditional:Npnn \flag_test:N #1 { p , T , F , TF }
+ {
+ \if_cs_exist:N #1
+ \prg_return_true:
+ \else:
+ \prg_return_false:
+ \fi:
+ }
+\prg_new_conditional:Npnn \flag_test:c #1 { p , T , F , TF }
+ {
+ \if_cs_exist:w #1 \cs_end:
+ \prg_return_true:
+ \else:
+ \prg_return_false:
+ \fi:
+ }
+\cs_new:Npn \flag_raise:N #1
+ { \exp_after:wN \use_none:n \cs:w \cs_to_str:N #1 \cs_end: }
+\cs_new:Npn \flag_raise:c #1
+ { \exp_after:wN \use_none:n \cs:w #1 \cs_end: }
+\cs_new_protected:Npn \flag_lower:N #1
+ { \cs_set_eq:NN #1 \c_undefined:D }
+\cs_generate_variant:Nn \flag_lower:N { c }
+\msg_kernel_new:nnnn { flag } { already-defined }
+ { The~control~sequence~#1~is~already~declared~as~a~flag. }
+ {
+ LaTeX~was~asked~to~define~the~flag~#1,~but~it~has~already~
+ been~defined~as~a~flag.~The~flag~module~is~mostly~meant~
+ for~kernel~use,~and~booleans~should~be~preferred.
+ }
+%%
+%%
+%% End of file `l3flag.sty'.