From b0b871a84bd57524b8aa6ff2562148b111741af2 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Wed, 1 Jun 2022 20:04:27 +0000 Subject: create-theorem (1jun22) git-svn-id: svn://tug.org/texlive/trunk@63466 c570f23f-e606-0410-a88d-b1316a301751 --- .../tex/latex/create-theorem/create-theorem.sty | 22 +++++++++++++--------- 1 file changed, 13 insertions(+), 9 deletions(-) (limited to 'Master/texmf-dist/tex') diff --git a/Master/texmf-dist/tex/latex/create-theorem/create-theorem.sty b/Master/texmf-dist/tex/latex/create-theorem/create-theorem.sty index c41908646c0..35b07ffd323 100644 --- a/Master/texmf-dist/tex/latex/create-theorem/create-theorem.sty +++ b/Master/texmf-dist/tex/latex/create-theorem/create-theorem.sty @@ -13,7 +13,7 @@ \RequirePackage{l3keys2e} \ProvidesExplPackage {create-theorem} - {2022/05/31} {} + {2022/06/01} {} {Initializing theorem-like environments with multilingual support} \keys_define:nn { create-theorem } @@ -39,11 +39,6 @@ } \ProcessKeysOptions { create-theorem } -\hook_gput_code:nnn { package/thmtools/after } { crthm } - { - \let\thmt@autorefsetup\relax - } - \RequirePackage { aliascnt } \bool_if:NT \l__crthm_nameinlink_bool @@ -54,6 +49,15 @@ \RequirePackage { crefthe } +\IfPackageLoadedTF { thmtools } + { + \cs_gset_eq:NN \crthm_newtheorem:w \thmt@original@newtheorem + } + { + \cs_gset_eq:NN \crthm_newtheorem:w \newtheorem + } + + % Users should consider appending their languages to this list as needed, % otherwise the naming functionality may not work in monolingual documents. \clist_new:N \g_crthm_supported_language_clist @@ -813,10 +817,10 @@ } \bool_if:NTF \l__crthm_creating_numberless_bool { - \newtheorem*{ #1 _crthm_regional } { \tl_use:c { g_crthm_name_heading_ #1 _ \languagename _tl } } + \crthm_newtheorem:w*{ #1 _crthm_regional } { \tl_use:c { g_crthm_name_heading_ #1 _ \languagename _tl } } } { - \newtheorem { #1 _crthm_regional } [#1] { \tl_use:c { g_crthm_name_heading_ #1 _ \languagename _tl } } + \crthm_newtheorem:w { #1 _crthm_regional } [#1] { \tl_use:c { g_crthm_name_heading_ #1 _ \languagename _tl } } } \group_end: \NewDocumentEnvironment { #1 } { O{} } @@ -841,7 +845,7 @@ } \bool_if:NT \l__crthm_creating_create_starred_bool { - \newtheorem*{ #1 * } { \tl_use:c { g_crthm_name_heading_ #1 _ \languagename _tl } } + \crthm_newtheorem:w*{ #1 * } { \tl_use:c { g_crthm_name_heading_ #1 _ \languagename _tl } } } \keys_set:nn { create-theorem-creating / counter-management } { #2 } } -- cgit v1.2.3