fix bugs in thmtools option not being set properly
This commit is contained in:
parent
ed41616c4a
commit
d609b54aac
2 changed files with 23 additions and 19 deletions
|
@ -83,7 +83,7 @@ __HEADER__(Grouping theorems for easier customization.)
|
|||
mapname .clist_set:N = \l_groupthm_mapname_clist,
|
||||
mapname .default:n = {},
|
||||
mapname .groups:n = { theoremgroup },
|
||||
thmtools .clist_set:N = \l_groupthm_thmtools_clist,
|
||||
thmtools .clist_set:N = \l_groupthm_key_thmtools_clist,
|
||||
thmtools .default:n = {},
|
||||
thmtools .groups:n = { theoremgroup, groupedtheorem, theoremvariants },
|
||||
unknown .code:n = \msg_error:nnn { groupthm } { unknown ~ group } { \l_keys_key_str }
|
||||
|
@ -133,8 +133,8 @@ __HEADER__(Grouping theorems for easier customization.)
|
|||
\new_theorem_group:nVVVV { #1 }
|
||||
\l_groupthm_key_prename_tl
|
||||
\l_groupthm_key_postname_tl
|
||||
\l_groupthm_mapname_clist
|
||||
\l_groupthm_thmtools_clist
|
||||
\l_groupthm_key_mapname_clist
|
||||
\l_groupthm_key_thmtools_clist
|
||||
}
|
||||
|
||||
\NewDocumentCommand{\NewTheoremGroup}{ O{} m }
|
||||
|
@ -233,7 +233,6 @@ __HEADER__(Grouping theorems for easier customization.)
|
|||
}
|
||||
|
||||
|
||||
|
||||
%% Rules for different theorem groups
|
||||
|
||||
\cs_generate_variant:Nn \hook_gset_rule:nnnn { n n V n }
|
||||
|
@ -263,9 +262,6 @@ __HEADER__(Grouping theorems for easier customization.)
|
|||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
%%% Hacks for sorting groupnames
|
||||
|
||||
\cs_new:Npn \__add_to_sort_hook:n #1
|
||||
|
@ -279,17 +275,10 @@ __HEADER__(Grouping theorems for easier customization.)
|
|||
|
||||
\cs_new:Npn \__sort_group_names:
|
||||
{
|
||||
|
||||
% \tl_show:n { sorting}
|
||||
% \clist_show:N \l_groupthm_group_clist
|
||||
|
||||
\hook_gremove_code:nn { groupthm / groupsort }{*}
|
||||
\clist_map_function:NN \l_groupthm_group_clist \__add_to_sort_hook:n
|
||||
\clist_clear:N \l_groupthm_group_clist
|
||||
% \ShowHook { groupthm / groupsort }
|
||||
\hook_use:n { groupthm / groupsort }
|
||||
|
||||
% \clist_show:N \l_groupthm_group_clist
|
||||
}
|
||||
|
||||
|
||||
|
@ -305,9 +294,6 @@ __HEADER__(Grouping theorems for easier customization.)
|
|||
{
|
||||
\__sort_group_names:
|
||||
|
||||
% \tl_show:n { Generating new theorem variant }
|
||||
% \clist_show:N \l_groupthm_group_clist
|
||||
|
||||
\new_grouped_theorem:xVnn
|
||||
{__#1__groups_\clist_use:Nn \l_groupthm_group_clist {_}}
|
||||
\l_groupthm_group_clist
|
||||
|
@ -336,7 +322,6 @@ __HEADER__(Grouping theorems for easier customization.)
|
|||
}
|
||||
|
||||
\clist_set_eq:NN \l_groupthm_group_clist \l_groupthm_key_group_clist
|
||||
|
||||
\clist_put_left:Nn \l_groupthm_group_clist { starred }
|
||||
|
||||
\generate_theorem_variants:nVVV
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
\documentclass{article}
|
||||
|
||||
\usepackage[enable-debug]{expl3}
|
||||
\usepackage[default styles]{mkessler-thmstyle}
|
||||
|
||||
\ExplSyntaxOn
|
||||
\debug_on:n { all }
|
||||
|
@ -8,7 +9,25 @@
|
|||
|
||||
\usepackage{mkessler-groupthm}
|
||||
|
||||
\GenerateTheoremVariants[ group = {star, dagger} ]{example}
|
||||
\mdfdefinestyle{green}{
|
||||
linecolor=green,
|
||||
linewidth = 2pt,
|
||||
leftmargin = 0cm,
|
||||
rightmargin=0cm,
|
||||
rightline=false,
|
||||
topline=false,
|
||||
bottomline=false
|
||||
}
|
||||
|
||||
\declaretheoremstyle[
|
||||
mdframed={style=green}
|
||||
]{green}
|
||||
|
||||
\GenerateTheoremVariants
|
||||
[
|
||||
group = {star, dagger},
|
||||
thmtools = { style = thmgreenmargin }
|
||||
]{example}
|
||||
|
||||
\DeclareTheoremVariants{example} { !s !t+ }
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue