texlive[60222] Master/texmf-dist: projlib (11aug21)

commits+karl at tug.org commits+karl at tug.org
Wed Aug 11 22:16:28 CEST 2021


Revision: 60222
          http://tug.org/svn/texlive?view=revision&revision=60222
Author:   karl
Date:     2021-08-11 22:16:28 +0200 (Wed, 11 Aug 2021)
Log Message:
-----------
projlib (11aug21)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/latex/projlib/ProjLib-doc-cn.pdf
    trunk/Master/texmf-dist/doc/latex/projlib/ProjLib-doc-cn.tex
    trunk/Master/texmf-dist/doc/latex/projlib/ProjLib-doc-en.pdf
    trunk/Master/texmf-dist/doc/latex/projlib/ProjLib-doc-en.tex
    trunk/Master/texmf-dist/doc/latex/projlib/ProjLib-doc-fr.pdf
    trunk/Master/texmf-dist/doc/latex/projlib/ProjLib-doc-fr.tex
    trunk/Master/texmf-dist/source/latex/projlib/ProjLib-doc.dtx
    trunk/Master/texmf-dist/source/latex/projlib/ProjLib.dtx
    trunk/Master/texmf-dist/tex/latex/projlib/PJLauthor.sty
    trunk/Master/texmf-dist/tex/latex/projlib/PJLdate.sty
    trunk/Master/texmf-dist/tex/latex/projlib/PJLdraft.sty
    trunk/Master/texmf-dist/tex/latex/projlib/PJLlang.sty
    trunk/Master/texmf-dist/tex/latex/projlib/PJLlogo.sty
    trunk/Master/texmf-dist/tex/latex/projlib/PJLmath.sty
    trunk/Master/texmf-dist/tex/latex/projlib/PJLpaper.sty
    trunk/Master/texmf-dist/tex/latex/projlib/PJLthm.sty
    trunk/Master/texmf-dist/tex/latex/projlib/ProjLib.sty

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

Modified: trunk/Master/texmf-dist/doc/latex/projlib/ProjLib-doc-cn.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/projlib/ProjLib-doc-cn.tex	2021-08-11 20:16:11 UTC (rev 60221)
+++ trunk/Master/texmf-dist/doc/latex/projlib/ProjLib-doc-cn.tex	2021-08-11 20:16:28 UTC (rev 60222)
@@ -69,7 +69,6 @@
 %% Names
 %%================================
 \providecommand{\ProjLibPackage}{\mbox{\textsf{ProjLib}}}
-\providecommand{\PJLtoolkit}{\mbox{\textsf{PJLtoolkit}}}
 \providecommand{\PJLauthor}{\mbox{\textsf{PJLauthor}}}
 \providecommand{\PJLdatePackage}{\mbox{\textsf{PJLdate}}}
 \providecommand{\PJLdraft}{\mbox{\textsf{PJLdraft}}}
@@ -86,7 +85,7 @@
 
 \title{\ProjLib{} 工具集\\[.3\baselineskip]\normalsize 使用指南}
 \author{许锦文}
-\thanks{对应版本.~~\texttt{\ProjLib{}~2021/08/07a}}
+\thanks{对应版本.~~\texttt{\ProjLib{}~2021/08/11}}
 \email{\href{mailto:ProjLib at outlook.com}{ProjLib at outlook.com}}
 \date{2021年8月,北京}
 
@@ -261,7 +260,7 @@
             \item 字体选项。顾名思义,会加载相应名称的字体。
             \item \texttt{useosf} 选项用来启用“旧式”数字。
         \end{itemize}
-    \item \texttt{nothms}、\texttt{nothmnum}、\texttt{thmnum} 或 \texttt{thmnum=}\meta{counter}、\texttt{regionalref}、\texttt{originalref}
+    \item \texttt{nothms}、\texttt{delaythms}、\texttt{nothmnum}、\texttt{thmnum} 或 \texttt{thmnum=}\meta{counter}、\texttt{regionalref}、\texttt{originalref}
         \begin{itemize}
             \item 来自用于设置定理类环境的组件 \PJLthm{} 的选项,详细信息请参阅有关这一宏包的小节。
         \end{itemize}
@@ -370,9 +369,13 @@
     \begin{itemize}
         \item 不设定定理类环境。如果你希望使用自己的定理样式,可以使用这一选项。
     \end{itemize}
+    \item \texttt{delaythms}
+    \begin{itemize}
+        \item 将定理类环境设定推迟到导言结尾。如果你希望定理类环境跟随自定义计数器编号,则应考虑这一选项。
+    \end{itemize}
     \item \texttt{nothmnum}、\texttt{thmnum} 或 \texttt{thmnum=}\meta{counter}
     \begin{itemize}
-        \item 使定理类环境均不编号 / 按照 1、2、3 顺序编号 / 在 \meta{counter} 内编号。其中 \meta{counter} 应该是自带的计数器 (如 \texttt{subsection}) 或在导言部分自定义的计数器。在没有使用任何选项的情况下将按照 \texttt{chapter} (书) 或 \texttt{section} (文章) 编号。
+        \item 使定理类环境均不编号 / 按照 1、2、3 顺序编号 / 在 \meta{counter} 内编号。其中 \meta{counter} 应该是自带的计数器 (如 \texttt{subsection}) 或在导言部分自定义的计数器 (在启用 \texttt{delaythms} 选项的情况下)。在没有使用任何选项的情况下将按照 \texttt{chapter} (书) 或 \texttt{section} (文章) 编号。
     \end{itemize}
     \item \texttt{regionalref}、\texttt{originalref}
     \begin{itemize}
@@ -397,6 +400,7 @@
 \vspace{-.15\baselineskip}%
 其中,\meta{language name} 可参阅关于 \PJLlang{} 的小节。当不指定 \meta{language name}时,则会将该名称设置为所有支持语言下的名称。另外,带星号与不带星号的同名环境共用一个名称,因此 \lstinline|\NameTheorem{envname*}{...}| 与 \lstinline|\NameTheorem{envname}{...}| 效果相同。
 
+\bigskip
 然后用下面五种方式之一定义这一环境:
 \begin{itemize}
     \item \lstinline|\CreateTheorem*{|\meta{name of environment}\lstinline|}|
@@ -442,6 +446,7 @@
   \CreateTheorem*{proofidea*}
   \CreateTheorem{proofidea}<subsection>
 \end{code}
+\clearpage\noindent
 可以分别定义不编号的环境 \lstinline|proofidea*| 和编号的环境 \lstinline|proofidea| (在 subsection 内编号),它们支持在简体中文语境中使用,效果如下所示 (具体样式与所在的文档类有关) :
 
 \begin{proofidea*}

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

Modified: trunk/Master/texmf-dist/doc/latex/projlib/ProjLib-doc-en.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/projlib/ProjLib-doc-en.tex	2021-08-11 20:16:11 UTC (rev 60221)
+++ trunk/Master/texmf-dist/doc/latex/projlib/ProjLib-doc-en.tex	2021-08-11 20:16:28 UTC (rev 60222)
@@ -69,7 +69,6 @@
 %% Names
 %%================================
 \providecommand{\ProjLibPackage}{\mbox{\textsf{ProjLib}}}
-\providecommand{\PJLtoolkit}{\mbox{\textsf{PJLtoolkit}}}
 \providecommand{\PJLauthor}{\mbox{\textsf{PJLauthor}}}
 \providecommand{\PJLdatePackage}{\mbox{\textsf{PJLdate}}}
 \providecommand{\PJLdraft}{\mbox{\textsf{PJLdraft}}}
@@ -86,7 +85,7 @@
 
 \title{\ProjLib{}~\,Toolkit\\[.3\baselineskip]\normalsize User Manual}
 \author{Jinwen XU}
-\thanks{Corresponding to: \texttt{\ProjLib{}~2021/08/07a}}
+\thanks{Corresponding to: \texttt{\ProjLib{}~2021/08/11}}
 \email{\href{mailto:ProjLib at outlook.com}{ProjLib at outlook.com}}
 \date{August 2021, Beijing}
 
@@ -262,7 +261,7 @@
             \item Font options. As the names suggest, font with corresponding name will be loaded.
             \item The \texttt{useosf} option is used to enable the old-style figures.
         \end{itemize}
-    \item \texttt{nothms}, \texttt{nothmnum}, \texttt{thmnum} or \texttt{thmnum=}\meta{counter}, \texttt{regionalref}, \texttt{originalref}
+    \item \texttt{nothms}, \texttt{delaythms}, \texttt{nothmnum}, \texttt{thmnum} or \texttt{thmnum=}\meta{counter}, \texttt{regionalref}, \texttt{originalref}
         \begin{itemize}
             \item Options from the component \PJLthm{} used for setting theorem-like environments, please refer to the section on this package for details.
         \end{itemize}
@@ -281,7 +280,7 @@
 
 \section{The components}
 
-\subsection{Main function}
+\subsection{Main functions}
 
 \subsubsection{PJLauthor: enhanced author block}
 
@@ -368,9 +367,13 @@
     \begin{itemize}
         \item Theorem-like environments will not be defined. You may use this option if you wish to apply your own theorem styles.
     \end{itemize}
+    \item \texttt{delaythms}
+    \begin{itemize}
+        \item Defer the definition of theorem-like environments to the end of the preamble. Use this option if you want the theorem-like environments to be numbered within a custom counter.
+    \end{itemize}
     \item \texttt{nothmnum}, \texttt{thmnum} or \texttt{thmnum=}\meta{counter}
     \begin{itemize}
-        \item Theorem-like environments will not be numbered / numbered in order 1, 2, 3... / numbered within \meta{counter}. Here, \meta{counter} should be a built-in counter (such as \texttt{subsection}) or a custom counter defined in the preamble. If no option is used, they will be numbered within \texttt{chapter} (book) or \texttt{section} (article).
+        \item Theorem-like environments will not be numbered / numbered in order 1, 2, 3... / numbered within \meta{counter}. Here, \meta{counter} should be a built-in counter (such as \texttt{subsection}) or a custom counter defined in the preamble (with the option \texttt{delaythms} enabled). If no option is used, they will be numbered within \texttt{chapter} (book) or \texttt{section} (article).
     \end{itemize}
     \item \texttt{regionalref}, \texttt{originalref}
     \begin{itemize}
@@ -452,7 +455,7 @@
 
 \bigskip
 
-\subsection{Secondary function}
+\subsection{Secondary functions}
 
 \subsubsection{PJLdate: date-time processing}
 

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

Modified: trunk/Master/texmf-dist/doc/latex/projlib/ProjLib-doc-fr.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/projlib/ProjLib-doc-fr.tex	2021-08-11 20:16:11 UTC (rev 60221)
+++ trunk/Master/texmf-dist/doc/latex/projlib/ProjLib-doc-fr.tex	2021-08-11 20:16:28 UTC (rev 60222)
@@ -69,7 +69,6 @@
 %% Names
 %%================================
 \providecommand{\ProjLibPackage}{\mbox{\textsf{ProjLib}}}
-\providecommand{\PJLtoolkit}{\mbox{\textsf{PJLtoolkit}}}
 \providecommand{\PJLauthor}{\mbox{\textsf{PJLauthor}}}
 \providecommand{\PJLdatePackage}{\mbox{\textsf{PJLdate}}}
 \providecommand{\PJLdraft}{\mbox{\textsf{PJLdraft}}}
@@ -86,7 +85,7 @@
 
 \title{La boîte à outils~\,\ProjLib{}\\[.3\baselineskip]\normalsize Manuel d'utilisation}
 \author{Jinwen XU}
-\thanks{Correspondant à : \texttt{\ProjLib{}~2021/08/07a}}
+\thanks{Correspondant à : \texttt{\ProjLib{}~2021/08/11}}
 \email{\href{mailto:ProjLib at outlook.com}{ProjLib at outlook.com}}
 \date{Août 2021, à Pékin}
 
@@ -262,7 +261,7 @@
             \item Options de police. Comme les noms l'indiquent, la police avec le nom correspondant sera utilisée.
             \item L'option \texttt{useosf} est pour activer les chiffres à l'ancienne.
         \end{itemize}
-    \item \texttt{nothms}, \texttt{nothmnum}, \texttt{thmnum} ou \texttt{thmnum=}\meta{counter}, \texttt{regionalref}, \texttt{originalref}
+    \item \texttt{nothms}, \texttt{delaythms}, \texttt{nothmnum}, \texttt{thmnum} ou \texttt{thmnum=}\meta{counter}, \texttt{regionalref}, \texttt{originalref}
         \begin{itemize}
             \item Options du composant \PJLthm{} utilisé pour définir des environnements de type théorème, veuillez vous référer à la section sur ce package pour plus de détails.
         \end{itemize}
@@ -281,7 +280,7 @@
 
 \section{Les composants}
 
-\subsection{Fonction principale}
+\subsection{Fonctions principales}
 
 \subsubsection{PJLauthor : bloc auteur amélioré}
 
@@ -368,9 +367,13 @@
     \begin{itemize}
         \item Les environnements de type théorème ne seront pas définis. Vous pouvez utiliser cette option si vous souhaitez appliquer vos propres styles de théorème.
     \end{itemize}
+    \item \texttt{delaythms}
+    \begin{itemize}
+        \item Reportez la définition des environnements de type théorème à la fin du préambule. Utilisez cette option si vous souhaitez que les environnements soient numérotés dans un compteur personnalisé.
+    \end{itemize}
     \item \texttt{nothmnum}, \texttt{thmnum} ou \texttt{thmnum=}\meta{counter}
     \begin{itemize}
-        \item Les environnements de type théorème ne seront pas numérotés / numérotés dans l'ordre 1, 2, 3... / numérotés dans \meta{counter}. Ici, \meta{counter} doit être un compteur intégré (tel que \texttt{subsection}) ou un compteur défini dans le préambule. Si aucune option n'est utilisée, ils seront numérotés dans \texttt{chapter} (livre) ou \texttt{section} (article).
+        \item Les environnements de type théorème ne seront pas numérotés / numérotés dans l'ordre 1, 2, 3... / numérotés dans \meta{counter}. Ici, \meta{counter} doit être un compteur intégré (tel que \texttt{subsection}) ou un compteur défini dans le préambule (avec l'option \texttt{delaythms} activée). Si aucune option n'est utilisée, ils seront numérotés dans \texttt{chapter} (livre) ou \texttt{section} (article).
     \end{itemize}
     \item \texttt{regionalref}, \texttt{originalref}
     \begin{itemize}
@@ -398,19 +401,19 @@
 \begin{itemize}
     \item \lstinline|\CreateTheorem*{|\meta{name of environment}\lstinline|}|
         \begin{itemize}
-            \item Définir un environnement non numéroté \meta{name of environment}
+            \item Définir un environnement \meta{name of environment} non numéroté
         \end{itemize}
     \item \lstinline|\CreateTheorem{|\meta{name of environment}\lstinline|}|
         \begin{itemize}
-            \item Définir un environnement numéroté \meta{name of environment}, numéroté dans l'ordre 1, 2, 3, \dots
+            \item Définir un environnement \meta{name of environment} numéroté dans l'ordre 1, 2, 3, \dots
         \end{itemize}
     \item \lstinline|\CreateTheorem{|\meta{name of environment}\lstinline|}[|\meta{numbered like}\lstinline|]|
         \begin{itemize}
-            \item Définir un environnement numéroté \meta{name of environment}, qui partage le compteur \meta{numbered like}
+            \item Définir un environnement \meta{name of environment} numéroté, qui partage le compteur \meta{numbered like}
         \end{itemize}
     \item \lstinline|\CreateTheorem{|\meta{name of environment}\lstinline|}<|\meta{numbered within}\lstinline|>|
         \begin{itemize}
-            \item Définir un environnement numéroté \meta{name of environment}, numéroté dans le compteur \meta{numbered within}
+            \item Définir un environnement \meta{name of environment} numéroté dans le compteur \meta{numbered within}
         \end{itemize}
     \item \lstinline|\CreateTheorem{|\meta{name of environment}\lstinline|}(|\meta{existed environment}\lstinline|)|\\
     \lstinline|\CreateTheorem*{|\meta{name of environment}\lstinline|}(|\meta{existed environment}\lstinline|)|
@@ -451,7 +454,7 @@
 
 \bigskip
 
-\subsection{Fonction secondaire}
+\subsection{Fonctions secondaires}
 
 \subsubsection{PJLdate : traitement de date-heure}
 

Modified: trunk/Master/texmf-dist/source/latex/projlib/ProjLib-doc.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/projlib/ProjLib-doc.dtx	2021-08-11 20:16:11 UTC (rev 60221)
+++ trunk/Master/texmf-dist/source/latex/projlib/ProjLib-doc.dtx	2021-08-11 20:16:28 UTC (rev 60222)
@@ -90,7 +90,6 @@
 %% Names
 %%================================
 \providecommand{\ProjLibPackage}{\mbox{\textsf{ProjLib}}}
-\providecommand{\PJLtoolkit}{\mbox{\textsf{PJLtoolkit}}}
 \providecommand{\PJLauthor}{\mbox{\textsf{PJLauthor}}}
 \providecommand{\PJLdatePackage}{\mbox{\textsf{PJLdate}}}
 \providecommand{\PJLdraft}{\mbox{\textsf{PJLdraft}}}
@@ -108,7 +107,7 @@
 %<*ProjLib-doc-cn>
 \title{\ProjLib{} 工具集\\[.3\baselineskip]\normalsize 使用指南}
 \author{许锦文}
-\thanks{对应版本.~~\texttt{\ProjLib{}~2021/08/07a}}
+\thanks{对应版本.~~\texttt{\ProjLib{}~2021/08/11}}
 \email{\href{mailto:ProjLib at outlook.com}{ProjLib at outlook.com}}
 \date{2021年8月,北京}
 %</ProjLib-doc-cn>
@@ -116,7 +115,7 @@
 %<*ProjLib-doc-en>
 \title{\ProjLib{}~\,Toolkit\\[.3\baselineskip]\normalsize User Manual}
 \author{Jinwen XU}
-\thanks{Corresponding to: \texttt{\ProjLib{}~2021/08/07a}}
+\thanks{Corresponding to: \texttt{\ProjLib{}~2021/08/11}}
 \email{\href{mailto:ProjLib at outlook.com}{ProjLib at outlook.com}}
 \date{August 2021, Beijing}
 %</ProjLib-doc-en>
@@ -124,7 +123,7 @@
 %<*ProjLib-doc-fr>
 \title{La boîte à outils~\,\ProjLib{}\\[.3\baselineskip]\normalsize Manuel d'utilisation}
 \author{Jinwen XU}
-\thanks{Correspondant à : \texttt{\ProjLib{}~2021/08/07a}}
+\thanks{Correspondant à : \texttt{\ProjLib{}~2021/08/11}}
 \email{\href{mailto:ProjLib at outlook.com}{ProjLib at outlook.com}}
 \date{Août 2021, à Pékin}
 %</ProjLib-doc-fr>
@@ -600,7 +599,7 @@
             \item 字体选项。顾名思义,会加载相应名称的字体。
             \item \texttt{useosf} 选项用来启用“旧式”数字。
         \end{itemize}
-    \item \texttt{nothms}、\texttt{nothmnum}、\texttt{thmnum} 或 \texttt{thmnum=}\meta{counter}、\texttt{regionalref}、\texttt{originalref}
+    \item \texttt{nothms}、\texttt{delaythms}、\texttt{nothmnum}、\texttt{thmnum} 或 \texttt{thmnum=}\meta{counter}、\texttt{regionalref}、\texttt{originalref}
         \begin{itemize}
             \item 来自用于设置定理类环境的组件 \PJLthm{} 的选项,详细信息请参阅有关这一宏包的小节。
         \end{itemize}
@@ -630,7 +629,7 @@
             \item Font options. As the names suggest, font with corresponding name will be loaded. 
             \item The \texttt{useosf} option is used to enable the old-style figures.
         \end{itemize}
-    \item \texttt{nothms}, \texttt{nothmnum}, \texttt{thmnum} or \texttt{thmnum=}\meta{counter}, \texttt{regionalref}, \texttt{originalref}
+    \item \texttt{nothms}, \texttt{delaythms}, \texttt{nothmnum}, \texttt{thmnum} or \texttt{thmnum=}\meta{counter}, \texttt{regionalref}, \texttt{originalref}
         \begin{itemize}
             \item Options from the component \PJLthm{} used for setting theorem-like environments, please refer to the section on this package for details.
         \end{itemize}
@@ -660,7 +659,7 @@
             \item Options de police. Comme les noms l'indiquent, la police avec le nom correspondant sera utilisée.
             \item L'option \texttt{useosf} est pour activer les chiffres à l'ancienne.
         \end{itemize}
-    \item \texttt{nothms}, \texttt{nothmnum}, \texttt{thmnum} ou \texttt{thmnum=}\meta{counter}, \texttt{regionalref}, \texttt{originalref}
+    \item \texttt{nothms}, \texttt{delaythms}, \texttt{nothmnum}, \texttt{thmnum} ou \texttt{thmnum=}\meta{counter}, \texttt{regionalref}, \texttt{originalref}
         \begin{itemize}
             \item Options du composant \PJLthm{} utilisé pour définir des environnements de type théorème, veuillez vous référer à la section sur ce package pour plus de détails.
         \end{itemize}
@@ -697,11 +696,11 @@
 %</ProjLib-doc-cn>
 %
 %<*ProjLib-doc-en>
-\subsection{Main function}
+\subsection{Main functions}
 %</ProjLib-doc-en>
 %
 %<*ProjLib-doc-fr>
-\subsection{Fonction principale}
+\subsection{Fonctions principales}
 %</ProjLib-doc-fr>
 
 %<*ProjLib-doc-cn>
@@ -958,9 +957,13 @@
     \begin{itemize}
         \item 不设定定理类环境。如果你希望使用自己的定理样式,可以使用这一选项。
     \end{itemize}
+    \item \texttt{delaythms}
+    \begin{itemize}
+        \item 将定理类环境设定推迟到导言结尾。如果你希望定理类环境跟随自定义计数器编号,则应考虑这一选项。
+    \end{itemize}
     \item \texttt{nothmnum}、\texttt{thmnum} 或 \texttt{thmnum=}\meta{counter}
     \begin{itemize}
-        \item 使定理类环境均不编号 / 按照 1、2、3 顺序编号 / 在 \meta{counter} 内编号。其中 \meta{counter} 应该是自带的计数器 (如 \texttt{subsection}) 或在导言部分自定义的计数器。在没有使用任何选项的情况下将按照 \texttt{chapter} (书) 或 \texttt{section} (文章) 编号。
+        \item 使定理类环境均不编号 / 按照 1、2、3 顺序编号 / 在 \meta{counter} 内编号。其中 \meta{counter} 应该是自带的计数器 (如 \texttt{subsection}) 或在导言部分自定义的计数器 (在启用 \texttt{delaythms} 选项的情况下)。在没有使用任何选项的情况下将按照 \texttt{chapter} (书) 或 \texttt{section} (文章) 编号。
     \end{itemize}
     \item \texttt{regionalref}、\texttt{originalref}
     \begin{itemize}
@@ -995,6 +998,7 @@
 \vspace{-.15\baselineskip}%
 其中,\meta{language name} 可参阅关于 \PJLlang{} 的小节。当不指定 \meta{language name}时,则会将该名称设置为所有支持语言下的名称。另外,带星号与不带星号的同名环境共用一个名称,因此 \lstinline|\NameTheorem{envname*}{...}| 与 \lstinline|\NameTheorem{envname}{...}| 效果相同。
 
+\bigskip
 然后用下面五种方式之一定义这一环境:
 \begin{itemize}
     \item \lstinline|\CreateTheorem*{|\meta{name of environment}\lstinline|}|
@@ -1041,6 +1045,7 @@
   \CreateTheorem*{proofidea*}
   \CreateTheorem{proofidea}<subsection>
 \end{code}
+\clearpage\noindent
 可以分别定义不编号的环境 \lstinline|proofidea*| 和编号的环境 \lstinline|proofidea| (在 subsection 内编号),它们支持在简体中文语境中使用,效果如下所示 (具体样式与所在的文档类有关) :
 
 \begin{proofidea*}
@@ -1063,9 +1068,13 @@
     \begin{itemize}
         \item Theorem-like environments will not be defined. You may use this option if you wish to apply your own theorem styles.
     \end{itemize}
+    \item \texttt{delaythms}
+    \begin{itemize}
+        \item Defer the definition of theorem-like environments to the end of the preamble. Use this option if you want the theorem-like environments to be numbered within a custom counter.
+    \end{itemize}
     \item \texttt{nothmnum}, \texttt{thmnum} or \texttt{thmnum=}\meta{counter}
     \begin{itemize}
-        \item Theorem-like environments will not be numbered / numbered in order 1, 2, 3... / numbered within \meta{counter}. Here, \meta{counter} should be a built-in counter (such as \texttt{subsection}) or a custom counter defined in the preamble. If no option is used, they will be numbered within \texttt{chapter} (book) or \texttt{section} (article).
+        \item Theorem-like environments will not be numbered / numbered in order 1, 2, 3... / numbered within \meta{counter}. Here, \meta{counter} should be a built-in counter (such as \texttt{subsection}) or a custom counter defined in the preamble (with the option \texttt{delaythms} enabled). If no option is used, they will be numbered within \texttt{chapter} (book) or \texttt{section} (article).
     \end{itemize}
     \item \texttt{regionalref}, \texttt{originalref}
     \begin{itemize}
@@ -1170,9 +1179,13 @@
     \begin{itemize}
         \item Les environnements de type théorème ne seront pas définis. Vous pouvez utiliser cette option si vous souhaitez appliquer vos propres styles de théorème.
     \end{itemize}
+    \item \texttt{delaythms}
+    \begin{itemize}
+        \item Reportez la définition des environnements de type théorème à la fin du préambule. Utilisez cette option si vous souhaitez que les environnements soient numérotés dans un compteur personnalisé.
+    \end{itemize}
     \item \texttt{nothmnum}, \texttt{thmnum} ou \texttt{thmnum=}\meta{counter}
     \begin{itemize}
-        \item Les environnements de type théorème ne seront pas numérotés / numérotés dans l'ordre 1, 2, 3... / numérotés dans \meta{counter}. Ici, \meta{counter} doit être un compteur intégré (tel que \texttt{subsection}) ou un compteur défini dans le préambule. Si aucune option n'est utilisée, ils seront numérotés dans \texttt{chapter} (livre) ou \texttt{section} (article).
+        \item Les environnements de type théorème ne seront pas numérotés / numérotés dans l'ordre 1, 2, 3... / numérotés dans \meta{counter}. Ici, \meta{counter} doit être un compteur intégré (tel que \texttt{subsection}) ou un compteur défini dans le préambule (avec l'option \texttt{delaythms} activée). Si aucune option n'est utilisée, ils seront numérotés dans \texttt{chapter} (livre) ou \texttt{section} (article).
     \end{itemize}
     \item \texttt{regionalref}, \texttt{originalref}
     \begin{itemize}
@@ -1200,19 +1213,19 @@
 \begin{itemize}
     \item \lstinline|\CreateTheorem*{|\meta{name of environment}\lstinline|}|
         \begin{itemize}
-            \item Définir un environnement non numéroté \meta{name of environment}
+            \item Définir un environnement \meta{name of environment} non numéroté
         \end{itemize}
     \item \lstinline|\CreateTheorem{|\meta{name of environment}\lstinline|}|
         \begin{itemize}
-            \item Définir un environnement numéroté \meta{name of environment}, numéroté dans l'ordre 1, 2, 3, \dots
+            \item Définir un environnement \meta{name of environment} numéroté dans l'ordre 1, 2, 3, \dots
         \end{itemize}
     \item \lstinline|\CreateTheorem{|\meta{name of environment}\lstinline|}[|\meta{numbered like}\lstinline|]|
         \begin{itemize}
-            \item Définir un environnement numéroté \meta{name of environment}, qui partage le compteur \meta{numbered like}
+            \item Définir un environnement \meta{name of environment} numéroté, qui partage le compteur \meta{numbered like}
         \end{itemize}
     \item \lstinline|\CreateTheorem{|\meta{name of environment}\lstinline|}<|\meta{numbered within}\lstinline|>|
         \begin{itemize}
-            \item Définir un environnement numéroté \meta{name of environment}, numéroté dans le compteur \meta{numbered within}
+            \item Définir un environnement \meta{name of environment} numéroté dans le compteur \meta{numbered within}
         \end{itemize}
     \item \lstinline|\CreateTheorem{|\meta{name of environment}\lstinline|}(|\meta{existed environment}\lstinline|)|\\
     \lstinline|\CreateTheorem*{|\meta{name of environment}\lstinline|}(|\meta{existed environment}\lstinline|)|
@@ -1261,11 +1274,11 @@
 %</ProjLib-doc-cn>
 %
 %<*ProjLib-doc-en>
-\subsection{Secondary function}
+\subsection{Secondary functions}
 %</ProjLib-doc-en>
 %
 %<*ProjLib-doc-fr>
-\subsection{Fonction secondaire}
+\subsection{Fonctions secondaires}
 %</ProjLib-doc-fr>
 
 %<*ProjLib-doc-cn>

Modified: trunk/Master/texmf-dist/source/latex/projlib/ProjLib.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/projlib/ProjLib.dtx	2021-08-11 20:16:11 UTC (rev 60221)
+++ trunk/Master/texmf-dist/source/latex/projlib/ProjLib.dtx	2021-08-11 20:16:28 UTC (rev 60222)
@@ -18,47 +18,47 @@
 %
 %<*ProjLib>
 \ProvidesPackage{ProjLib}
-    [2021/08/07a The collective interface of ProjLib toolkit]
+    [2021/08/11 The collective interface of ProjLib toolkit]
 %</ProjLib>
 %
 %<*PJLauthor>
 \ProvidesPackage{PJLauthor}
-    [2021/08/07a Enhanced author information block]
+    [2021/08/11 Enhanced author information block]
 %</PJLauthor>
 %
 %<*PJLdate>
 \ProvidesPackage{PJLdate}
-    [2021/08/07a Convert yyyy-mm-dd to normal datetime format]
+    [2021/08/11 Convert yyyy-mm-dd to normal datetime format]
 %</PJLdate>
 %
 %<*PJLdraft>
 \ProvidesPackage{PJLdraft}
-    [2021/08/07a Some useful macros for the draft stage]
+    [2021/08/11 Some useful macros for the draft stage]
 %</PJLdraft>
 %
 %<*PJLlang>
 \ProvidesPackage{PJLlang}
-    [2021/08/07a Multi-language configuration]
+    [2021/08/11 Multi-language configuration]
 %</PJLlang>
 %
 %<*PJLlogo>
 \ProvidesPackage{PJLlogo}
-    [2021/08/07a The ProjLib logo]
+    [2021/08/11 The ProjLib logo]
 %</PJLlogo>
 %
 %<*PJLmath>
 \ProvidesPackage{PJLmath}
-    [2021/08/07a Useful math macros and shortcuts]
+    [2021/08/11 Useful math macros and shortcuts]
 %</PJLmath>
 %
 %<*PJLpaper>
 \ProvidesPackage{PJLpaper}
-    [2021/08/07a Paper style configuration]
+    [2021/08/11 Paper style configuration]
 %</PJLpaper>
 %
 %<*PJLthm>
 \ProvidesPackage{PJLthm}
-    [2021/08/07a Theorem setup and configuration]
+    [2021/08/11 Theorem setup and configuration]
 %</PJLthm>
 %
 %# 下面两行引入宏包的代码是所有文件共用的。
@@ -411,19 +411,19 @@
 \gappto{\PJLlang at langconfig@common}{%
     \let\@DTMdate\@DTMdate at PJLoriginal%
 }
-\gappto{\PJLlang at langconfig@schinese}{%
+\gappto{\PJLlang at langconfig@CN}{%
     \renewcommand*{\@DTMdate}[1]{%
     \expandafter\@dtm at parsedate#1\@dtm at endparsedate%
     \zhdate{\@dtm at year/\@dtm at month/\@dtm at day}%
     }%
 }
-\gappto{\PJLlang at langconfig@tchinese}{%
+\gappto{\PJLlang at langconfig@TC}{%
     \renewcommand*{\@DTMdate}[1]{%
     \expandafter\@dtm at parsedate#1\@dtm at endparsedate%
     \zhdate{\@dtm at year/\@dtm at month/\@dtm at day}%
     }%
 }
-\gappto{\PJLlang at langconfig@japanese}{%
+\gappto{\PJLlang at langconfig@JP}{%
     \renewcommand*{\@DTMdate}[1]{%
     \expandafter\@dtm at parsedate#1\@dtm at endparsedate%
     \zhdate{\@dtm at year/\@dtm at month/\@dtm at day}%
@@ -664,6 +664,77 @@
 \newcommand\japaneseABBR{JP}
 \newcommand\russianABBR{RU}
 
+%# 将字符串转换为相应的缩写
+%# Convert a string to the corresponding abbreviation
+\ExplSyntaxOn
+% See https://tex.stackexchange.com/a/610146
+\NewExpandableDocumentCommand{\StrToABBR}{m}
+ {
+  \str_case_e:nn { \str_foldcase:n { #1 } }
+   {
+        {cn}                    {CN}
+        {chinese}               {CN}
+        {schinese}              {CN}
+        {simplifiedchinese}     {CN}
+        {tc}                    {TC}
+        {tchinese}              {TC}
+        {traditionalchinese}    {TC}
+        {jp}                    {JP}
+        {japanese}              {JP}
+        {en}                    {EN}
+        {english}               {EN}
+        {fr}                    {FR}
+        {french}                {FR}
+        {de}                    {DE}
+        {ngerman}               {DE}
+        {it}                    {IT}
+        {italian}               {IT}
+        {pt}                    {PT}
+        {portuguese}            {PT}
+        {br}                    {BR}
+        {brazilian}             {BR}
+        {es}                    {ES}
+        {spanish}               {ES}
+        {german}                {DE}
+        {ru}                    {RU}
+        {russian}               {RU}
+   }
+ }
+
+\NewExpandableDocumentCommand{\StrToTYPE}{m}
+ {
+  \str_case_e:nn { \str_foldcase:n { #1 } }
+   {
+        {cn}                    {CJK}
+        {chinese}               {CJK}
+        {schinese}              {CJK}
+        {simplifiedchinese}     {CJK}
+        {tc}                    {CJK}
+        {tchinese}              {CJK}
+        {traditionalchinese}    {CJK}
+        {jp}                    {CJK}
+        {japanese}              {CJK}
+        {en}                    {Latin}
+        {english}               {Latin}
+        {fr}                    {Latin}
+        {french}                {Latin}
+        {de}                    {Latin}
+        {ngerman}               {Latin}
+        {it}                    {Latin}
+        {italian}               {Latin}
+        {pt}                    {Latin}
+        {portuguese}            {Latin}
+        {br}                    {Latin}
+        {brazilian}             {Latin}
+        {es}                    {Latin}
+        {spanish}               {Latin}
+        {german}                {Latin}
+        {ru}                    {Latin}
+        {russian}               {Latin}
+   }
+ }
+\ExplSyntaxOff
+
 %# 在 pdfLaTeX 编译时载入编码设置
 %# Load the encoding settings when pdfLaTeX is used
 \RequirePackage{iftex}
@@ -723,7 +794,7 @@
 
 %# 各个语言的设置
 %# The configuration for each language
-\newcommand{\PJLlang at langconfig@schinese}{%
+\newcommand{\PJLlang at langconfig@CN}{%
     \def\abstractname{摘要}%
     \def\proofname{证明}%
     \def\contentsname{目录}%
@@ -738,7 +809,7 @@
     \let\today\zhtoday%
     \renewcommand{\languagename}{schinese}%
 }
-\newcommand{\PJLlang at langconfig@tchinese}{%
+\newcommand{\PJLlang at langconfig@TC}{%
     \def\abstractname{摘要}%
     \def\proofname{證明}%
     \def\contentsname{目錄}%
@@ -753,72 +824,42 @@
     \let\today\zhtoday%
     \renewcommand{\languagename}{tchinese}%
 }
-\newcommand{\PJLlang at langconfig@japanese}{%
+\newcommand{\PJLlang at langconfig@JP}{%
     \selectlanguage{japanese}%
 }
-\newcommand{\PJLlang at langconfig@english}{%
+\newcommand{\PJLlang at langconfig@EN}{%
     \selectlanguage{english}%
 }
-\newcommand{\PJLlang at langconfig@french}{%
+\newcommand{\PJLlang at langconfig@FR}{%
     \selectlanguage{french}%
 % The line below is currently only needed for 'babel', but also works with 'polyglossia'
     \def\frenchpartname{Partie}%
 }
-\newcommand{\PJLlang at langconfig@german}{%
+\newcommand{\PJLlang at langconfig@DE}{%
     \selectlanguage{ngerman}%
 }
-\newcommand{\PJLlang at langconfig@italian}{%
+\newcommand{\PJLlang at langconfig@IT}{%
     \selectlanguage{italian}%
 }
-\newcommand{\PJLlang at langconfig@portuguese}{%
+\newcommand{\PJLlang at langconfig@PT}{%
     \selectlanguage{portuguese}%
 }
-\newcommand{\PJLlang at langconfig@brazilian}{%
+\newcommand{\PJLlang at langconfig@BR}{%
     \selectlanguage{brazilian}%
 }
-\newcommand{\PJLlang at langconfig@spanish}{%
+\newcommand{\PJLlang at langconfig@ES}{%
     \selectlanguage{spanish}%
 }
-\newcommand{\PJLlang at langconfig@russian}{%
+\newcommand{\PJLlang at langconfig@RU}{%
     \selectlanguage{russian}%
 }
 
 %# 用于增加语言设置的用户指令 AddLanguageSetting
 %# User command for adding language settings
-\RequirePackage{xstring}
 \NewDocumentCommand\AddLanguageSetting{d()m}{%
 \IfNoValueTF{#1}%
     {\gappto{\PJLlang at langconfig@common}{#2}}%
-    {%
-        \lowercase{\IfStrEqCase{#1}}{%
-            {cn}{\gappto{\PJLlang at langconfig@schinese}{#2}}%
-            {chinese}{\gappto{\PJLlang at langconfig@schinese}{#2}}%
-            {schinese}{\gappto{\PJLlang at langconfig@schinese}{#2}}%
-            {simplifiedchinese}{\gappto{\PJLlang at langconfig@schinese}{#2}}%
-            {tc}{\gappto{\PJLlang at langconfig@tchinese}{#2}}%
-            {tchinese}{\gappto{\PJLlang at langconfig@tchinese}{#2}}%
-            {traditionalchinese}{\gappto{\PJLlang at langconfig@tchinese}{#2}}%
-            {jp}{\gappto{\PJLlang at langconfig@japanese}{#2}}%
-            {japanese}{\gappto{\PJLlang at langconfig@japanese}{#2}}%
-            {en}{\gappto{\PJLlang at langconfig@english}{#2}}%
-            {english}{\gappto{\PJLlang at langconfig@english}{#2}}%
-            {fr}{\gappto{\PJLlang at langconfig@french}{#2}}%
-            {french}{\gappto{\PJLlang at langconfig@french}{#2}}%
-            {de}{\gappto{\PJLlang at langconfig@german}{#2}}%
-            {ngerman}{\gappto{\PJLlang at langconfig@german}{#2}}%
-            {it}{\gappto{\PJLlang at langconfig@italian}{#2}}%
-            {italian}{\gappto{\PJLlang at langconfig@italian}{#2}}%
-            {pt}{\gappto{\PJLlang at langconfig@portuguese}{#2}}%
-            {portuguese}{\gappto{\PJLlang at langconfig@portuguese}{#2}}%
-            {br}{\gappto{\PJLlang at langconfig@brazilian}{#2}}%
-            {brazilian}{\gappto{\PJLlang at langconfig@brazilian}{#2}}%
-            {es}{\gappto{\PJLlang at langconfig@spanish}{#2}}%
-            {spanish}{\gappto{\PJLlang at langconfig@spanish}{#2}}%
-            {german}{\gappto{\PJLlang at langconfig@german}{#2}}%
-            {ru}{\gappto{\PJLlang at langconfig@russian}{#2}}%
-            {russian}{\gappto{\PJLlang at langconfig@russian}{#2}}%
-        }%
-    }%
+    {\expandafter\gappto\expandafter{\csname PJLlang at langconfig@\StrToABBR{#1}\endcsname}{#2}}%
 }
 
 \RequirePackage{setspace}
@@ -841,40 +882,14 @@
 %
 %# UseLanguage 的核心部分,只能在正文中使用
 %# The core part of UseLanguage, can be used only in the main text, not preamble
-\newcommand{\UseLanguageCORE}[1]{%
+\NewDocumentCommand{\UseLanguageCORE}{m}{%
     \PJLlang at langconfig@common%
-    \lowercase{\IfStrEqCase{#1}}{%
-        {cn}{\PJL at config@CJK\PJLlang at langconfig@schinese}%
-        {chinese}{\PJL at config@CJK\PJLlang at langconfig@schinese}%
-        {schinese}{\PJL at config@CJK\PJLlang at langconfig@schinese}%
-        {simplifiedchinese}{\PJL at config@CJK\PJLlang at langconfig@schinese}%
-        {tc}{\PJL at config@CJK\PJLlang at langconfig@tchinese}%
-        {tchinese}{\PJL at config@CJK\PJLlang at langconfig@tchinese}%
-        {traditionalchinese}{\PJL at config@CJK\PJLlang at langconfig@tchinese}%
-        {jp}{\PJL at config@CJK\PJLlang at langconfig@japanese}%
-        {japanese}{\PJL at config@CJK\PJLlang at langconfig@japanese}%
-        {en}{\PJL at config@Latin\PJLlang at langconfig@english}%
-        {english}{\PJL at config@Latin\PJLlang at langconfig@english}%
-        {fr}{\PJL at config@Latin\PJLlang at langconfig@french}%
-        {french}{\PJL at config@Latin\PJLlang at langconfig@french}%
-        {de}{\PJL at config@Latin\PJLlang at langconfig@german}%
-        {ngerman}{\PJL at config@Latin\PJLlang at langconfig@german}%
-        {german}{\PJL at config@Latin\PJLlang at langconfig@german}%
-        {it}{\PJL at config@Latin\PJLlang at langconfig@italian}%
-        {italian}{\PJL at config@Latin\PJLlang at langconfig@italian}%
-        {pt}{\PJL at config@Latin\PJLlang at langconfig@portuguese}%
-        {portuguese}{\PJL at config@Latin\PJLlang at langconfig@portuguese}%
-        {br}{\PJL at config@Latin\PJLlang at langconfig@brazilian}%
-        {brazilian}{\PJL at config@Latin\PJLlang at langconfig@brazilian}%
-        {es}{\PJL at config@Latin\PJLlang at langconfig@spanish}%
-        {spanish}{\PJL at config@Latin\PJLlang at langconfig@spanish}%
-        {ru}{\PJL at config@Latin\PJLlang at langconfig@russian}%
-        {russian}{\PJL at config@Latin\PJLlang at langconfig@russian}%
-    }%
+    \csname PJL at config@\StrToTYPE{#1}\endcsname%
+    \csname PJLlang at langconfig@\StrToABBR{#1}\endcsname%
 }
 %# 用于选定语言的 UseLanguage
 %# Macro for selecting language
-\newcommand{\UseLanguage}[1]{%
+\NewDocumentCommand{\UseLanguage}{m}{%
     \ifx\@onlypreamble\@notprerr%
         \UseLanguageCORE{#1}%
     \else%
@@ -883,37 +898,10 @@
 }
 %# 用于局部选定语言的 UseOtherLanguage
 %# Macro for selecting language locally
-\newcommand{\UseOtherLanguage}[2]{%
+\NewDocumentCommand{\UseOtherLanguage}{mm}{%
 \begingroup\begingroup%
     \PJLlang at langconfig@common%
-    \lowercase{\IfStrEqCase{#1}}{%
-        {cn}{\PJLlang at langconfig@schinese}%
-        {chinese}{\PJLlang at langconfig@schinese}%
-        {schinese}{\PJLlang at langconfig@schinese}%
-        {simplifiedchinese}{\PJLlang at langconfig@schinese}%
-        {tc}{\PJLlang at langconfig@tchinese}%
-        {tchinese}{\PJLlang at langconfig@tchinese}%
-        {traditionalchinese}{\PJLlang at langconfig@tchinese}%
-        {jp}{\PJLlang at langconfig@japanese}%
-        {japanese}{\PJLlang at langconfig@japanese}%
-        {en}{\PJLlang at langconfig@english}%
-        {english}{\PJLlang at langconfig@english}%
-        {fr}{\PJLlang at langconfig@french}%
-        {french}{\PJLlang at langconfig@french}%
-        {de}{\PJLlang at langconfig@german}%
-        {ngerman}{\PJLlang at langconfig@german}%
-        {german}{\PJLlang at langconfig@german}%
-        {it}{\PJLlang at langconfig@italian}%
-        {italian}{\PJLlang at langconfig@italian}%
-        {pt}{\PJLlang at langconfig@portuguese}%
-        {portuguese}{\PJLlang at langconfig@portuguese}%
-        {br}{\PJLlang at langconfig@brazilian}%
-        {brazilian}{\PJLlang at langconfig@brazilian}%
-        {es}{\PJLlang at langconfig@spanish}%
-        {spanish}{\PJLlang at langconfig@spanish}%
-        {ru}{\PJLlang at langconfig@russian}%
-        {russian}{\PJLlang at langconfig@russian}%
-    }%
+    \csname PJLlang at langconfig@\StrToABBR{#1}\endcsname%
     #2%
 \endgroup\endgroup%
 }
@@ -920,19 +908,7 @@
 
 %# 运行默认语言的设置
 %# Execute the configuration of the main language
-\IfStrEqCase{\PJLlang at mainlang}{%
-    {EN}{\UseLanguage{EN}}%
-    {FR}{\UseLanguage{FR}}%
-    {DE}{\UseLanguage{DE}}%
-    {IT}{\UseLanguage{IT}}%
-    {PT}{\UseLanguage{PT}}%
-    {BR}{\UseLanguage{BR}}%
-    {ES}{\UseLanguage{ES}}%
-    {CN}{\UseLanguage{CN}}%
-    {TC}{\UseLanguage{TC}}%
-    {JP}{\UseLanguage{JP}}%
-    {RU}{\UseLanguage{RU}}%
-}
+\expandafter\UseLanguage\expandafter{\PJLlang at mainlang}
 %</PJLlang>
 %
 %<*PJLlogo>
@@ -1393,6 +1369,9 @@
 %# 不建立定理类环境
 %# Do not setup theorem-like environments
 \DeclareBoolOption[false]{nothms}
+%# 推迟建立定理类环境
+%# Delay the setup of theorem-like environments to the end of the preamble
+\DeclareBoolOption[false]{delaythms}
 %# 不编号定理类环境
 %# Do not number theorem-like environments
 \DeclareBoolOption[false]{nothmnum}
@@ -1436,34 +1415,8 @@
         \expandafter\StrGobbleRight\expandafter{\PJLthm at temp}{1}[\PJLthm at temp]%
     }{}%
     \IfValueTF{#1}{%
-        \lowercase{\IfStrEqCase{#1}}{%
-            {cn}{\def\PJL at temp@abbr{CN}}%
-            {chinese}{\def\PJL at temp@abbr{CN}}%
-            {schinese}{\def\PJL at temp@abbr{CN}}%
-            {simplifiedchinese}{\def\PJL at temp@abbr{CN}}%
-            {tc}{\def\PJL at temp@abbr{TC}}%
-            {tchinese}{\def\PJL at temp@abbr{TC}}%
-            {traditionalchinese}{\def\PJL at temp@abbr{TC}}%
-            {jp}{\def\PJL at temp@abbr{JP}}%
-            {japanese}{\def\PJL at temp@abbr{JP}}%
-            {en}{\def\PJL at temp@abbr{EN}}%
-            {english}{\def\PJL at temp@abbr{EN}}%
-            {fr}{\def\PJL at temp@abbr{FR}}%
-            {french}{\def\PJL at temp@abbr{FR}}%
-            {de}{\def\PJL at temp@abbr{DE}}%
-            {ngerman}{\def\PJL at temp@abbr{DE}}%
-            {german}{\def\PJL at temp@abbr{DE}}%
-            {it}{\def\PJL at temp@abbr{IT}}%
-            {italian}{\def\PJL at temp@abbr{IT}}%
-            {pt}{\def\PJL at temp@abbr{PT}}%
-            {portuguese}{\def\PJL at temp@abbr{PT}}%
-            {br}{\def\PJL at temp@abbr{BR}}%
-            {brazilian}{\def\PJL at temp@abbr{BR}}%
-            {es}{\def\PJL at temp@abbr{ES}}%
-            {spanish}{\def\PJL at temp@abbr{ES}}%
-            {ru}{\def\PJL at temp@abbr{RU}}%
-            {russian}{\def\PJL at temp@abbr{RU}}%
-        }%
+        \expandafter\def\expandafter\PJL at temp@abbr\expandafter%
+            {\expandafter\StrToABBR\expandafter{#1}}%
         \expandafter\def\csname\PJLthm at temp name\PJL at temp@abbr\endcsname{#3}%
     }{%
         \expandafter\def\csname\PJLthm at temp nameEN\endcsname{#3}%
@@ -1975,9 +1928,10 @@
         }
     }
 }
+
 %# 建立定理类环境
 %# Setup theorem-like environments
-\AtEndPreamble{
+\def\PJLthm at definethms{
 \if at PJLthm@nothms\else
 \if at PJLthm@nothmnum
 \CreateTheorem*{theorem}
@@ -2056,7 +2010,6 @@
 \CreateTheorem*{remark*}
 \CreateTheorem*{observation*}
 \fi
-}
 
 %# 按照 thmnum 决定公式如何编号
 %# Number the equations with respect to thmnum
@@ -2072,9 +2025,17 @@
     }
 }
 
+} % End of \PJLthm at definethms
+
+\if at PJLthm@delaythms
+    \AtEndPreamble{\PJLthm at definethms}
+\else
+    \PJLthm at definethms
+\fi
+
 %# 一些 cref 的本地化
 %# Some localization of cref
-\gappto{\PJLlang at langconfig@schinese}{%
+\gappto{\PJLlang at langconfig@CN}{%
     \crefname{equation}{式}{式}%
     \crefname{figure}{图}{图}%
     \crefname{table}{表}{表}%
@@ -2091,7 +2052,7 @@
     \def\creflastgroupconjunction{~和~}%
     \def\crefrangeconjunction{~}%
 }
-\gappto{\PJLlang at langconfig@tchinese}{%
+\gappto{\PJLlang at langconfig@TC}{%
     \crefname{equation}{式}{式}%
     \crefname{figure}{圖}{圖}%
     \crefname{table}{表}{表}%
@@ -2108,7 +2069,7 @@
     \def\creflastgroupconjunction{~與~}%
     \def\crefrangeconjunction{~}%
 }
-\gappto{\PJLlang at langconfig@japanese}{%
+\gappto{\PJLlang at langconfig@JP}{%
     \crefname{equation}{式}{式}%
     \crefname{figure}{図}{図}%
     \crefname{table}{表}{表}%
@@ -2125,7 +2086,7 @@
     \def\creflastgroupconjunction{~と~}%
     \def\crefrangeconjunction{〜}%
 }
-\gappto{\PJLlang at langconfig@russian}{%
+\gappto{\PJLlang at langconfig@RU}{%
     \crefname{equation}{уравнение}{уравнения}%
     \crefname{figure}{рис.}{рис.}%
     \crefname{table}{таблица}{таблицы}%
@@ -2142,7 +2103,7 @@
     \def\creflastgroupconjunction{~и~}%
     \def\crefrangeconjunction{~\textasciitilde~}%
 }
-\gappto{\PJLlang at langconfig@portuguese}{%
+\gappto{\PJLlang at langconfig@PT}{%
     \crefname{equation}{eq.}{eqs.}%
     \crefname{figure}{fig.}{figs.}%
     \crefname{table}{tabela}{tabelas}%
@@ -2173,6 +2134,7 @@
 \DeclareBoolOption[false]{author}
 \DeclareBoolOption[false]{amsfashion}
 \DeclareBoolOption[false]{nothms}
+\DeclareBoolOption[false]{delaythms}
 \DeclareBoolOption[false]{nothmnum}
 \DeclareStringOption{thmnum}[PJL at thmnum@default]
 \DeclareBoolOption[true]{regionalref}
@@ -2207,6 +2169,9 @@
 \if at ProjLib@nothms
     \PassOptionsToPackage{nothms}{PJLthm}
 \fi
+\if at ProjLib@delaythms
+    \PassOptionsToPackage{delaythms}{PJLthm}
+\fi
 \if at ProjLib@nothmnum
     \PassOptionsToPackage{nothmnum}{PJLthm}
 \fi

Modified: trunk/Master/texmf-dist/tex/latex/projlib/PJLauthor.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/projlib/PJLauthor.sty	2021-08-11 20:16:11 UTC (rev 60221)
+++ trunk/Master/texmf-dist/tex/latex/projlib/PJLauthor.sty	2021-08-11 20:16:28 UTC (rev 60222)
@@ -17,7 +17,7 @@
 %% 
 \NeedsTeXFormat{LaTeX2e}[2020-10-01]
 \ProvidesPackage{PJLauthor}
-    [2021/08/07a Enhanced author information block]
+    [2021/08/11 Enhanced author information block]
 \RequirePackage{kvoptions}
 \RequirePackage{etoolbox}
 \ifdefined\subjclass\endinput\fi

Modified: trunk/Master/texmf-dist/tex/latex/projlib/PJLdate.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/projlib/PJLdate.sty	2021-08-11 20:16:11 UTC (rev 60221)
+++ trunk/Master/texmf-dist/tex/latex/projlib/PJLdate.sty	2021-08-11 20:16:28 UTC (rev 60222)
@@ -17,7 +17,7 @@
 %% 
 \NeedsTeXFormat{LaTeX2e}[2020-10-01]
 \ProvidesPackage{PJLdate}
-    [2021/08/07a Convert yyyy-mm-dd to normal datetime format]
+    [2021/08/11 Convert yyyy-mm-dd to normal datetime format]
 \RequirePackage{kvoptions}
 \RequirePackage{etoolbox}
 \SetupKeyvalOptions{
@@ -47,19 +47,19 @@
 \gappto{\PJLlang at langconfig@common}{%
     \let\@DTMdate\@DTMdate at PJLoriginal%
 }
-\gappto{\PJLlang at langconfig@schinese}{%
+\gappto{\PJLlang at langconfig@CN}{%
     \renewcommand*{\@DTMdate}[1]{%
     \expandafter\@dtm at parsedate#1\@dtm at endparsedate%
     \zhdate{\@dtm at year/\@dtm at month/\@dtm at day}%
     }%
 }
-\gappto{\PJLlang at langconfig@tchinese}{%
+\gappto{\PJLlang at langconfig@TC}{%
     \renewcommand*{\@DTMdate}[1]{%
     \expandafter\@dtm at parsedate#1\@dtm at endparsedate%
     \zhdate{\@dtm at year/\@dtm at month/\@dtm at day}%
     }%
 }
-\gappto{\PJLlang at langconfig@japanese}{%
+\gappto{\PJLlang at langconfig@JP}{%
     \renewcommand*{\@DTMdate}[1]{%
     \expandafter\@dtm at parsedate#1\@dtm at endparsedate%
     \zhdate{\@dtm at year/\@dtm at month/\@dtm at day}%

Modified: trunk/Master/texmf-dist/tex/latex/projlib/PJLdraft.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/projlib/PJLdraft.sty	2021-08-11 20:16:11 UTC (rev 60221)
+++ trunk/Master/texmf-dist/tex/latex/projlib/PJLdraft.sty	2021-08-11 20:16:28 UTC (rev 60222)
@@ -17,7 +17,7 @@
 %% 
 \NeedsTeXFormat{LaTeX2e}[2020-10-01]
 \ProvidesPackage{PJLdraft}
-    [2021/08/07a Some useful macros for the draft stage]
+    [2021/08/11 Some useful macros for the draft stage]
 \RequirePackage{kvoptions}
 \RequirePackage{etoolbox}
 \SetupKeyvalOptions{

Modified: trunk/Master/texmf-dist/tex/latex/projlib/PJLlang.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/projlib/PJLlang.sty	2021-08-11 20:16:11 UTC (rev 60221)
+++ trunk/Master/texmf-dist/tex/latex/projlib/PJLlang.sty	2021-08-11 20:16:28 UTC (rev 60222)
@@ -17,7 +17,7 @@
 %% 
 \NeedsTeXFormat{LaTeX2e}[2020-10-01]
 \ProvidesPackage{PJLlang}
-    [2021/08/07a Multi-language configuration]
+    [2021/08/11 Multi-language configuration]
 \RequirePackage{kvoptions}
 \RequirePackage{etoolbox}
 \SetupKeyvalOptions{%
@@ -119,6 +119,74 @@
 \newcommand\japaneseABBR{JP}
 \newcommand\russianABBR{RU}
 
+\ExplSyntaxOn
+\NewExpandableDocumentCommand{\StrToABBR}{m}
+ {
+  \str_case_e:nn { \str_foldcase:n { #1 } }
+   {
+        {cn}                    {CN}
+        {chinese}               {CN}
+        {schinese}              {CN}
+        {simplifiedchinese}     {CN}
+        {tc}                    {TC}
+        {tchinese}              {TC}
+        {traditionalchinese}    {TC}
+        {jp}                    {JP}
+        {japanese}              {JP}
+        {en}                    {EN}
+        {english}               {EN}
+        {fr}                    {FR}
+        {french}                {FR}
+        {de}                    {DE}
+        {ngerman}               {DE}
+        {it}                    {IT}
+        {italian}               {IT}
+        {pt}                    {PT}
+        {portuguese}            {PT}
+        {br}                    {BR}
+        {brazilian}             {BR}
+        {es}                    {ES}
+        {spanish}               {ES}
+        {german}                {DE}
+        {ru}                    {RU}
+        {russian}               {RU}
+   }
+ }
+
+\NewExpandableDocumentCommand{\StrToTYPE}{m}
+ {
+  \str_case_e:nn { \str_foldcase:n { #1 } }
+   {
+        {cn}                    {CJK}
+        {chinese}               {CJK}
+        {schinese}              {CJK}
+        {simplifiedchinese}     {CJK}
+        {tc}                    {CJK}
+        {tchinese}              {CJK}
+        {traditionalchinese}    {CJK}
+        {jp}                    {CJK}
+        {japanese}              {CJK}
+        {en}                    {Latin}
+        {english}               {Latin}
+        {fr}                    {Latin}
+        {french}                {Latin}
+        {de}                    {Latin}
+        {ngerman}               {Latin}
+        {it}                    {Latin}
+        {italian}               {Latin}
+        {pt}                    {Latin}
+        {portuguese}            {Latin}
+        {br}                    {Latin}
+        {brazilian}             {Latin}
+        {es}                    {Latin}
+        {spanish}               {Latin}
+        {german}                {Latin}
+        {ru}                    {Latin}
+        {russian}               {Latin}
+   }
+ }
+\ExplSyntaxOff
+
 \RequirePackage{iftex}
 \ifPDFTeX
 \RequirePackage[T1]{fontenc}
@@ -168,7 +236,7 @@
     \fi%
 }
 
-\newcommand{\PJLlang at langconfig@schinese}{%
+\newcommand{\PJLlang at langconfig@CN}{%
     \def\abstractname{摘要}%
     \def\proofname{证明}%
     \def\contentsname{目录}%
@@ -183,7 +251,7 @@
     \let\today\zhtoday%
     \renewcommand{\languagename}{schinese}%
 }
-\newcommand{\PJLlang at langconfig@tchinese}{%
+\newcommand{\PJLlang at langconfig@TC}{%
     \def\abstractname{摘要}%
     \def\proofname{證明}%
     \def\contentsname{目錄}%
@@ -198,69 +266,39 @@
     \let\today\zhtoday%
     \renewcommand{\languagename}{tchinese}%
 }
-\newcommand{\PJLlang at langconfig@japanese}{%
+\newcommand{\PJLlang at langconfig@JP}{%
     \selectlanguage{japanese}%
 }
-\newcommand{\PJLlang at langconfig@english}{%
+\newcommand{\PJLlang at langconfig@EN}{%
     \selectlanguage{english}%
 }
-\newcommand{\PJLlang at langconfig@french}{%
+\newcommand{\PJLlang at langconfig@FR}{%
     \selectlanguage{french}%
     \def\frenchpartname{Partie}%
 }
-\newcommand{\PJLlang at langconfig@german}{%
+\newcommand{\PJLlang at langconfig@DE}{%
     \selectlanguage{ngerman}%
 }
-\newcommand{\PJLlang at langconfig@italian}{%
+\newcommand{\PJLlang at langconfig@IT}{%
     \selectlanguage{italian}%
 }
-\newcommand{\PJLlang at langconfig@portuguese}{%
+\newcommand{\PJLlang at langconfig@PT}{%
     \selectlanguage{portuguese}%
 }
-\newcommand{\PJLlang at langconfig@brazilian}{%
+\newcommand{\PJLlang at langconfig@BR}{%
     \selectlanguage{brazilian}%
 }
-\newcommand{\PJLlang at langconfig@spanish}{%
+\newcommand{\PJLlang at langconfig@ES}{%
     \selectlanguage{spanish}%
 }
-\newcommand{\PJLlang at langconfig@russian}{%
+\newcommand{\PJLlang at langconfig@RU}{%
     \selectlanguage{russian}%
 }
 
-\RequirePackage{xstring}
 \NewDocumentCommand\AddLanguageSetting{d()m}{%
 \IfNoValueTF{#1}%
     {\gappto{\PJLlang at langconfig@common}{#2}}%
-    {%
-        \lowercase{\IfStrEqCase{#1}}{%
-            {cn}{\gappto{\PJLlang at langconfig@schinese}{#2}}%
-            {chinese}{\gappto{\PJLlang at langconfig@schinese}{#2}}%
-            {schinese}{\gappto{\PJLlang at langconfig@schinese}{#2}}%
-            {simplifiedchinese}{\gappto{\PJLlang at langconfig@schinese}{#2}}%
-            {tc}{\gappto{\PJLlang at langconfig@tchinese}{#2}}%
-            {tchinese}{\gappto{\PJLlang at langconfig@tchinese}{#2}}%
-            {traditionalchinese}{\gappto{\PJLlang at langconfig@tchinese}{#2}}%
-            {jp}{\gappto{\PJLlang at langconfig@japanese}{#2}}%
-            {japanese}{\gappto{\PJLlang at langconfig@japanese}{#2}}%
-            {en}{\gappto{\PJLlang at langconfig@english}{#2}}%
-            {english}{\gappto{\PJLlang at langconfig@english}{#2}}%
-            {fr}{\gappto{\PJLlang at langconfig@french}{#2}}%
-            {french}{\gappto{\PJLlang at langconfig@french}{#2}}%
-            {de}{\gappto{\PJLlang at langconfig@german}{#2}}%
-            {ngerman}{\gappto{\PJLlang at langconfig@german}{#2}}%
-            {it}{\gappto{\PJLlang at langconfig@italian}{#2}}%
-            {italian}{\gappto{\PJLlang at langconfig@italian}{#2}}%
-            {pt}{\gappto{\PJLlang at langconfig@portuguese}{#2}}%
-            {portuguese}{\gappto{\PJLlang at langconfig@portuguese}{#2}}%
-            {br}{\gappto{\PJLlang at langconfig@brazilian}{#2}}%
-            {brazilian}{\gappto{\PJLlang at langconfig@brazilian}{#2}}%
-            {es}{\gappto{\PJLlang at langconfig@spanish}{#2}}%
-            {spanish}{\gappto{\PJLlang at langconfig@spanish}{#2}}%
-            {german}{\gappto{\PJLlang at langconfig@german}{#2}}%
-            {ru}{\gappto{\PJLlang at langconfig@russian}{#2}}%
-            {russian}{\gappto{\PJLlang at langconfig@russian}{#2}}%
-        }%
-    }%
+    {\expandafter\gappto\expandafter{\csname PJLlang at langconfig@\StrToABBR{#1}\endcsname}{#2}}%
 }
 
 \RequirePackage{setspace}
@@ -274,38 +312,12 @@
 \newcommand{\PJLsetCJKparindent}[1]{\renewcommand{\PJL at config@CJKparindent}{\ltx at ifpackageloaded{parskip}{}{\setlength{\parindent}{#1}}}}
 \def\PJL at config@CJK{\PJL at config@CJKlinespacing\PJL at config@CJKparindent}
 \def\PJL at config@Latin{\PJL at config@linespacing\PJL at config@parindent}
-\newcommand{\UseLanguageCORE}[1]{%
+\NewDocumentCommand{\UseLanguageCORE}{m}{%
     \PJLlang at langconfig@common%
-    \lowercase{\IfStrEqCase{#1}}{%
-        {cn}{\PJL at config@CJK\PJLlang at langconfig@schinese}%
-        {chinese}{\PJL at config@CJK\PJLlang at langconfig@schinese}%
-        {schinese}{\PJL at config@CJK\PJLlang at langconfig@schinese}%
-        {simplifiedchinese}{\PJL at config@CJK\PJLlang at langconfig@schinese}%
-        {tc}{\PJL at config@CJK\PJLlang at langconfig@tchinese}%
-        {tchinese}{\PJL at config@CJK\PJLlang at langconfig@tchinese}%
-        {traditionalchinese}{\PJL at config@CJK\PJLlang at langconfig@tchinese}%
-        {jp}{\PJL at config@CJK\PJLlang at langconfig@japanese}%
-        {japanese}{\PJL at config@CJK\PJLlang at langconfig@japanese}%
-        {en}{\PJL at config@Latin\PJLlang at langconfig@english}%
-        {english}{\PJL at config@Latin\PJLlang at langconfig@english}%
-        {fr}{\PJL at config@Latin\PJLlang at langconfig@french}%
-        {french}{\PJL at config@Latin\PJLlang at langconfig@french}%
-        {de}{\PJL at config@Latin\PJLlang at langconfig@german}%
-        {ngerman}{\PJL at config@Latin\PJLlang at langconfig@german}%
-        {german}{\PJL at config@Latin\PJLlang at langconfig@german}%
-        {it}{\PJL at config@Latin\PJLlang at langconfig@italian}%
-        {italian}{\PJL at config@Latin\PJLlang at langconfig@italian}%
-        {pt}{\PJL at config@Latin\PJLlang at langconfig@portuguese}%
-        {portuguese}{\PJL at config@Latin\PJLlang at langconfig@portuguese}%
-        {br}{\PJL at config@Latin\PJLlang at langconfig@brazilian}%
-        {brazilian}{\PJL at config@Latin\PJLlang at langconfig@brazilian}%
-        {es}{\PJL at config@Latin\PJLlang at langconfig@spanish}%
-        {spanish}{\PJL at config@Latin\PJLlang at langconfig@spanish}%
-        {ru}{\PJL at config@Latin\PJLlang at langconfig@russian}%
-        {russian}{\PJL at config@Latin\PJLlang at langconfig@russian}%
-    }%
+    \csname PJL at config@\StrToTYPE{#1}\endcsname%
+    \csname PJLlang at langconfig@\StrToABBR{#1}\endcsname%
 }
-\newcommand{\UseLanguage}[1]{%
+\NewDocumentCommand{\UseLanguage}{m}{%
     \ifx\@onlypreamble\@notprerr%
         \UseLanguageCORE{#1}%
     \else%
@@ -312,54 +324,15 @@
         \AfterEndPreamble{\UseLanguageCORE{#1}}%
     \fi%
 }
-\newcommand{\UseOtherLanguage}[2]{%
+\NewDocumentCommand{\UseOtherLanguage}{mm}{%
 \begingroup\begingroup%
     \PJLlang at langconfig@common%
-    \lowercase{\IfStrEqCase{#1}}{%
-        {cn}{\PJLlang at langconfig@schinese}%
-        {chinese}{\PJLlang at langconfig@schinese}%
-        {schinese}{\PJLlang at langconfig@schinese}%
-        {simplifiedchinese}{\PJLlang at langconfig@schinese}%
-        {tc}{\PJLlang at langconfig@tchinese}%
-        {tchinese}{\PJLlang at langconfig@tchinese}%
-        {traditionalchinese}{\PJLlang at langconfig@tchinese}%
-        {jp}{\PJLlang at langconfig@japanese}%
-        {japanese}{\PJLlang at langconfig@japanese}%
-        {en}{\PJLlang at langconfig@english}%
-        {english}{\PJLlang at langconfig@english}%
-        {fr}{\PJLlang at langconfig@french}%
-        {french}{\PJLlang at langconfig@french}%
-        {de}{\PJLlang at langconfig@german}%
-        {ngerman}{\PJLlang at langconfig@german}%
-        {german}{\PJLlang at langconfig@german}%
-        {it}{\PJLlang at langconfig@italian}%
-        {italian}{\PJLlang at langconfig@italian}%
-        {pt}{\PJLlang at langconfig@portuguese}%
-        {portuguese}{\PJLlang at langconfig@portuguese}%
-        {br}{\PJLlang at langconfig@brazilian}%
-        {brazilian}{\PJLlang at langconfig@brazilian}%
-        {es}{\PJLlang at langconfig@spanish}%
-        {spanish}{\PJLlang at langconfig@spanish}%
-        {ru}{\PJLlang at langconfig@russian}%
-        {russian}{\PJLlang at langconfig@russian}%
-    }%
+    \csname PJLlang at langconfig@\StrToABBR{#1}\endcsname%
     #2%
 \endgroup\endgroup%
 }
 
-\IfStrEqCase{\PJLlang at mainlang}{%
-    {EN}{\UseLanguage{EN}}%
-    {FR}{\UseLanguage{FR}}%
-    {DE}{\UseLanguage{DE}}%
-    {IT}{\UseLanguage{IT}}%
-    {PT}{\UseLanguage{PT}}%
-    {BR}{\UseLanguage{BR}}%
-    {ES}{\UseLanguage{ES}}%
-    {CN}{\UseLanguage{CN}}%
-    {TC}{\UseLanguage{TC}}%
-    {JP}{\UseLanguage{JP}}%
-    {RU}{\UseLanguage{RU}}%
-}
+\expandafter\UseLanguage\expandafter{\PJLlang at mainlang}
 
 \endinput
 %%

Modified: trunk/Master/texmf-dist/tex/latex/projlib/PJLlogo.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/projlib/PJLlogo.sty	2021-08-11 20:16:11 UTC (rev 60221)
+++ trunk/Master/texmf-dist/tex/latex/projlib/PJLlogo.sty	2021-08-11 20:16:28 UTC (rev 60222)
@@ -17,7 +17,7 @@
 %% 
 \NeedsTeXFormat{LaTeX2e}[2020-10-01]
 \ProvidesPackage{PJLlogo}
-    [2021/08/07a The ProjLib logo]
+    [2021/08/11 The ProjLib logo]
 \RequirePackage{kvoptions}
 \RequirePackage{etoolbox}
 \SetupKeyvalOptions{

Modified: trunk/Master/texmf-dist/tex/latex/projlib/PJLmath.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/projlib/PJLmath.sty	2021-08-11 20:16:11 UTC (rev 60221)
+++ trunk/Master/texmf-dist/tex/latex/projlib/PJLmath.sty	2021-08-11 20:16:28 UTC (rev 60222)
@@ -17,7 +17,7 @@
 %% 
 \NeedsTeXFormat{LaTeX2e}[2020-10-01]
 \ProvidesPackage{PJLmath}
-    [2021/08/07a Useful math macros and shortcuts]
+    [2021/08/11 Useful math macros and shortcuts]
 \RequirePackage{kvoptions}
 \RequirePackage{etoolbox}
 \RequirePackage{mathtools}

Modified: trunk/Master/texmf-dist/tex/latex/projlib/PJLpaper.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/projlib/PJLpaper.sty	2021-08-11 20:16:11 UTC (rev 60221)
+++ trunk/Master/texmf-dist/tex/latex/projlib/PJLpaper.sty	2021-08-11 20:16:28 UTC (rev 60222)
@@ -17,7 +17,7 @@
 %% 
 \NeedsTeXFormat{LaTeX2e}[2020-10-01]
 \ProvidesPackage{PJLpaper}
-    [2021/08/07a Paper style configuration]
+    [2021/08/11 Paper style configuration]
 \RequirePackage{kvoptions}
 \RequirePackage{etoolbox}
 \RequirePackage{ifthen}

Modified: trunk/Master/texmf-dist/tex/latex/projlib/PJLthm.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/projlib/PJLthm.sty	2021-08-11 20:16:11 UTC (rev 60221)
+++ trunk/Master/texmf-dist/tex/latex/projlib/PJLthm.sty	2021-08-11 20:16:28 UTC (rev 60222)
@@ -17,7 +17,7 @@
 %% 
 \NeedsTeXFormat{LaTeX2e}[2020-10-01]
 \ProvidesPackage{PJLthm}
-    [2021/08/07a Theorem setup and configuration]
+    [2021/08/11 Theorem setup and configuration]
 \RequirePackage{kvoptions}
 \RequirePackage{etoolbox}
 \SetupKeyvalOptions{%
@@ -25,6 +25,7 @@
     prefix = @PJLthm@
 }
 \DeclareBoolOption[false]{nothms}
+\DeclareBoolOption[false]{delaythms}
 \DeclareBoolOption[false]{nothmnum}
 \DeclareStringOption{thmnum}[PJL at thmnum@default]
 \DeclareBoolOption[false]{draft}
@@ -54,34 +55,8 @@
         \expandafter\StrGobbleRight\expandafter{\PJLthm at temp}{1}[\PJLthm at temp]%
     }{}%
     \IfValueTF{#1}{%
-        \lowercase{\IfStrEqCase{#1}}{%
-            {cn}{\def\PJL at temp@abbr{CN}}%
-            {chinese}{\def\PJL at temp@abbr{CN}}%
-            {schinese}{\def\PJL at temp@abbr{CN}}%
-            {simplifiedchinese}{\def\PJL at temp@abbr{CN}}%
-            {tc}{\def\PJL at temp@abbr{TC}}%
-            {tchinese}{\def\PJL at temp@abbr{TC}}%
-            {traditionalchinese}{\def\PJL at temp@abbr{TC}}%
-            {jp}{\def\PJL at temp@abbr{JP}}%
-            {japanese}{\def\PJL at temp@abbr{JP}}%
-            {en}{\def\PJL at temp@abbr{EN}}%
-            {english}{\def\PJL at temp@abbr{EN}}%
-            {fr}{\def\PJL at temp@abbr{FR}}%
-            {french}{\def\PJL at temp@abbr{FR}}%
-            {de}{\def\PJL at temp@abbr{DE}}%
-            {ngerman}{\def\PJL at temp@abbr{DE}}%
-            {german}{\def\PJL at temp@abbr{DE}}%
-            {it}{\def\PJL at temp@abbr{IT}}%
-            {italian}{\def\PJL at temp@abbr{IT}}%
-            {pt}{\def\PJL at temp@abbr{PT}}%
-            {portuguese}{\def\PJL at temp@abbr{PT}}%
-            {br}{\def\PJL at temp@abbr{BR}}%
-            {brazilian}{\def\PJL at temp@abbr{BR}}%
-            {es}{\def\PJL at temp@abbr{ES}}%
-            {spanish}{\def\PJL at temp@abbr{ES}}%
-            {ru}{\def\PJL at temp@abbr{RU}}%
-            {russian}{\def\PJL at temp@abbr{RU}}%
-        }%
+        \expandafter\def\expandafter\PJL at temp@abbr\expandafter%
+            {\expandafter\StrToABBR\expandafter{#1}}%
         \expandafter\def\csname\PJLthm at temp name\PJL at temp@abbr\endcsname{#3}%
     }{%
         \expandafter\def\csname\PJLthm at temp nameEN\endcsname{#3}%
@@ -524,7 +499,8 @@
         }
     }
 }
-\AtEndPreamble{
+
+\def\PJLthm at definethms{
 \if at PJLthm@nothms\else
 \if at PJLthm@nothmnum
 \CreateTheorem*{theorem}
@@ -603,7 +579,6 @@
 \CreateTheorem*{remark*}
 \CreateTheorem*{observation*}
 \fi
-}
 
 \expandafter\ifstrempty\expandafter{\@PJLthm at thmnum}{
     \numberwithin{equation}{PJLthm at highest}
@@ -614,7 +589,15 @@
     }
 }
 
-\gappto{\PJLlang at langconfig@schinese}{%
+} % End of \PJLthm at definethms
+
+\if at PJLthm@delaythms
+    \AtEndPreamble{\PJLthm at definethms}
+\else
+    \PJLthm at definethms
+\fi
+
+\gappto{\PJLlang at langconfig@CN}{%
     \crefname{equation}{式}{式}%
     \crefname{figure}{图}{图}%
     \crefname{table}{表}{表}%
@@ -631,7 +614,7 @@
     \def\creflastgroupconjunction{~和~}%
     \def\crefrangeconjunction{~}%
 }
-\gappto{\PJLlang at langconfig@tchinese}{%
+\gappto{\PJLlang at langconfig@TC}{%
     \crefname{equation}{式}{式}%
     \crefname{figure}{圖}{圖}%
     \crefname{table}{表}{表}%
@@ -648,7 +631,7 @@
     \def\creflastgroupconjunction{~與~}%
     \def\crefrangeconjunction{~}%
 }
-\gappto{\PJLlang at langconfig@japanese}{%
+\gappto{\PJLlang at langconfig@JP}{%
     \crefname{equation}{式}{式}%
     \crefname{figure}{図}{図}%
     \crefname{table}{表}{表}%
@@ -665,7 +648,7 @@
     \def\creflastgroupconjunction{~と~}%
     \def\crefrangeconjunction{〜}%
 }
-\gappto{\PJLlang at langconfig@russian}{%
+\gappto{\PJLlang at langconfig@RU}{%
     \crefname{equation}{уравнение}{уравнения}%
     \crefname{figure}{рис.}{рис.}%
     \crefname{table}{таблица}{таблицы}%
@@ -682,7 +665,7 @@
     \def\creflastgroupconjunction{~и~}%
     \def\crefrangeconjunction{~\textasciitilde~}%
 }
-\gappto{\PJLlang at langconfig@portuguese}{%
+\gappto{\PJLlang at langconfig@PT}{%
     \crefname{equation}{eq.}{eqs.}%
     \crefname{figure}{fig.}{figs.}%
     \crefname{table}{tabela}{tabelas}%

Modified: trunk/Master/texmf-dist/tex/latex/projlib/ProjLib.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/projlib/ProjLib.sty	2021-08-11 20:16:11 UTC (rev 60221)
+++ trunk/Master/texmf-dist/tex/latex/projlib/ProjLib.sty	2021-08-11 20:16:28 UTC (rev 60222)
@@ -17,7 +17,7 @@
 %% 
 \NeedsTeXFormat{LaTeX2e}[2020-10-01]
 \ProvidesPackage{ProjLib}
-    [2021/08/07a The collective interface of ProjLib toolkit]
+    [2021/08/11 The collective interface of ProjLib toolkit]
 \RequirePackage{kvoptions}
 \RequirePackage{etoolbox}
 \SetupKeyvalOptions{
@@ -29,6 +29,7 @@
 \DeclareBoolOption[false]{author}
 \DeclareBoolOption[false]{amsfashion}
 \DeclareBoolOption[false]{nothms}
+\DeclareBoolOption[false]{delaythms}
 \DeclareBoolOption[false]{nothmnum}
 \DeclareStringOption{thmnum}[PJL at thmnum@default]
 \DeclareBoolOption[true]{regionalref}
@@ -57,6 +58,9 @@
 \if at ProjLib@nothms
     \PassOptionsToPackage{nothms}{PJLthm}
 \fi
+\if at ProjLib@delaythms
+    \PassOptionsToPackage{delaythms}{PJLthm}
+\fi
 \if at ProjLib@nothmnum
     \PassOptionsToPackage{nothmnum}{PJLthm}
 \fi



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