[latex3-commits] [git/LaTeX3-latex3-latex2e] gh963: update teh news entry (9ac734a0)

Frank Mittelbach frank.mittelbach at latex-project.org
Tue Nov 29 00:36:43 CET 2022


Repository : https://github.com/latex3/latex2e
On branch  : gh963
Link       : https://github.com/latex3/latex2e/commit/9ac734a0523a06f4278b5d989bbc8905f21aea22

>---------------------------------------------------------------

commit 9ac734a0523a06f4278b5d989bbc8905f21aea22
Author: Frank Mittelbach <frank.mittelbach at latex-project.org>
Date:   Tue Nov 29 00:36:43 2022 +0100

    update teh news entry


>---------------------------------------------------------------

9ac734a0523a06f4278b5d989bbc8905f21aea22
 base/doc/ltnews37.tex | 43 ++++++++++++++++++++++++++++++++-----------
 1 file changed, 32 insertions(+), 11 deletions(-)

diff --git a/base/doc/ltnews37.tex b/base/doc/ltnews37.tex
index b40cee00..ed564933 100644
--- a/base/doc/ltnews37.tex
+++ b/base/doc/ltnews37.tex
@@ -146,8 +146,39 @@
 
 \section{New or improved commands}
 
+
+
+\subsection{Providing copy and show functions for environments}
+
+To copy a command definition we have introduced \cs{NewCommandCopy} in
+2022.  This allows you to copy even that consist of several internal
+components, such as robust commands or those with a complex signature.
+To do the same with environments, e.g., to define the environment
+\env{myitemize} to be equivalent to \env{itemize}, you can now write
+\begin{verbatim}
+  \NewEnvironmentCopy{myitemize}{itemize}
+\end{verbatim}
+There are also \cs{Renew...}\ and \cs{Declare...}, which may be useful
+depending on the circumstances.
+
+In addition, we offer a \cs{ShowEnvironment} command, which displays the
+\cs{begin} and \cs{end} code of the environment passed as an
+argument. E.g., \verb=\ShowEnvironment{center}= results in the
+following output:
+\begin{verbatim}
+  > \begin{center}=environment:
+  > ->\trivlist \centering \item \relax .
+  <recently read> }
+  l. ...\ShowEnvironment{center}
+  > \end{center}:
+  > ->\endtrivlist .
+  <recently read> }
+  l. ...\ShowEnvironment{center}
+\end{verbatim}
 %
-\githubissue{xxx}
+\githubissue{963}
+
+
 
 
 \section{Code improvements}
@@ -256,16 +287,6 @@ it is open and ready to receive material.
 %
 \githubissue{944}
 
-\subsection{Providing copy and show functions for environments}
-
-\emph{to write}
-
-Add \cs{NewEnvironmentCopy},
-\cs{RenewEnvironmentCopy}, and \cs{DeclareEnvironmentCopy}
-
-There is now \cs{ShowEnvironment}
-%
-\githubissue{963}
 
 
 





More information about the latex3-commits mailing list.