add new theorem variant parser command

This commit is contained in:
Maximilian Keßler 2022-01-16 22:41:36 +01:00
parent 820ae92f28
commit 9cb5f5ed2f

View file

@ -348,6 +348,23 @@ __HEADER__(Grouping theorems for easier customization.)
}
}
\cs_new:Npn \new_theorem_variant_parser:nnn #1 #2 #3
{
\NewDocumentEnvironment{#1}{#2}
{
\clist_clear:N \l_groupthm_groups_clist
#3
\__sort_group_names:
\begin{__#1__groups_\clist_use:Nn \l_groupthm_groups_clist{_}}
}
{
\clist_clear:N \l_groupthm_groups_clist
#3
\__sort_group_names:
\end{__#1__groups_\clist_use:Nn \l_groupthm_groups_clist{_}}
}
}
% envname, name, thmtools
\cs_new:Npn \declare_theorem_variants:nnn #1 #2 #3
{