[latex3-commits] [git/LaTeX3-latex3-latex2e] develop: First draft for LaTeX News section on xparse (a6592c26)

Joseph Wright joseph.wright at morningstar2.co.uk
Sat Mar 7 23:18:33 CET 2020


Repository : https://github.com/latex3/latex2e
On branch  : develop
Link       : https://github.com/latex3/latex2e/commit/a6592c263cdf67434306fb3e7f1ed773ff486dd2

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

commit a6592c263cdf67434306fb3e7f1ed773ff486dd2
Author: Joseph Wright <joseph.wright at morningstar2.co.uk>
Date:   Sat Mar 7 22:18:33 2020 +0000

    First draft for LaTeX News section on xparse


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

a6592c263cdf67434306fb3e7f1ed773ff486dd2
 base/doc/ltnews32.tex | 42 +++++++++++++++++++++++++++++++++++++++---
 1 file changed, 39 insertions(+), 3 deletions(-)

diff --git a/base/doc/ltnews32.tex b/base/doc/ltnews32.tex
index 37e18210..a244854b 100644
--- a/base/doc/ltnews32.tex
+++ b/base/doc/ltnews32.tex
@@ -143,9 +143,45 @@ This document is under construction \ldots
 
 \section{Providing \pkg{xparse} in the format}
 
-\emph{write section}
-
-
+The official interface in the \LaTeXe{} kernel for creating document-level
+commands has always been \cs{newcommand}. However, this is very limited in the
+types of command it can create: those taking at most one optional argument in
+square brackets, then zero or more mandatory arguments. Richer syntaxes
+required use of the \TeX{} \cs{def} primitive along with appropriate macro
+programming.
+
+The \LaTeX{} team started work on a comprehensive document-command parser,
+\pkg{xparse}, in the late 1990s. In the past decade, the experimental ideas it
+provides have been carefully worked through and moved to a stable footing. As
+such, \pkg{xparse} is now used to define a very large number of document
+commands. It does this by providing a rich and self-consistent syntax to
+describe a wide range interfaces seen in \LaTeX{} packages.
+
+The ideas developed in \pkg{xparse} are now sufficiently well-tested that
+the majority can be transferred into the \LaTeX{} kernel. Thus the following
+commands have been added
+\begin{itemize}
+  \item \cs{NewDocumentCommand}, \cs{RenewDocumentCommand},
+    \cs{ProvideDocumentCommand}, \cs{DeclareDocumentCommand}
+  \item \cs{NewExpandableDocumentCommand}, \cs{RenewExpandableDocumentCommand},
+    \cs{ProvideExpandableDocumentCommand}, \cs{DeclareExpandableDocumentCommand}
+  \item \cs{NewDocumentEnvironment}, \cs{RenewDocumentEnvironment},
+    \cs{ProvideDocumentEnvironment}, \cs{DeclareDocumentEnvironment}
+  \item \cs{BooleanTrue} \cs{BooleanFalse}
+  \item \cs{IfBooleanTF}, \cs{IfBooleanT}, \cs{IfBooleanF}
+  \item \cs{IfNoValueTF}, \cs{IfNoValueT}, \cs{IfNoValueF}
+  \item \cs{IfValueTF}, \cs{IfValueT}, \cs{IfValueF}
+  \item \cs{SplitArgument}, \cs{SplitList}, \cs{TrimSpaces},
+    \cs{ProcessList}, \cs{ReverseBoolean}
+  \item \cs{GetDocumentCommandArgSpec}
+    \cs{GetDocumentEnvironmentArgSpec}
+\end{itemize}
+
+The full list of argument types defined by \pkg{xparse} are \emph{not}
+supported at the kernel level. In particular, the types |g|/|G|, |l| and
+|u| are not provided by the kernel code; these are deprecated but still
+available by explicitly loading \pkg{xparse}. All other argument types
+\emph{are} now available directly within the \LaTeXe{} kernel.
 
 \section{Other changes to the \LaTeX{} kernel}
 





More information about the latex3-commits mailing list.