![適切な下付き文字と上付き文字、およびカスタム引数を持つ複合用語集コマンド](https://rvso.com/image/472719/%E9%81%A9%E5%88%87%E3%81%AA%E4%B8%8B%E4%BB%98%E3%81%8D%E6%96%87%E5%AD%97%E3%81%A8%E4%B8%8A%E4%BB%98%E3%81%8D%E6%96%87%E5%AD%97%E3%80%81%E3%81%8A%E3%82%88%E3%81%B3%E3%82%AB%E3%82%B9%E3%82%BF%E3%83%A0%E5%BC%95%E6%95%B0%E3%82%92%E6%8C%81%E3%81%A4%E8%A4%87%E5%90%88%E7%94%A8%E8%AA%9E%E9%9B%86%E3%82%B3%E3%83%9E%E3%83%B3%E3%83%89.png)
gls シンボルの結合に役立つマクロを作成したいと思います。各複合シンボルは、本体と (オプションで) 上付き文字と下付き文字 (それ自体が gls シンボルであり、下付き文字/上付き文字の異なるシンボル リストにリストされます) で構成されます。さらに、一部の複合シンボルにカスタム引数を追加したいと思います。実現したいことの一例:
私の問題は次のとおりです:
- 複合文字の後に追加される下付き/上付き文字が「複合」下付き/上付き文字に追加されていることを確認するには、定義したマクロ ( )
xparse
の最後の 2 つのパラメーターとしての装飾機能を使用する必要があります。E{^_}{{}{}}
- 事前にいくつのカスタム引数が追加されるかがわからないため、
args=
装飾にどのパラメータ番号が含まれるかはわかりません (つまり、引数の数を数えて、パラメータ番号を動的に追加する必要があります)。
私は次のコードを思いつきました (これは動作しません)。ここでの主な問題は、マクロが最終的に定義される前に、装飾 (\l_compound_supparameter_tl
および\l_compound_subparameter_tl
) のパラメータ番号を保持する変数が展開されるという正しい展開であると思います。さらに、 にはコンマで区切られた引数仕様しか渡すことができませんでしたargs
。
\documentclass[margin=5mm]{standalone}
\usepackage[symbols]{glossaries}
\newglossaryentry{body}{
type=symbols,
name={body},
symbol={B},
description={A body.}
}
\newglossaryentry{phase}{
type=symbols,
name={phase},
symbol={\alpha},
description={A material phase.}
}
\newglossaryentry{index}{
type=symbols,
name={index},
symbol={i},
description={A body index.}
}
\ExplSyntaxOn
% Define the keys
\keys_define:nn { my/glscompound }{
body .tl_set:N = \l_compound_body_tl,
args .tl_set:N = \l_compound_args_tl,
superscript .tl_set:N = \l_compound_superscript_tl,
superscript .initial:n = {},
subscript .tl_set:N = \l_compound_subscript_tl,
subscript .initial:n = {},
}
\tl_new:N \l_compound_supparameter_tl % stores the macro parameter for superscript (e.g. #3)
\tl_new:N \l_compound_subparameter_tl % stores the macro parameter for subscript (e.g. #4)
\cs_generate_variant:Nn \exp_args:Nnnx { NnVx }
\NewDocumentCommand{\NewGlsCompound}{ m m }{
\tl_clear:N \l_compound_body_tl
\tl_clear:N \l_compound_args_tl
\tl_clear:N \l_compound_superscript_tl
\tl_clear:N \l_compound_subscript_tl
\tl_set:Nn \l_compound_supparameter_tl { # }
\tl_set:Nn \l_compound_subparameter_tl { # }
\keys_set:nn { my/glscompound } { #2 }
% convert tl to sequence of arguments
\seq_set_split:NnV \l_tmpa_seq { , } \l_compound_args_tl
% get the count of the seq to determine the number of custom arguments
\int_set:Nn \l_tmpa_int { \seq_count:N \l_tmpa_seq }
% parameter number of superscript
\int_incr:N \l_tmpa_int
\tl_put_right:NV \l_compound_supparameter_tl \l_tmpa_int
% parameter number of subscript
\int_incr:N \l_tmpa_int
\tl_put_right:NV \l_compound_subparameter_tl \l_tmpa_int
% convert the arument seq to a single tl
\tl_set:No \l_compound_args_tl { \seq_use:Nn \l_tmpa_seq { , } }
% append the sub/superscript arguments
\tl_put_right:Nn \l_compound_args_tl { ~E{^_}{{}{}} }
% Define the new command
\exp_args:NnVx \NewDocumentCommand {#1} \l_compound_args_tl {
\l_compound_body_tl
% superscript
% evaluated during runtime, if an additional superscript as parameter
% '\l_compound_supparameter_tl' is given
\IfValueT{ \l_compound_supparameter_tl }{
% append the custom superscript to the body of the compound superscript
\tl_put_right:Nn \l_compound_superscript_tl { \l_compound_supparameter_tl }
}
% if the body of the superscript is not empty, call the superscript macro
\tl_if_blank:VF \l_compound_superscript_tl { \sp{ \l_compound_superscript_tl } }
% subscript (same as superscript)
\IfValueT{ \l_compound_supparameter_tl }{
\tl_put_right:Nn \l_compound_subscript_tl { \l_compound_supparameter_tl }
}
\tl_if_blank:VF \l_compound_subscript_tl { \sb{ \l_compound_subscript_tl } }
}
}
\ExplSyntaxOff
\NewGlsCompound{\Body}{
body = { \glssymbol{body} },
args = { O{arg1}, O{arg2} }, % this is comma separated list of arguments
superscript = { \glssymbol{phase},#1 },
subscript = { \glssymbol{index},#2 },
}
\begin{document}
\begin{minipage}{.7\textwidth}
\renewcommand{\arraystretch}{1.5}
\begin{tabular}{l l}
\verb+\Body+ &\(\rightarrow \Body\)\\
\verb+\Body^{,a}_{,y}+ &\(\rightarrow \Body^{,a}_{,y}\)\\
\verb+\Body[foo]+ &\(\rightarrow \Body[foo]\)\\
\verb+\Body[foo]^{,x}+ &\(\rightarrow \Body[foo]^{,x}\)\\
\verb+\Body[foo][bar]^{,x}+ &\(\rightarrow \Body[foo][bar]^{,x}\)
\end{tabular}
\end{minipage}
\end{document}
拡張の混乱を解消するためにご協力いただければ、大変助かります。
答え1
まず、xparse-argument-signature によって指定された引数の数をカウントするルーチンが必要です。
以下の例では、これがルーチンです
\MYSTUFF_xparse_arg_signature_count:n
。私は
\__cmd_split_signature:n
、コメント付き LaTeX 2ε ソース、ファイル g: ltcmd.dtx 日付: 2023-08-19 バージョン v1.2a、セクション「1.7.2 コマンドの定義の表示」。ルーチンは、
\MYSTUFF_xparse_arg_signature_count:n
のインスタンスの x-parse-argument-signature を形成する引数を取ります\NewDocumentCommand
。
ルーチンは、2 つの展開ステップの後、 x-parse-argument-signature で指定された引数の数を 10 進表記で示す数字トークンのシーケンスを返します。もう 1 つの問題は、定義が有効になっているときに、カテゴリ8 (下付き文字) のアンダースコア ( )が、 によって定義されたコマンドの -type 引数
_
の装飾指定に取り込まれることです。その結果、アンダースコアのカテゴリ コードが 11 (文字) になります。E
\NewGlsCompound
\NewGlsCompound
\ExplSyntaxOn
私は次のように対処します:
%\errorcontextlines=10000
\ExplSyntaxOn
%-------------------------------------------------------------------------------
\cs_new:Nn \MYSTUFF_xparse_arg_signature_count:n
{
\exp:w \exp_after:wN \exp_after:wN \exp_after:wN \exp_end:
\int_eval:n
{
0 \__MYSTUFF_xparse_arg_signature_count_loop:Nw #1
\q_recursion_tail \q_recursion_stop
}
}
\cs_new:Npn \__MYSTUFF_xparse_arg_signature_count_loop:Nw #1
{
\quark_if_recursion_tail_stop:N #1
\tl_if_exist:cTF
{ c_MYSTUFF_xparse_map_arg_type_to_argclass_\tl_to_str:n{#1}_tl }
{
\tl_use:c
{ c_MYSTUFF_xparse_map_arg_type_to_argclass_\tl_to_str:n{#1}_tl }
}
{ +1 \__MYSTUFF_xparse_arg_signature_count_loop:Nw }
}
\cs_set:Npn \__cmd_tmp:w #1 #2
{
\quark_if_nil:nF
{#1}
{
\tl_const:cn { c_MYSTUFF_xparse_map_arg_type_to_argclass_#1_tl } {#2}
\__cmd_tmp:w
}
}
\__cmd_tmp:w
t{\__MYSTUFF_xparse_arg_remove_arg_specification_of_class_delim:w}
r{\__MYSTUFF_xparse_arg_remove_arg_specification_of_class_delims:w}
d{\__MYSTUFF_xparse_arg_remove_arg_specification_of_class_delims:w}
R{\__MYSTUFF_xparse_arg_remove_arg_specification_of_class_delims_opt:w}
D{\__MYSTUFF_xparse_arg_remove_arg_specification_of_class_delims_opt:w}
O{\__MYSTUFF_xparse_arg_remove_arg_specification_of_class_opt:w}
e{\__MYSTUFF_xparse_arg_remove_arg_specification_of_class_e:w}
E{\__MYSTUFF_xparse_arg_remove_arg_specification_of_class_E:w}
+{\__MYSTUFF_xparse_arg_remove_arg_specification_of_class_prefix:w}
!{\__MYSTUFF_xparse_arg_remove_arg_specification_of_class_prefix:w}
>{\__MYSTUFF_xparse_arg_remove_arg_specification_of_class_processor:w}
={\__MYSTUFF_xparse_arg_remove_arg_specification_of_class_processor:w}
\q_nil \q_nil
%------------
\cs_new:Npn \__MYSTUFF_xparse_arg_remove_arg_specification_of_class_delim:w
#1
{ +1 \__MYSTUFF_xparse_arg_signature_count_loop:Nw }
\cs_new:Npn \__MYSTUFF_xparse_arg_remove_arg_specification_of_class_delims:w
#1 #2
{ +1 \__MYSTUFF_xparse_arg_signature_count_loop:Nw }
\cs_new:Npn \__MYSTUFF_xparse_arg_remove_arg_specification_of_class_delims_opt:w
#1 #2 #3
{ +1 \__MYSTUFF_xparse_arg_signature_count_loop:Nw }
\cs_new:Npn \__MYSTUFF_xparse_arg_remove_arg_specification_of_class_opt:w
#1
{ +1 \__MYSTUFF_xparse_arg_signature_count_loop:Nw }
\cs_new:Npn \__MYSTUFF_xparse_arg_remove_arg_specification_of_class_e:w
#1
{ +\tl_count:n{#1} \__MYSTUFF_xparse_arg_signature_count_loop:Nw }
\cs_new:Npn \__MYSTUFF_xparse_arg_remove_arg_specification_of_class_E:w
#1 #2
{ +\tl_count:n{#1} \__MYSTUFF_xparse_arg_signature_count_loop:Nw }
\cs_new:Npn \__MYSTUFF_xparse_arg_remove_arg_specification_of_class_prefix:w
{ \__MYSTUFF_xparse_arg_signature_count_loop:Nw }
\cs_new:Npn \__MYSTUFF_xparse_arg_remove_arg_specification_of_class_processor:w
#1
{ \__MYSTUFF_xparse_arg_signature_count_loop:Nw }
%-------------------------------------------------------------------------------
\cs_if_exist:NF \IfBlankF { \cs_new_eq:NN \IfBlankF \tl_if_blank:nF }
\cs_if_exist:NF \IfBlankT { \cs_new_eq:NN \IfBlankT \tl_if_blank:nT }
\cs_if_exist:NF \IfBlankTF { \cs_new_eq:NN \IfBlankTF \tl_if_blank:nTF }
%-------------------------------------------------------------------------------
\tl_new:N \l_MYSTUFF_GLSCOMPOUND_body_tl
\tl_new:N \l_MYSTUFF_GLSCOMPOUND_args_tl
\tl_new:N \l_MYSTUFF_GLSCOMPOUND_superscript_tl
\tl_new:N \l_MYSTUFF_GLSCOMPOUND_subscript_tl
\tl_new:N \l_MYSTUFF_GLSCOMPOUND_supparameter_tl
\tl_new:N \l_MYSTUFF_GLSCOMPOUND_subparameter_tl
%-------------------------------------------------------------------------------
\keys_define:nn { MYSTUFF/GLSCOMPOUND }{
body.tl_set:N = \l_MYSTUFF_GLSCOMPOUND_body_tl,
args.tl_set:N = \l_MYSTUFF_GLSCOMPOUND_args_tl,
superscript.tl_set:N = \l_MYSTUFF_GLSCOMPOUND_superscript_tl,
subscript.tl_set:N = \l_MYSTUFF_GLSCOMPOUND_subscript_tl,
}
% ------------------------------------------------------------------------------
% Use expl3-infrastructure for providing error-message in case the key
% "body" is not specified in the 2nd argument of \NewGlsCompound.
% ..............................................................................
\prop_gput:Nnn \g_msg_module_type_prop { MYSTUFF_GLSCOMPOUND } {}
\prop_gput:Nnn
\g_msg_module_name_prop
{ MYSTUFF_GLSCOMPOUND }
{Macro-Defined-In-Preamble:}
\msg_new:nnnn {MYSTUFF_GLSCOMPOUND}
{No Value specified}
{Macro~#1:~No~value~for~key~"#3"~specified.}
{In~the~#2~argument~a~value~for~key~"#3"~must~be~specified~%
when~calling~macro~#1.}
\cs_new:Npn \NoValueSpecifiedError #1#2#3 {
\exp_args:Nne \use:nn {
\msg_error:nnnnn {MYSTUFF_GLSCOMPOUND} {No Value specified}
}{{\iow_char:N \\ \cs_to_str:N#1}}{#2}{#3}
}%
%-------------------------------------------------------------------------------
% In order to get _ of category 8(subscript) and ^ of category 7(superscript)
% into the embellishment specification of the E-type argument of the command
% defined via \NewGlsCompound, define a scratch variant of \NewGlsCompound
% which as arguments grabs these tokens and redefines itself.
\group_begin:
\cs_set:Npn \NewGlsCompound #1#2
{
\group_end:
\NewDocumentCommand \NewGlsCompound {mm} {
\group_begin:
\exp_args:Nnx \keys_set:nn { MYSTUFF/GLSCOMPOUND } {
body={\exp_not:o{\c_novalue_tl}},
args={},
superscript={},
subscript={}
}
\keys_set:nn { MYSTUFF/GLSCOMPOUND } { ##2 }
\exp_args:NV \tl_if_novalue:nTF
\l_MYSTUFF_GLSCOMPOUND_body_tl
{ \group_end: \NoValueSpecifiedError{\NewGlsCompound}{second}{body} }
{
\tl_set:Nf \l_MYSTUFF_GLSCOMPOUND_supparameter_tl
{
\int_eval:n
{
\exp_args:No \MYSTUFF_xparse_arg_signature_count:n
{\l_MYSTUFF_GLSCOMPOUND_args_tl} + 1
}
}
\tl_set:Nf \l_MYSTUFF_GLSCOMPOUND_subparameter_tl
{
\int_eval:n
{
\tl_use:N \l_MYSTUFF_GLSCOMPOUND_supparameter_tl + 1
}
}
\tl_put_left:Nn \l_MYSTUFF_GLSCOMPOUND_supparameter_tl {####}
\tl_put_left:Nn \l_MYSTUFF_GLSCOMPOUND_subparameter_tl {####}
\tl_put_right:Nn \l_MYSTUFF_GLSCOMPOUND_args_tl { E{#1#2}{{}{}} }
\__MYSTUFF_GLSCOMPOUND_set_scriptdirective_to_tokenlist:NNN
\l_MYSTUFF_GLSCOMPOUND_superscript_tl
\l_MYSTUFF_GLSCOMPOUND_supparameter_tl
#1
\__MYSTUFF_GLSCOMPOUND_set_scriptdirective_to_tokenlist:NNN
\l_MYSTUFF_GLSCOMPOUND_subscript_tl
\l_MYSTUFF_GLSCOMPOUND_subparameter_tl
#2
\exp_args:Nnx
\use:nn
{ \group_end: \NewDocumentCommand {##1} }
{
{ \exp_not:o{\l_MYSTUFF_GLSCOMPOUND_args_tl} }
{
\exp_not:o{ \l_MYSTUFF_GLSCOMPOUND_body_tl}
\exp_not:o{\l_MYSTUFF_GLSCOMPOUND_superscript_tl}
\exp_not:o{\l_MYSTUFF_GLSCOMPOUND_subscript_tl}
}
}
}
}
}
\char_set_catcode_math_superscript:N \^
\char_set_catcode_math_subscript:N \_
\NewGlsCompound{^}{_}
% Scratch-\NewGlsCompound im the line above does
% \group_end:
%--------------------
\cs_new:Nn \__MYSTUFF_GLSCOMPOUND_set_scriptdirective_to_tokenlist:NNN
{
% #1 = \l_MYSTUFF_GLSCOMPOUND_superscript_tl /
% \l_MYSTUFF_GLSCOMPOUND_subscript_tl
% #2 = \l_MYSTUFF_GLSCOMPOUND_supparameter_tl /
% \l_MYSTUFF_GLSCOMPOUND_subparameter_tl
% #3 = _ (subscript) or ^ (subscript)
\__MYSTUFF_GLSCOMPOUND_set_scriptdirective_to_tokenlist:NVVN#1#1#2#3
}
\cs_new:Nn \__MYSTUFF_GLSCOMPOUND_set_scriptdirective_to_tokenlist:NnnN
{
% #1 = \l_MYSTUFF_GLSCOMPOUND_superscript_tl /
% \l_MYSTUFF_GLSCOMPOUND_subscript_tl
% #2 = content of \l_MYSTUFF_GLSCOMPOUND_superscript_tl /
% content of \l_MYSTUFF_GLSCOMPOUND_subscript_tl
% #3 = content of \l_MYSTUFF_GLSCOMPOUND_supparameter_tl /
% content of \l_MYSTUFF_GLSCOMPOUND_subparameter_tl
% #4 = _ (subscript) or ^ (subscript)
\tl_if_blank:nTF{#2}
{
\tl_set:Nn
#1
{
\tl_if_blank:oF
{
\exp:w
\tl_if_blank:nTF{#3}{\use:n}{\use_ii_i:nn{#3}}{\exp_end:}
}
{
#4
{
\exp:w
\tl_if_blank:nTF{#3}{\use:n}{\use_ii_i:nn{#3}}{\exp_end:}
}
}
}
}
{
\tl_set:Nn
#1
{
\tl_if_blank:oF
{
\exp:w
\tl_if_blank:nTF{#3}{\use:n}{\use_ii_i:nn{,#3}}{\exp_end:#2}
}
{
#4
{
\exp:w
\tl_if_blank:nTF{#3}{\use:n}{\use_ii_i:nn{,#3}}{\exp_end: #2}
}
}
}
}
}
\cs_generate_variant:Nn
\__MYSTUFF_GLSCOMPOUND_set_scriptdirective_to_tokenlist:NnnN
{ NVVN }
\ExplSyntaxOff
\documentclass[margin=5mm]{standalone}
\usepackage{array}
\usepackage[symbols]{glossaries}
\newglossaryentry{body}{
type=symbols,
name={body},
symbol={B},
description={A body.}
}
\newglossaryentry{phase}{
type=symbols,
name={phase},
symbol={\alpha},
description={A material phase.}
}
\newglossaryentry{index}{
type=symbols,
name={index},
symbol={i},
description={A body index.}
}
\NewGlsCompound{\Body}{
body = {\glssymbol{body}},
args = {O{arg1} O{arg2}},
superscript = {\glssymbol{phase}\IfBlankF{#1}{,#1}},
subscript = {\glssymbol{index}\IfBlankF{#2}{,#2}}
}
%\NewGlsCompound{\Stuff}{
%% body = {stuff},
% args = { },
% superscript = {up},
% subscript = {down}
%}
\begin{document}
\begin{minipage}{\textwidth}
% \(\Stuff^{2up}_{2down}\) \par\bigskip
\renewcommand{\arraystretch}{1.5}
\begin{tabular}{l>{\(\rightarrow\)}c>{\(}l<{\)}}
\verb|\Body|&&\Body\\
\verb|\Body[foo]|&&\Body[foo]\\
\verb|\Body[foo][bar]|&&\Body[foo][bar]\\
\verb|\Body^{X}|&&\Body^{X}\\
\verb|\Body[foo]^{X}|&&\Body[foo]^{X}\\
\verb|\Body[foo][bar]^{X}|&&\Body[foo][bar]^{X}\\
\verb|\Body_{Y}|&&\Body_{Y}\\
\verb|\Body[foo]_{Y}|&&\Body[foo]_{Y}\\
\verb|\Body[foo][bar]_{Y}|&&\Body[foo][bar]_{Y}\\
\verb|\Body^{X}_{Y}|&&\Body^{X}_{Y}\\
\verb|\Body[foo]^{X}_{Y}|&&\Body[foo]^{X}_{Y}\\
\verb|\Body[foo][bar]^{X}_{Y}|&&\Body[foo][bar]^{X}_{Y}\\
\multicolumn{3}{l}{Behavior when specifying optional arguments blank:}\\
\verb|\Body[ ]|&&\Body[ ]\\
\verb|\Body[ ][ ]|&&\Body[ ][ ]\\
\verb|\Body[ ]^{X}|&&\Body[ ]^{X}\\
\verb|\Body[ ][ ]^{X}|&&\Body[ ][ ]^{X}\\
\verb|\Body[ ]_{Y}|&&\Body[ ]_{Y}\\
\verb|\Body[ ][ ]_{Y}|&&\Body[ ][ ]_{Y}\\
\verb|\Body[ ]^{X}_{Y}|&&\Body[ ]^{X}_{Y}\\
\verb|\Body[ ][ ]^{X}_{Y}|&&\Body[ ][ ]^{X}_{Y}\\
\multicolumn{3}{l}{Behavior when specifying embellishments blank:}\\
\verb|\Body^{ }|&&\Body^{ }\\
\verb|\Body[foo]^{ }|&&\Body[foo]^{ }\\
\verb|\Body[foo][bar]^{ }|&&\Body[foo][bar]^{ }\\
\verb|\Body_{ }|&&\Body_{ }\\
\verb|\Body[foo]_{ }|&&\Body[foo]_{ }\\
\verb|\Body[foo][bar]_{ }|&&\Body[foo][bar]_{ }\\
\verb|\Body^{ }_{ }|&&\Body^{ }_{ }\\
\verb|\Body[foo]^{ }_{ }|&&\Body[foo]^{ }_{ }\\
\verb|\Body[foo][bar]^{ }_{ }|&&\Body[foo][bar]^{ }_{ }\\
\multicolumn{3}{l}{Behavior when specifying optional args and
embellishments blank:}\\
\verb|\Body[ ]^{ }|&&\Body[ ]^{ }\\
\verb|\Body[ ][ ]^{ }|&&\Body[ ][ ]^{ }\\
\verb|\Body[ ]_{ }|&&\Body[ ]_{ }\\
\verb|\Body[ ][ ]_{ }|&&\Body[ ][ ]_{ }\\
\verb|\Body[ ]^{ }_{ }|&&\Body[ ]^{ }_{ }\\
\verb|\Body[ ][ ]^{ }_{ }|&&\Body[ ][ ]^{ }_{ }
\end{tabular}
\end{minipage}
\end{document}
注意:
装飾引数の値として
\Body^_{down}
whereが取得されるようなことはしないでください。_
^
および で示されるオプションの装飾引数の他に
^
、_
マクロには 2つの後続の - 区切りオプション引数\Body
もあります。したがって、最初の- 区切りオプション引数を明示的に指定してそのデフォルト値も提供する以外に、最初の - 区切りオプション引数のデフォルト値を維持しながら、これらの - 区切りオプション引数の 2 番目のデフォルト値のみを変更する方法はありません。[...]
[...]
[...]
[...]
現在 (2024 年 1 月 13 日、07:18:40 (UTC + 0000))、xparse-argument-signature で示される引数をカウントするための適切な公式インターフェイスは存在しないようです。
そのため\MYSTUFF_xparse_arg_signature_count:n
、将来の LaTeX リリースで内部的なものが変更されると、機能しなくなる可能性があります。たとえば、非標準の解析/カウントを備えた xparse-argument-type が追加され、引数シグネチャを解析するためのメカニズムを調整する必要がある場合などです。\MYSTUFF_xparse_arg_signature_count:n
有効な xparse-argument-signature である引数に対するエラー チェックは実装されていません。また、有効な xparse-argument-signature であるマクロの 2 番目の引数のキーの値に対するエラー チェックも実装されていません。args
したがって、その値が有効な xparse-argument-signature を形成しない場合、最初の引数で指定されたコマンドによる定義\NewGlsCompound
によってトリガーされる試行では、不明な引数タイプなどに関するエラー メッセージが表示されることがあります。\NewGlsCompound
\NewDocumentCommand