diff options
author | Karl Berry <karl@freefriends.org> | 2021-08-23 20:51:47 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2021-08-23 20:51:47 +0000 |
commit | 080ee0cef1631f16ed37bc76f13c6be3be525f05 (patch) | |
tree | b51192bd68c3add83b1ac38b3a64d58366bce03f | |
parent | cc7dcdd7ea83f25894871c0a10a99ab723a14f48 (diff) |
semantex (23aug21)
git-svn-id: svn://tug.org/texlive/trunk@60312 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r-- | Master/texmf-dist/doc/latex/semantex/semantex.pdf | bin | 384739 -> 385165 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/latex/semantex/semantex.tex | 86 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/semantex/semantex.sty | 160 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/semantex/stripsemantex.sty | 2 |
4 files changed, 221 insertions, 27 deletions
diff --git a/Master/texmf-dist/doc/latex/semantex/semantex.pdf b/Master/texmf-dist/doc/latex/semantex/semantex.pdf Binary files differindex b397d484450..7bbf5313c27 100644 --- a/Master/texmf-dist/doc/latex/semantex/semantex.pdf +++ b/Master/texmf-dist/doc/latex/semantex/semantex.pdf diff --git a/Master/texmf-dist/doc/latex/semantex/semantex.tex b/Master/texmf-dist/doc/latex/semantex/semantex.tex index 563be874be1..3b2630da085 100644 --- a/Master/texmf-dist/doc/latex/semantex/semantex.tex +++ b/Master/texmf-dist/doc/latex/semantex/semantex.tex @@ -42,7 +42,7 @@ \usepackage[nameinlink]{cleveref} -\title{Seman\!\TeX: semantic, keyval-based mathematics (v0.512)} +\title{Seman\!\TeX: semantic, keyval-based mathematics (v0.513)} \date{\today} \author{Sebastian Ørsted (\href{mailto:sorsted@gmail.com}{sorsted@gmail.com})} @@ -103,6 +103,10 @@ \usepackage{semantex} +\SemantexSetup{ + semtex file=true, +} + \usepackage{expkv} \NewVariableClass\MyVar[ @@ -2036,7 +2040,7 @@ Tuple-like commands are also possible: \NewObject\MyVar\tup[left par=(,right par=)] % tuples \NewObject\MyVar\pcoor[ % projective coordinates left par={[}, right par={]}, - set arg sep=\mathpunct{:}, + set arg sep=\mathbin{:}, % changes the argument separator to colon set arg dots=\dotsb, % changes what is inserted if you write "..." @@ -2045,7 +2049,7 @@ Tuple-like commands are also possible: \NewObject\MyVar\tup[left par=(,right par=)] % tuples \NewObject\MyVar\pcoor[ % projective coordinates left par={[}, right par={]}, - set arg sep=\mathpunct{:}, + set arg sep=\mathbin{:}, % changes the argument separator to colon set arg dots=\dotsb, % changes what is inserted if you write "..." @@ -3350,9 +3354,9 @@ In the following sections, we include the full list. Increases the \<integer\> by~\( 1 \). \item - \mylst!int if ieq TF={$\<integer\num{1}\>$}{$\<integer\num{2}\>$}{$\<if true\>$}{$\<if false\>$}!, \\ - \mylst!int if ieq T={$\<integer\num{1}\>$}{$\<integer\num{2}\>$}{$\<if true\>$}!, \\ - \mylst!int if ieq F={$\<integer\num{1}\>$}{$\<integer\num{2}\>$}{$\<if false\>$}! + \mylst!int if eq TF={$\<integer\num{1}\>$}{$\<integer\num{2}\>$}{$\<if true\>$}{$\<if false\>$}!, \\ + \mylst!int if eq T={$\<integer\num{1}\>$}{$\<integer\num{2}\>$}{$\<if true\>$}!, \\ + \mylst!int if eq F={$\<integer\num{1}\>$}{$\<integer\num{2}\>$}{$\<if false\>$}! Checks whether the integers \<integer\num{1}\> and \<integer\num{2}\> are equal, and runs \<if~true\> or \<if~false\> accordingly. @@ -3840,11 +3844,21 @@ In the following sections, we include the full list. \mylst!pre arg={$\<value\>$}! Sets the pre-argument. + + \item + \mylst!pre arg put left={$\<value\>$}! + + Adds to the left of the pre-argument. \item \mylst!post arg={$\<value\>$}! Sets the post-argument. + + \item + \mylst!post arg put right={$\<value\>$}! + + Adds to the right of the post-argument. \item \mylst!set arg sep={$\<value\>$}! @@ -3994,11 +4008,21 @@ In the following sections, we include the full list. \mylst!pre upper={$\<value\>$}! Sets the pre-upper index. + + \item + \mylst!pre upper put left={$\<value\>$}! + + Adds to the left of the pre-upper index. \item \mylst!post upper={$\<value\>$}! Sets the post-upper index. + + \item + \mylst!post upper put right={$\<value\>$}! + + Adds to the right of the post-upper index. \item \mylst!upper put left={$\<value\>$}! @@ -4192,11 +4216,21 @@ In the following sections, we include the full list. \mylst!pre lower={$\<value\>$}! Sets the pre-lower index. + + \item + \mylst!pre lower put left={$\<value\>$}! + + Adds to the left of the pre-lower index. \item \mylst!post lower={$\<value\>$}! Sets the post-lower index. + + \item + \mylst!post lower put right={$\<value\>$}! + + Adds to the right of the post-lower index. \item \mylst!lower put left={$\<value\>$}! @@ -4390,11 +4424,21 @@ In the following sections, we include the full list. \mylst!pre upper left={$\<value\>$}! Sets the pre-upper left index. + + \item + \mylst!pre upper left put left={$\<value\>$}! + + Adds to the left of the pre-upper left index. \item \mylst!post upper left={$\<value\>$}! Sets the post-upper left index. + + \item + \mylst!post upper left put right={$\<value\>$}! + + Adds to the right of the post-upper left index. \item \mylst!upper left put right={$\<value\>$}! @@ -4588,11 +4632,21 @@ In the following sections, we include the full list. \mylst!pre lower left={$\<value\>$}! Sets the pre-lower left index. + + \item + \mylst!pre lower left put left={$\<value\>$}! + + Adds to the left of the pre-lower left index. \item \mylst!post lower left={$\<value\>$}! Sets the post-lower left index. + + \item + \mylst!post lower left put right={$\<value\>$}! + + Adds to the right of the post-lower left index. \item \mylst!lower left put right={$\<value\>$}! @@ -4786,11 +4840,21 @@ In the following sections, we include the full list. \mylst!pre d={$\<value\>$}! Sets the pre-\lstinline!d!-index. + + \item + \mylst!pre d put left={$\<value\>$}! + + Adds to the left of the pre-\lstinline!d!-index. \item \mylst!post d={$\<value\>$}! Sets the post-\lstinline!d!-index. + + \item + \mylst!post d put right={$\<value\>$}! + + Adds to the right of the post-\lstinline!d!-index. \item \mylst!d put left={$\<value\>$}! @@ -4983,11 +5047,21 @@ In the following sections, we include the full list. \mylst!pre i={$\<value\>$}! Sets the pre-\lstinline!i!-index. + + \item + \mylst!pre i put left={$\<value\>$}! + + Adds to the left of the pre-\lstinline!i!-index. \item \mylst!post i={$\<value\>$}! Sets the post-\lstinline!i!-index. + + \item + \mylst!post i put right={$\<value\>$}! + + Adds to the right of the post-\lstinline!i!-index. \item \mylst!i put left={$\<value\>$}! diff --git a/Master/texmf-dist/tex/latex/semantex/semantex.sty b/Master/texmf-dist/tex/latex/semantex/semantex.sty index 5d7e6070a1c..325f2dbec59 100644 --- a/Master/texmf-dist/tex/latex/semantex/semantex.sty +++ b/Master/texmf-dist/tex/latex/semantex/semantex.sty @@ -1,5 +1,5 @@ \RequirePackage{xparse,l3keys2e,leftindex,semtex} -\ProvidesExplPackage{semantex}{2021/08/10}{0.512}{} +\ProvidesExplPackage{semantex}{2021/08/23}{0.513}{} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % @@ -10,7 +10,7 @@ % % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\tl_set:Nn\SemantexVersion{0.512} +\tl_set:Nn\SemantexVersion{0.513} \cs_set_eq:NN \semantex_keyval_parse:NNn \keyval_parse:NNn \cs_set:Npn \semantex_singlekey_parse:Nn#1#2 { \clist_map_function:nN { #2 } #1 } @@ -1574,13 +1574,15 @@ \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } { lower~put~left } { \semantex_data_tl_get_exp_not:nn { #1 } { lower } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } - { pre~upper } { \semantex_data_tl_get_exp_not:nn { #1 } { pre~upper } } + { pre~upper~put~left } { \semantex_data_tl_get_exp_not:nn { #1 } { pre~upper } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } - { post~upper } { \semantex_data_tl_get_exp_not:nn { #1 } { post~upper } } + { post~upper~put~right } { \semantex_data_tl_get_exp_not:nn { #1 } { post~upper } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } - { pre~lower } { \semantex_data_tl_get_exp_not:nn { #1 } { pre~lower } } + { pre~lower~put~left } { \semantex_data_tl_get_exp_not:nn { #1 } { pre~lower } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } - { post~lower } { \semantex_data_tl_get_exp_not:nn { #1 } { post~lower } } + { post~lower~put~right } { \semantex_data_tl_get_exp_not:nn { #1 } { post~lower } } + \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } + { slanting~phantom } { } % reset slanting phantom \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } { math~class } { \semantex_data_tl_get_exp_not:nn { #1 } { math~class } } \exp_not:V \l__semantex_render_output_options_temp_tl @@ -1609,13 +1611,13 @@ \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } { lower~left~put~right } { \semantex_data_tl_get_exp_not:nn { #1 } { lower~left } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } - { pre~upper~left } { \semantex_data_tl_get_exp_not:nn { #1 } { pre~upper~left } } + { pre~upper~left~put~left } { \semantex_data_tl_get_exp_not:nn { #1 } { pre~upper~left } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } - { post~upper~left } { \semantex_data_tl_get_exp_not:nn { #1 } { post~upper~left } } + { post~upper~left~put~right } { \semantex_data_tl_get_exp_not:nn { #1 } { post~upper~left } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } - { pre~lower~left } { \semantex_data_tl_get_exp_not:nn { #1 } { pre~lower~left } } + { pre~lower~left~put~left } { \semantex_data_tl_get_exp_not:nn { #1 } { pre~lower~left } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } - { post~lower~left } { \semantex_data_tl_get_exp_not:nn { #1 } { post~lower~left } } + { post~lower~left~put~right } { \semantex_data_tl_get_exp_not:nn { #1 } { post~lower~left } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } { height~phantom } { \semantex_data_tl_get_exp_not:nn { #1 } { height~phantom } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } @@ -1651,21 +1653,21 @@ \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } { lower~left~put~right } { \semantex_data_tl_get_exp_not:nn { #1 } { lower~left } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } - { pre~upper } { \semantex_data_tl_get_exp_not:nn { #1 } { pre~upper } } + { pre~upper~put~left } { \semantex_data_tl_get_exp_not:nn { #1 } { pre~upper } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } - { post~upper } { \semantex_data_tl_get_exp_not:nn { #1 } { post~upper } } + { post~upper~put~right } { \semantex_data_tl_get_exp_not:nn { #1 } { post~upper } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } - { pre~lower } { \semantex_data_tl_get_exp_not:nn { #1 } { pre~lower } } + { pre~lower~put~left } { \semantex_data_tl_get_exp_not:nn { #1 } { pre~lower } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } - { post~lower } { \semantex_data_tl_get_exp_not:nn { #1 } { post~lower } } + { post~lower~put~right } { \semantex_data_tl_get_exp_not:nn { #1 } { post~lower } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } - { pre~upper~left } { \semantex_data_tl_get_exp_not:nn { #1 } { pre~upper~left } } + { pre~upper~left~put~left } { \semantex_data_tl_get_exp_not:nn { #1 } { pre~upper~left } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } - { post~upper~left } { \semantex_data_tl_get_exp_not:nn { #1 } { post~upper~left } } + { post~upper~left~put~right } { \semantex_data_tl_get_exp_not:nn { #1 } { post~upper~left } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } - { pre~lower~left } { \semantex_data_tl_get_exp_not:nn { #1 } { pre~lower~left } } + { pre~lower~left~put~left } { \semantex_data_tl_get_exp_not:nn { #1 } { pre~lower~left } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } - { post~lower~left } { \semantex_data_tl_get_exp_not:nn { #1 } { post~lower~left } } + { post~lower~left~put~right } { \semantex_data_tl_get_exp_not:nn { #1 } { post~lower~left } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } { height~phantom } { \semantex_data_tl_get_exp_not:nn { #1 } { height~phantom } } \exp_not:N\semantex_base_object_valuekey:nnn { \l__semantex_render_object_associated_to_output_class_tempt_tl } @@ -7828,8 +7830,34 @@ {arg~without~keyval~set}{ execute={ \semantex_arg_without_keyval:nn { ##1 } { #1 } } }, {set~arg~without~keyval~x}{ execute={ \semantex_arg_without_keyval:nx { ##1 } { #1 } } }, {arg~without~keyval~set~x}{ execute={ \semantex_arg_without_keyval:nx { ##1 } { #1 } } }, - {pre~arg}{ execute={ \semantex_data_tl_put_right:nnn { ##1 } { pre~arg } { #1 } } }, - {post~arg}{ execute={ \semantex_data_tl_put_left:nnn { ##1 } { post~arg } { #1 } } }, + {pre~arg}{ + execute={ + \tl_if_blank:nF{#1}{ + \semantex_data_tl_put_right:nnn { ##1 } { pre~arg } { #1 } + } + }, + }, + {pre~arg~put~left}{ + execute={ + \tl_if_blank:nF{#1}{ + \semantex_data_tl_put_left:nnn { ##1 } { pre~arg } { #1 } + } + }, + }, + {post~arg}{ + execute={ + \tl_if_blank:nF{#1}{ + \semantex_data_tl_put_left:nnn { ##1 } { post~arg } { #1 } + } + }, + }, + {post~arg~put~right}{ + execute={ + \tl_if_blank:nF{#1}{ + \semantex_data_tl_put_right:nnn { ##1 } { post~arg } { #1 } + } + }, + }, {set~arg~sep}{ execute={ \semantex_data_tl_set:nnn { ##1 } { arg~sep } { #1 } } }, {set~arg~slot}{ execute={ \semantex_data_tl_set:nnn { ##1 } { arg~slot } { #1 } } }, {set~arg~dots}{ execute={ \semantex_data_tl_set:nnn { ##1 } { arg~dots } { #1 } } }, @@ -8073,6 +8101,13 @@ } }, }, + {pre~upper~put~left}{ + execute={ + \tl_if_blank:nF{#1}{ + \semantex_data_tl_put_left:nnn { ##1 } { pre~upper } { #1 } + } + }, + }, {post~upper}{ execute={ \tl_if_blank:nF{#1}{ @@ -8080,6 +8115,13 @@ } }, }, + {post~upper~put~right}{ + execute={ + \tl_if_blank:nF{#1}{ + \semantex_data_tl_put_right:nnn { ##1 } { post~upper } { #1 } + } + }, + }, {upper~put~left}{ execute={ \tl_if_blank:nF { #1 } @@ -8245,6 +8287,13 @@ } }, }, + {pre~lower~put~left}{ + execute={ + \tl_if_blank:nF{#1}{ + \semantex_data_tl_put_left:nnn { ##1 } { pre~lower } { #1 } + } + }, + }, {post~lower}{ execute={ \tl_if_blank:nF{#1}{ @@ -8252,6 +8301,13 @@ } }, }, + {post~lower~put~right}{ + execute={ + \tl_if_blank:nF{#1}{ + \semantex_data_tl_put_right:nnn { ##1 } { post~lower } { #1 } + } + }, + }, {lower~put~left}{ execute={ \tl_if_blank:nF { #1 } @@ -8417,6 +8473,13 @@ } }, }, + {pre~upper~left~put~left}{ + execute={ + \tl_if_blank:nF{#1}{ + \semantex_data_tl_put_left:nnn { ##1 } { pre~upper~left } { #1 } + } + }, + }, {post~upper~left}{ execute={ \tl_if_blank:nF{#1}{ @@ -8424,6 +8487,13 @@ } }, }, + {post~upper~left~put~right}{ + execute={ + \tl_if_blank:nF{#1}{ + \semantex_data_tl_put_right:nnn { ##1 } { post~upper~left } { #1 } + } + }, + }, {upper~left~put~right}{ execute={ \tl_if_blank:nF { #1 } @@ -8589,6 +8659,13 @@ } }, }, + {pre~lower~left~put~left}{ + execute={ + \tl_if_blank:nF{#1}{ + \semantex_data_tl_put_left:nnn { ##1 } { pre~lower~left } { #1 } + } + }, + }, {post~lower~left}{ execute={ \tl_if_blank:nF{#1}{ @@ -8596,6 +8673,13 @@ } }, }, + {post~lower~left~put~right}{ + execute={ + \tl_if_blank:nF{#1}{ + \semantex_data_tl_put_right:nnn { ##1 } { post~lower~left } { #1 } + } + }, + }, {lower~left~put~right}{ execute={ \tl_if_blank:nF { #1 } @@ -8786,6 +8870,15 @@ pre~lower={#1}, }, }, + {pre~d~put~left}{ + bool~if~TF={upper~grading} + { + pre~upper~put~left={#1}, + } + { + pre~lower~put~left={#1}, + }, + }, {post~d}{ bool~if~TF={upper~grading} { @@ -8795,6 +8888,15 @@ post~lower={#1}, }, }, + {post~d~put~right}{ + bool~if~TF={upper~grading} + { + post~upper~put~right={#1}, + } + { + post~lower~put~right={#1}, + }, + }, {d~put~left}{ bool~if~TF={upper~grading} { @@ -9013,6 +9115,15 @@ pre~upper={#1}, }, }, + {pre~i~put~left}{ + bool~if~TF={upper~grading} + { + pre~lower~put~left={#1}, + } + { + pre~upper~put~left={#1}, + }, + }, {post~i}{ bool~if~TF={upper~grading} { @@ -9022,6 +9133,15 @@ post~upper={#1}, }, }, + {post~i~put~right}{ + bool~if~TF={upper~grading} + { + post~lower~put~right={#1}, + } + { + post~upper~put~right={#1}, + }, + }, {i~put~left}{ bool~if~TF={upper~grading} { diff --git a/Master/texmf-dist/tex/latex/semantex/stripsemantex.sty b/Master/texmf-dist/tex/latex/semantex/stripsemantex.sty index c674680d6cf..4e5dafc2ee4 100644 --- a/Master/texmf-dist/tex/latex/semantex/stripsemantex.sty +++ b/Master/texmf-dist/tex/latex/semantex/stripsemantex.sty @@ -1,5 +1,5 @@ \RequirePackage{xparse} -\ProvidesExplPackage{stripsemantex}{2021/08/10}{0.512}{} +\ProvidesExplPackage{stripsemantex}{2021/08/23}{0.513}{} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % % |