texlive[61276] Master/texmf-dist: easybook (11dec21)

commits+karl at tug.org commits+karl at tug.org
Sat Dec 11 22:18:38 CET 2021


Revision: 61276
          http://tug.org/svn/texlive?view=revision&revision=61276
Author:   karl
Date:     2021-12-11 22:18:38 +0100 (Sat, 11 Dec 2021)
Log Message:
-----------
easybook (11dec21)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/latex/easybook/easybook.pdf
    trunk/Master/texmf-dist/doc/latex/easybook/easybook.tex
    trunk/Master/texmf-dist/source/latex/easybook/easybook.dtx
    trunk/Master/texmf-dist/tex/latex/easybook/easybase.sty
    trunk/Master/texmf-dist/tex/latex/easybook/easybook.cls
    trunk/Master/texmf-dist/tex/latex/easybook/eb-tcolorbox.cfg

Modified: trunk/Master/texmf-dist/doc/latex/easybook/easybook.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/doc/latex/easybook/easybook.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/easybook/easybook.tex	2021-12-11 21:18:22 UTC (rev 61275)
+++ trunk/Master/texmf-dist/doc/latex/easybook/easybook.tex	2021-12-11 21:18:38 UTC (rev 61276)
@@ -20,8 +20,8 @@
     name            = easybook,
     color-scheme    = blue,
     title           = EASYBOOK 使用手册,
-    version         = v1.41O,
-    date            = 2021/12/10,
+    version         = v1.41P,
+    date            = 2021/12/11,
     authors         = 瞿毅,
     info            = 排版简体中文学位论文和书籍,
     email           = q1jx at foxmail.com,
@@ -593,7 +593,7 @@
 文档类已预置 12 个定理环境,环境名及对应的定理名见小节 \ref{subsec:theorem},它们均使用预置的定理样式 \code{eb-theorem}。下面 \module*{thmset} 模块选项的用法名称与 \pkg*{thmtools} 宏包基本一致,且仅对预置定理样式生效。如果下面的选项不满足需求,可使用支持完整选项的相关命令创建定理环境。
 \begin{options}
   \keybool{thmframe}\Module{thmset}\Default{false}
-  给定理环境使用彩色盒子。这个特殊选项在本模块中使用 \pkg*{tcolorbox} 宏包来支持,\meta{盒子风格} 默认为 \code{tc-theorem}。\pkg*{thmtools} 具有类似的选项 \option*{thmbox},可在新建定理样式的命令中使用。
+  给定理环境使用彩色盒子。这个特殊选项在本模块中使用 \pkg*{tcolorbox} 宏包来支持,\meta{盒子风格} 默认为 \code{tc-theorem}。注意它应当在定理声明命令前使用。\pkg*{thmtools} 具有类似的选项 \option*{thmbox}。
   \keyval-{headfont}{字体命令}\Default{\cs*{color}\Carg{ctex at emph}\cs*{sffamily}}
   定理标题部分的字体,包括字体族、字体系列、字体尺寸和字体形状命令。
   \keyval-{notefont}{字体命令}\Default
@@ -1052,8 +1052,8 @@
   \end{options}
   \command{setexerlist}[\marg{键值列表3}]
   命令 \cs{setexerlist} 用于全局设置习题条目选项 \meta{键值列表3} 的值。\meta{键值列表3} 的选项与 \pkg*{enumitem} 的排序列表相同,也可以使用下述 \option{enumitem} 选项,不过第一个选项无法是短编号形式,这被 \option{number} 选项代替。
-  \command{exerprologue}[\marg{序言内容}]
-  序言命令 \cs{exerprologue} 在习题环境开始前插入一段内容,可以是文本或者代码,需要在每一个习题环境前使用。
+  \command{exerprologue}[\sarg\marg{序言内容}]
+  序言命令 \cs{exerprologue} 在习题环境开始前插入一段内容,可以是文本或者代码,需要在每一个习题环境前使用。带有星号参数的命令会使序言在习题环境一直有效。
   \command{tcphantomifname}[\marg{编号代码}\marg{不编号代码}]
   命令 \cs{tcphantomifname} 根据使用 \pkg*{tcolorbox} 生成的习题标题是否编号,在超链接锚点的位置加入代码,比如使用 \cs*{addcontentsline} 命令将习题标题加入目录。
 \end{commands}

Modified: trunk/Master/texmf-dist/source/latex/easybook/easybook.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/easybook/easybook.dtx	2021-12-11 21:18:22 UTC (rev 61275)
+++ trunk/Master/texmf-dist/source/latex/easybook/easybook.dtx	2021-12-11 21:18:38 UTC (rev 61276)
@@ -15,7 +15,7 @@
 %<*class>
 \NeedsTeXFormat{LaTeX2e}[2020/10/01]
 \RequirePackage{l3keys2e}
-\ProvidesExplClass{easybook}{2021/12/10}{1.41O}
+\ProvidesExplClass{easybook}{2021/12/11}{1.41P}
   {Typeset Chinese theses or books}
 
 \bool_set_false:N \l__eb_compile_draft_bool
@@ -309,7 +309,7 @@
 %<*package>
 \NeedsTeXFormat{LaTeX2e}[2020/10/01]
 \RequirePackage{l3keys2e,etoolbox}
-\ProvidesExplPackage{easybase}{2021/12/10}{1.41O}
+\ProvidesExplPackage{easybase}{2021/12/11}{1.41P}
   {Typeset Chinese theses or books}
 
 \cs_generate_variant:Nn \dim_set:Nn { NV }
@@ -1957,8 +1957,8 @@
 \cs_new_protected:Npn \eb_thm_biname_set:nnn #1#2#3
   {
     \tl_if_eq:NnTF \l__ctex_scheme_tl { chinese }
-      { \tl_set:cn { c__eb_thm_biname_#1_tl } {#3} }
-      { \tl_set:cn { c__eb_thm_biname_#1_tl } {#2} }
+      { \tl_set:cn { l__eb_thm_biname_#1_tl } {#3} }
+      { \tl_set:cn { l__eb_thm_biname_#1_tl } {#2} }
   }
 \cs_set_eq:NN \eb at declaretheorem@save \declaretheorem
 \cs_set_eq:NN \eb at declaretheoremsyle@save \declaretheoremstyle
@@ -1982,12 +1982,18 @@
       }
     \eb_thm_biname_set:nnn {#1} {#2} {#3}
     \declaretheorem{#1}[
-      name  = \tl_use:c { c__eb_thm_biname_#1_tl },
+      name  = \tl_use:c { l__eb_thm_biname_#1_tl },
       style = eb-theorem,#5
       ]
     \eb_if_thmframe_with_tcolorbox:TF
-      { \tcolorboxenvironment{#1}{#4} } { }
-    \labelformat{#1}{\tl_use:c { c__eb_thm_biname_#1_tl }~##1}
+      {
+        \bool_if_exist:cTF { l__eb_tcb_repeat_env_#1_bool }
+          { \bool_set_true:c { l__eb_tcb_repeat_env_#1_bool } }
+          { \bool_set_false:c { l__eb_tcb_repeat_env_#1_bool } }
+        \bool_if:cF { l__eb_tcb_repeat_env_#1_bool }
+          { \tcolorboxenvironment{#1}{#4} }
+      } { }
+    \labelformat{#1}{\tl_use:c { l__eb_thm_biname_#1_tl }~##1}
   }
 
 \prop_new:N \l__eb_thmtools_entry_prop
@@ -2051,18 +2057,18 @@
     \c__eb_thmtools_entry_clist { notebraces = \l__eb_thm_notebraces_tl }
     \exp_last_unbraced:NNV
     \declaretheoremstyle[\c__eb_thmtools_entry_clist]{eb-theorem}
-    \deftheorem{lemma}{引理}
-    \deftheorem{axiom}{公理}
-    \deftheorem{example}{例}
-    \deftheorem{problem}{问题}
-    \deftheorem{theorem}{定理}
-    \deftheorem{corollary}{推论}
+    \deftheorem{proof}{证明}[numbered = no,qed = \qedsymbol]
+    \deftheorem{remark}{注}[numbered = no]
+    \deftheorem{proposition}{性质}
     \deftheorem{assumption}{假设}
     \deftheorem{conjecture}{猜想}
     \deftheorem{definition}{定义}
-    \deftheorem{proposition}{性质}
-    \deftheorem{remark}{注}[numbered = no]
-    \deftheorem{proof}{证明}[numbered = no,qed = \qedsymbol]
+    \deftheorem{corollary}{推论}
+    \deftheorem{problem}{问题}
+    \deftheorem{theorem}{定理}
+    \deftheorem{example}{例}
+    \deftheorem{axiom}{公理}
+    \deftheorem{lemma}{引理}
   }
 
 \setchemformula
@@ -2433,7 +2439,7 @@
   }
 %</package>
 %<*tcolorbox>
-\ProvidesExplFile{eb-tcolorbox.cfg}{2021/12/10}{1.41O}
+\ProvidesExplFile{eb-tcolorbox.cfg}{2021/12/11}{1.41P}
   {Customization of tcolorbox for easybook}
 
 \cs_set_protected:Npn \setexercise #1
@@ -2542,9 +2548,16 @@
 
 \tl_new:N \p at eb@exercise
 \tl_new:N \eb at tc@list at prologue
-\cs_new:Npn \exerprologue #1 { \tl_gset:Nn \eb at tc@list at prologue {#1} }
-\cs_new:Npn \tcphantomifname #1#2
+\bool_gset_true:N \g__eb_exer_clear_prologue_bool
+\NewDocumentCommand{\exerprologue}{sm}
   {
+    \IfBooleanTF{#1}
+      {\bool_gset_false:N \g__eb_exer_clear_prologue_bool}
+      {\bool_gset_true:N \g__eb_exer_clear_prologue_bool}
+    \tl_gset:Nn \eb at tc@list at prologue {#2}
+  }
+\cs_new_protected:Npn \tcphantomifname #1#2
+  {
     \tl_gset:Nn \eb at tc@exercise at ifnametrue {#1}
     \tl_gset:Nn \eb at tc@exercise at ifnamefalse {#2}
   }
@@ -2561,7 +2574,7 @@
         \eb at tc@exercise at title
       }
   }{}
-\cs_set:Npn \eb_exercise_label_noempty_use:
+\cs_new:Npn \eb_exercise_label_noempty_use:
   {
     \eb_current_label:n { eb at exercise }
     \tl_if_empty:NF \eb at tc@exercise at label
@@ -2613,7 +2626,8 @@
     \begin{eb at exercise@list}[\eb at tc@list at number,#5]
       #6
     \end{eb at exercise@list}
-    \tl_gclear:N \eb at tc@list at prologue
+    \bool_if:NT \g__eb_exer_clear_prologue_bool
+      { \tl_gclear:N \eb at tc@list at prologue }
   }{}
 \DeclareTColorBox{easybox}{sO{Khaki}d()O{}}
   {

Modified: trunk/Master/texmf-dist/tex/latex/easybook/easybase.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/easybook/easybase.sty	2021-12-11 21:18:22 UTC (rev 61275)
+++ trunk/Master/texmf-dist/tex/latex/easybook/easybase.sty	2021-12-11 21:18:38 UTC (rev 61276)
@@ -20,7 +20,7 @@
 %% This work has the LPPL maintenance status `maintained'.
 \NeedsTeXFormat{LaTeX2e}[2020/10/01]
 \RequirePackage{l3keys2e,etoolbox}
-\ProvidesExplPackage{easybase}{2021/12/10}{1.41O}
+\ProvidesExplPackage{easybase}{2021/12/11}{1.41P}
   {Typeset Chinese theses or books}
 
 \cs_generate_variant:Nn \dim_set:Nn { NV }
@@ -1668,8 +1668,8 @@
 \cs_new_protected:Npn \eb_thm_biname_set:nnn #1#2#3
   {
     \tl_if_eq:NnTF \l__ctex_scheme_tl { chinese }
-      { \tl_set:cn { c__eb_thm_biname_#1_tl } {#3} }
-      { \tl_set:cn { c__eb_thm_biname_#1_tl } {#2} }
+      { \tl_set:cn { l__eb_thm_biname_#1_tl } {#3} }
+      { \tl_set:cn { l__eb_thm_biname_#1_tl } {#2} }
   }
 \cs_set_eq:NN \eb at declaretheorem@save \declaretheorem
 \cs_set_eq:NN \eb at declaretheoremsyle@save \declaretheoremstyle
@@ -1693,12 +1693,18 @@
       }
     \eb_thm_biname_set:nnn {#1} {#2} {#3}
     \declaretheorem{#1}[
-      name  = \tl_use:c { c__eb_thm_biname_#1_tl },
+      name  = \tl_use:c { l__eb_thm_biname_#1_tl },
       style = eb-theorem,#5
       ]
     \eb_if_thmframe_with_tcolorbox:TF
-      { \tcolorboxenvironment{#1}{#4} } { }
-    \labelformat{#1}{\tl_use:c { c__eb_thm_biname_#1_tl }~##1}
+      {
+        \bool_if_exist:cTF { l__eb_tcb_repeat_env_#1_bool }
+          { \bool_set_true:c { l__eb_tcb_repeat_env_#1_bool } }
+          { \bool_set_false:c { l__eb_tcb_repeat_env_#1_bool } }
+        \bool_if:cF { l__eb_tcb_repeat_env_#1_bool }
+          { \tcolorboxenvironment{#1}{#4} }
+      } { }
+    \labelformat{#1}{\tl_use:c { l__eb_thm_biname_#1_tl }~##1}
   }
 
 \prop_new:N \l__eb_thmtools_entry_prop
@@ -1762,18 +1768,18 @@
     \c__eb_thmtools_entry_clist { notebraces = \l__eb_thm_notebraces_tl }
     \exp_last_unbraced:NNV
     \declaretheoremstyle[\c__eb_thmtools_entry_clist]{eb-theorem}
-    \deftheorem{lemma}{引理}
-    \deftheorem{axiom}{公理}
-    \deftheorem{example}{例}
-    \deftheorem{problem}{问题}
-    \deftheorem{theorem}{定理}
-    \deftheorem{corollary}{推论}
+    \deftheorem{proof}{证明}[numbered = no,qed = \qedsymbol]
+    \deftheorem{remark}{注}[numbered = no]
+    \deftheorem{proposition}{性质}
     \deftheorem{assumption}{假设}
     \deftheorem{conjecture}{猜想}
     \deftheorem{definition}{定义}
-    \deftheorem{proposition}{性质}
-    \deftheorem{remark}{注}[numbered = no]
-    \deftheorem{proof}{证明}[numbered = no,qed = \qedsymbol]
+    \deftheorem{corollary}{推论}
+    \deftheorem{problem}{问题}
+    \deftheorem{theorem}{定理}
+    \deftheorem{example}{例}
+    \deftheorem{axiom}{公理}
+    \deftheorem{lemma}{引理}
   }
 
 \setchemformula

Modified: trunk/Master/texmf-dist/tex/latex/easybook/easybook.cls
===================================================================
--- trunk/Master/texmf-dist/tex/latex/easybook/easybook.cls	2021-12-11 21:18:22 UTC (rev 61275)
+++ trunk/Master/texmf-dist/tex/latex/easybook/easybook.cls	2021-12-11 21:18:38 UTC (rev 61276)
@@ -20,7 +20,7 @@
 %% This work has the LPPL maintenance status `maintained'.
 \NeedsTeXFormat{LaTeX2e}[2020/10/01]
 \RequirePackage{l3keys2e}
-\ProvidesExplClass{easybook}{2021/12/10}{1.41O}
+\ProvidesExplClass{easybook}{2021/12/11}{1.41P}
   {Typeset Chinese theses or books}
 
 \bool_set_false:N \l__eb_compile_draft_bool

Modified: trunk/Master/texmf-dist/tex/latex/easybook/eb-tcolorbox.cfg
===================================================================
--- trunk/Master/texmf-dist/tex/latex/easybook/eb-tcolorbox.cfg	2021-12-11 21:18:22 UTC (rev 61275)
+++ trunk/Master/texmf-dist/tex/latex/easybook/eb-tcolorbox.cfg	2021-12-11 21:18:38 UTC (rev 61276)
@@ -18,7 +18,7 @@
 %% LaTeX version 2005/12/01 or later.
 %% 
 %% This work has the LPPL maintenance status `maintained'.
-\ProvidesExplFile{eb-tcolorbox.cfg}{2021/12/10}{1.41O}
+\ProvidesExplFile{eb-tcolorbox.cfg}{2021/12/11}{1.41P}
   {Customization of tcolorbox for easybook}
 
 \cs_set_protected:Npn \setexercise #1
@@ -127,9 +127,16 @@
 
 \tl_new:N \p at eb@exercise
 \tl_new:N \eb at tc@list at prologue
-\cs_new:Npn \exerprologue #1 { \tl_gset:Nn \eb at tc@list at prologue {#1} }
-\cs_new:Npn \tcphantomifname #1#2
+\bool_gset_true:N \g__eb_exer_clear_prologue_bool
+\NewDocumentCommand{\exerprologue}{sm}
   {
+    \IfBooleanTF{#1}
+      {\bool_gset_false:N \g__eb_exer_clear_prologue_bool}
+      {\bool_gset_true:N \g__eb_exer_clear_prologue_bool}
+    \tl_gset:Nn \eb at tc@list at prologue {#2}
+  }
+\cs_new_protected:Npn \tcphantomifname #1#2
+  {
     \tl_gset:Nn \eb at tc@exercise at ifnametrue {#1}
     \tl_gset:Nn \eb at tc@exercise at ifnamefalse {#2}
   }
@@ -146,7 +153,7 @@
         \eb at tc@exercise at title
       }
   }{}
-\cs_set:Npn \eb_exercise_label_noempty_use:
+\cs_new:Npn \eb_exercise_label_noempty_use:
   {
     \eb_current_label:n { eb at exercise }
     \tl_if_empty:NF \eb at tc@exercise at label
@@ -198,7 +205,8 @@
     \begin{eb at exercise@list}[\eb at tc@list at number,#5]
       #6
     \end{eb at exercise@list}
-    \tl_gclear:N \eb at tc@list at prologue
+    \bool_if:NT \g__eb_exer_clear_prologue_bool
+      { \tl_gclear:N \eb at tc@list at prologue }
   }{}
 \DeclareTColorBox{easybox}{sO{Khaki}d()O{}}
   {



More information about the tex-live-commits mailing list.