texlive[60310] Master/texmf-dist: cascade (23aug21)

commits+karl at tug.org commits+karl at tug.org
Mon Aug 23 22:51:12 CEST 2021


Revision: 60310
          http://tug.org/svn/texlive?view=revision&revision=60310
Author:   karl
Date:     2021-08-23 22:51:12 +0200 (Mon, 23 Aug 2021)
Log Message:
-----------
cascade (23aug21)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/latex/cascade/README.md
    trunk/Master/texmf-dist/doc/latex/cascade/cascade-french.pdf
    trunk/Master/texmf-dist/doc/latex/cascade/cascade-french.tex
    trunk/Master/texmf-dist/doc/latex/cascade/cascade.pdf
    trunk/Master/texmf-dist/source/latex/cascade/cascade.dtx
    trunk/Master/texmf-dist/source/latex/cascade/cascade.ins
    trunk/Master/texmf-dist/tex/latex/cascade/cascade.sty

Modified: trunk/Master/texmf-dist/doc/latex/cascade/README.md
===================================================================
--- trunk/Master/texmf-dist/doc/latex/cascade/README.md	2021-08-23 20:50:58 UTC (rev 60309)
+++ trunk/Master/texmf-dist/doc/latex/cascade/README.md	2021-08-23 20:51:12 UTC (rev 60310)
@@ -9,8 +9,7 @@
 
 ## Presentation
 
-
-The LaTeX package `cascade` provides a command `\Cascade` to do contructions to present mathematical
+The LaTeX package `cascade` provides a command `\Cascade` to do constructions to present mathematical
 demonstrations with successive braces for the deductions.
 
 

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

Modified: trunk/Master/texmf-dist/doc/latex/cascade/cascade-french.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/cascade/cascade-french.tex	2021-08-23 20:50:58 UTC (rev 60309)
+++ trunk/Master/texmf-dist/doc/latex/cascade/cascade-french.tex	2021-08-23 20:51:12 UTC (rev 60310)
@@ -66,29 +66,30 @@
 
 
 \title{L'extension LaTeX \pkg{cascade}\thanks{Ce document correspond à la 
-version~\myfileversion\space of \pkg{cascade}, à la date du~\myfiledate.}} 
+version~\myfileversion\space de \pkg{cascade}, à la date du~\myfiledate.}} 
 \author{F. Pantigny \\ \texttt{fpantigny at wanadoo.fr}}
 
 \maketitle
 
 \begin{abstract}
-L'extension LaTeX \pkg{cascade} fournit une commande |\Cascade| pour faire des
-constructions qui présentent des démonstrations mathématiques avec des accolades
-enchaînées pour les déductions.
+L'extension LaTeX \pkg{cascade} fournit une commande |\Cascade| pour faire des constructions qui présentent des
+démonstrations mathématiques avec des accolades enchaînées pour les déductions. L'extension \pkg{cascade} fournit
+également une commande |\Edacsac| (\emph{cascade} à l'envers) qui construit une structure similaire mais avec des
+accolades allant dans l'autre sens. 
 \end{abstract}
 
 
 
 \vspace{1cm}
-\section{Présentation}
+\section{La commande \textbackslash Cascade}
 
 L'extension \pkg{cascade} fournit une commande |\Cascade| qui permet des
 constructions comme la suivante, où la taille de l'accolade de droite est
 calculée sur seulement une partie des éléments LaTeX composés à gauche.
 \begin{center}
-\Cascade{$\det(A) = \begin{vmatrix}3&4\\ -1&7\end{vmatrix}\neq 0$}%
-        {et, par conséquent, $A$ est inversible}%
-        {}%
+\Cascade{$\det(A) = \begin{vmatrix}3&4\\ -1&7\end{vmatrix}\neq 0$}
+        {et, par conséquent, $A$ est inversible}
+        {}
         {or $AX=Y$} 
 donc, $X = A^{-1}Y$
 \end{center}
@@ -95,9 +96,9 @@
         
 \medskip
 \begin{Verbatim}
-~emphase#\Cascade@{$\det(A) = \begin{vmatrix}3&4\\ -1&7\end{vmatrix}\neq 0$}%
-        {et, par conséquent, $A$ est inversible}%
-        {}%
+~emphase#\Cascade@{$\det(A) = \begin{vmatrix}3&4\\ -1&7\end{vmatrix}\neq 0$}
+        {et, par conséquent, $A$ est inversible}
+        {}
         {or $AX=Y$} 
 donc, $X = A^{-1}Y$
 \end{Verbatim}
@@ -244,14 +245,47 @@
 |\CascadeOptions|. Dans ce cas, la portée de ces déclarations est le groupe TeX
 courant (ces déclarations sont, comme on dit parfois «semi-globales»).
 
+\bigskip
+\section{La commande \textbackslash Edacsac}
 
+La commande |\Edacsac| (\textsl{cascade} écrit à l'envers) est similaire à la commande |\Cascade| mais avec des
+accolades dans l'autre sens. La clé~|t| n'est pas disponible dans cette commande. 
 
+\begin{Verbatim}
+Singularity 
+~emphase#\Edacsac@
+  {elementary}
+    {
+      ~emphase#\Edacsac@
+        {non-degenerate elementary}
+          {~emphase#\ShortEdacsac@{hyperbolic}{non-hyperbolic}}
+        {degenerate elementary}
+          {}
+      }
+  {non-elementary}
+    {~emphase#\ShortEdacsac@{Nilpotent}{Higher order}}
+\end{Verbatim}
+
+
+Singularity 
+\Edacsac
+  {elementary}
+  {
+    \Edacsac
+      {non-degenerate elementary}
+      {\ShortEdacsac{hyperbolic}{non-hyperbolic}}
+      {degenerate elementary}
+      {}
+    }
+  {non-elementary}
+  {\ShortEdacsac{nilpotent}{higher order}}
+
+
 \bigskip
 \section{Remarque technique}
 
-L'extension |\Cascade| est conçue pour fournir par défaut des résultats similaires
-à ceux fournis par les environnements  de l'\pkg{amsmath} (et de
-\pkg{mathtools}), en particulier |{aligned}|.
+Les commandes de \pkg{cascade} sont conçues pour fournir par défaut des résultats similaires à ceux fournis par les
+environnements de l'\pkg{amsmath} (et de \pkg{mathtools}), en particulier |{aligned}|.
 
 
 \bigskip
@@ -278,7 +312,7 @@
 |\left|-|\right| de TeX. Néanmoins, les délimiteurs extensibles, en TeX, ne
 peuvent pas prendre toutes les tailles. On donne, dans l'exemple suivant, les
 accolades obtenues en entourant des filets verticaux de $6$~mm à $17$~mm (le code
-est en |expl3|).
+utilise la couche programmative de LaTeX3).
 
 \begin{Verbatim}
 \int_step_inline:nnnn 6 1 {17} { $\left.\hbox{\vrule height ~#1 mm}\right\}$\quad }
@@ -298,10 +332,6 @@
 documentation ici présente, ainsi que le code source commenté et un historique des versions.
 
 
-
-
-
-
 \end{document}
 
 

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

Modified: trunk/Master/texmf-dist/source/latex/cascade/cascade.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/cascade/cascade.dtx	2021-08-23 20:50:58 UTC (rev 60309)
+++ trunk/Master/texmf-dist/source/latex/cascade/cascade.dtx	2021-08-23 20:51:12 UTC (rev 60310)
@@ -1,6 +1,6 @@
 % \iffalse meta-comment
 %
-% Copyright (C) 2018-2020 by F. Pantigny
+% Copyright (C) 2018-2021 by F. Pantigny
 % -----------------------------------
 %
 % This file may be distributed and/or modified under the
@@ -15,8 +15,8 @@
 %
 % \fi
 % \iffalse
-\def\myfileversion{1.1}
-\def\myfiledate{2020/07/05}
+\def\myfileversion{1.2}
+\def\myfiledate{2021/08/23}
 %
 %
 %<*batchfile>
@@ -26,7 +26,7 @@
 \usedir{tex/latex/cascade}
 \preamble
 
-Copyright (C) 2018-2020 by F. Pantigny
+Copyright (C) 2018-2021 by F. Pantigny
 -----------------------------------
 
 This file may be distributed and/or modified under the
@@ -106,21 +106,23 @@
 % \begin{abstract}
 % The LaTeX package \pkg{cascade} provides a command |\Cascade| to do
 % constructions to present mathematical demonstrations with successive braces
-% for the deductions.
+% for the deductions. The package \pkg{cascade} provides also a command
+% |\Edacsac| which creates similar structures but with
+% braces going backwards.
 % \end{abstract}
 % 
 %
 %
 % \vspace{1cm}
-% \section{Presentation}
+% \section{The command \textbackslash Cascade}
 %
 % The package \pkg{cascade} provides a command |\Cascade| which allows
 % constructions like the following where the size of the right brace is computed
 % on only a part of the LaTeX elements composed on the left.
 % \begin{center}
-% \Cascade{$\det(A) = \begin{vmatrix}3&4\\ -1&7\end{vmatrix}\neq 0$}%
-%         {and, therefore, $A$ is inversible}%
-%         {}%
+% \Cascade{$\det(A) = \begin{vmatrix}3&4\\ -1&7\end{vmatrix}\neq 0$}
+%         {and, therefore, $A$ is inversible}
+%         {}
 %         {yet $AX=Y$} 
 % hence, $X = A^{-1}Y$
 % \end{center}
@@ -127,9 +129,9 @@
 %         
 % \medskip
 % \begin{Verbatim}
-% ~emphase#\Cascade@{$\det(A) = \begin{vmatrix}3&4\\ -1&7\end{vmatrix}\neq 0$}%
-%         {and, therefore, $A$ is inversible}%
-%         {}%
+% ~emphase#\Cascade@{$\det(A) = \begin{vmatrix}3&4\\ -1&7\end{vmatrix}\neq 0$}
+%         {and, therefore, $A$ is inversible}
+%         {}
 %         {yet $AX=Y$} 
 % hence, $X = A^{-1}Y$
 % \end{Verbatim}
@@ -272,13 +274,49 @@
 % |\CascadeOptions|. In this case, the scope of the declarations is the current
 % TeX group (these declarations are ``semi-global'').
 % 
+% \bigskip
+% \section{The command \textbackslash Edacsac}
+%
+% The command |\Edacsac| (\textsl{cascade} written in reverse) is similar to the
+% command |\Cascade| but with braces going backwards. The key |t| is not available in that command.
 % 
+% \begin{Verbatim}
+% Singularity 
+% ~emphase#\Edacsac@
+%   {elementary}
+%     {
+%       ~emphase#\Edacsac@
+%         {non-degenerate elementary}
+%           {~emphase#\ShortEdacsac@{hyperbolic}{non-hyperbolic}}
+%         {degenerate elementary}
+%           {}
+%       }
+%   {non-elementary}
+%     {~emphase#\ShortEdacsac@{Nilpotent}{Higher order}}
+% \end{Verbatim}
+%
+%
+% Singularity 
+% \Edacsac
+%   {elementary}
+%   {
+%     \Edacsac
+%       {non-degenerate elementary}
+%       {\ShortEdacsac{hyperbolic}{non-hyperbolic}}
+%       {degenerate elementary}
+%       {}
+%     }
+%   {non-elementary}
+%   {\ShortEdacsac{nilpotent}{higher order}}
+%
+% 
+% 
 % \bigskip
 % \section{Technical remark}
 % 
-% The package |\Cascade| is designed to provide by default results similar to the
-% those given by the environments of \pkg{amsmath} --- and \pkg{mathtools} ---
-% especially |{aligned}|.
+% The package \pkg{cascade} is designed to provide by default results similar to
+% the those given by the environments of \pkg{amsmath} --- and \pkg{mathtools}
+% --- especially |{aligned}|.
 % 
 % \bigskip
 % \begin{BVerbatim}[baseline=c,boxwidth=10cm]
@@ -303,7 +341,8 @@
 % The package \pkg{cascade} constructs the braces with the classical pair
 % |\left|-|\right| of TeX. However, the extensible delimiters, in TeX, cannot
 % take all sizes. We give, in the following example, the braces obtained when
-% surrounding vertical rules from $6$~mm to $17$~mm (the code is in |expl3|).
+% surrounding vertical rules from $6$~mm to $17$~mm (the code uses the L3
+% programming layer).
 %
 % \begin{Verbatim}
 % \int_step_inline:nnnn 6 1 {17} { $\left.\hbox{\vrule height ~#1 mm}\right\}$\quad }
@@ -330,10 +369,6 @@
   {Easy presentation of demonstrations in cascades}
 %    \end{macrocode}
 % 
-% \interitem
-%    \begin{macrocode}
-\RequirePackage{xparse}
-%    \end{macrocode}
 % 
 % \interitem
 % \iffalse
@@ -404,7 +439,7 @@
 %%
 %% This set of options will be used by \Cascade and \ShortCascade
 % \fi
-% The set of keys |cascade/command| will be used for the commands |\Cascade|.
+% The set of keys |cascade/command| will be used by the command |\Cascade|.
 %    \begin{macrocode}
 \keys_define:nn { cascade / command }
   {
@@ -461,6 +496,19 @@
     space-between .value_required:n = true
   }
 %    \end{macrocode}
+%
+% \medskip
+%    \begin{macrocode}
+\cs_new_protected:Npn \@@_initialisation:
+  {
+    \box_clear_new:N \l_@@_box_one
+    \box_clear_new:N \l_@@_box_two
+    \box_clear_new:N \l_@@_box_three
+    \box_clear_new:N \l_@@_box_four
+    \dim_zero_new:N \l_@@_top_dim
+    \dim_zero_new:N \l_@@_bottom_dim
+  }
+%    \end{macrocode}
 % 
 % \medskip
 % \DescribeMacro{\CascadeOptions}
@@ -484,7 +532,7 @@
 \NewDocumentCommand \Cascade { O { } m m m m D < > { } }
   { 
     \if_mode_math:
-      \msg_error:nn { cascade } { Cascade~in~math~mode }
+      \msg_error:nn { cascade } { math~mode }
     \fi:
     \mode_leave_vertical:
 %    \end{macrocode}
@@ -500,10 +548,7 @@
     \spread at equation
     \dim_set_eq:NN \l_@@_interline_dim \l_@@_interline_all_dim
     \keys_set:nn { cascade / command } { #1 }
-    \box_clear_new:N \l_@@_box_one
-    \box_clear_new:N \l_@@_box_two
-    \box_clear_new:N \l_@@_box_three
-    \box_clear_new:N \l_@@_box_four
+    \@@_initialisation:
     \hbox_set:Nn \l_@@_box_one 
       { 
         \bool_set_true:N \l_@@_first_argument_bool 
@@ -524,7 +569,6 @@
 % The dimension |\l_@@_top_dim| is the space that we will have to add before the
 % main construction to make up for the ``|\smash[t]|'' of the box |#1|.
 %    \begin{macrocode}
-    \dim_zero_new:N \l_@@_top_dim
     \dim_set:Nn \l_@@_top_dim 
       { 
         \dim_max:nn 
@@ -535,7 +579,6 @@
 % The dimension |\l_@@_bottom_dim| is the space that we will have to add after
 % the main construction to make up for the ``|\smash[b]|'' of the box |#3|.
 %    \begin{macrocode}
-    \dim_zero_new:N \l_@@_bottom_dim
     \dim_set:Nn \l_@@_bottom_dim 
       { 
         \dim_max:nn 
@@ -565,6 +608,10 @@
 %    \begin{macrocode}
             \bool_if:NT \l_@@_first_argument_bool
               {
+%    \end{macrocode}
+% Here, you should use |\box_ht_plus_dp:N| when TeXLive 2021 will be available
+% on Overleaf. 
+%    \begin{macrocode}
                 \dim_set:Nn \l_tmpa_dim
                   { \box_ht:N \l_tmpb_box + \box_dp:N \l_tmpb_box }
                 \l_tmpa_dim = 0.5\l_tmpa_dim
@@ -575,7 +622,7 @@
               }
 %    \end{macrocode}
 %    \begin{macrocode}
-            \hbox:n 
+            \hbox
               {
                 \c_math_toggle_token
                 \left .
@@ -625,7 +672,7 @@
             \halign 
               { 
                 \hfil ## \cr
-                \hbox:n
+                \hbox
                   {
                     \tl_if_empty:nF { #1 }
                       {
@@ -637,7 +684,7 @@
                   } 
                 \cr
                 \noalign { \skip_vertical:n \l_@@_interline_dim }
-                \hbox:n 
+                \hbox
                   {
                     \tl_if_empty:nF { #2 } 
                       { 
@@ -654,15 +701,92 @@
       }
   }
 %    \end{macrocode}
+%
+% \bigskip
+% The command |\Edacsac|. The code is simpler because we don't need the
+% |\halign| and we don't have the key |t|.
+%
+%    \begin{macrocode}
+\NewDocumentCommand \Edacsac { O { } m m m m }
+  {
+    \if_mode_math:
+      \msg_error:nn { cascade } { math~mode }
+    \fi:
+    \mode_leave_vertical:
+    \group_begin:
+    \spread at equation
+    \dim_set_eq:NN \l_@@_interline_dim \l_@@_interline_all_dim
+    \keys_set:nn { cascade / command } { #1 }
+    \@@_initialisation:
+    \hbox_set:Nn \l_@@_box_one { #2 }
+    \hbox_set:Nn \l_@@_box_two { #3 }
+    \hbox_set:Nn \l_@@_box_three { #4 }
+    \hbox_set:Nn \l_@@_box_four { #5 }
+    \dim_set:Nn \l_@@_top_dim
+      {
+        \dim_max:nn
+          \c_zero_dim
+          { \box_ht:N \l_@@_box_two - \box_ht:N \l_@@_box_one }
+      }
+    \dim_set:Nn \l_@@_bottom_dim
+      {
+        \dim_max:nn
+          \c_zero_dim
+          { \box_dp:N \l_@@_box_four - \box_dp:N \l_@@_box_three }
+      }
+    \box_set_ht:Nn \l_@@_box_two \c_zero_dim
+    \box_set_dp:Nn \l_@@_box_four \c_zero_dim
+    \vbox
+       {
+         \skip_vertical:N \l_@@_top_dim
+         \vtop
+           {
+             \hbox
+               {
+                 \c_math_toggle_token
+                 \left \{
+                 \vcenter
+                   {
+                     \hbox
+                       {
+                         \tl_if_empty:nF { #2 }
+                           {
+                             \box_use_drop:N \l_@@_box_one
+                             \skip_horizontal:n \l_@@_space_between_dim 
+                           }
+                         \box_use_drop:N \l_@@_box_two 
+                         \strut
+                       }
+                     \skip_vertical:N \l_@@_interline_dim 
+                     \hbox
+                       {
+                         \tl_if_empty:nF { #4 }
+                           {
+                             \box_use_drop:N \l_@@_box_three
+                             \skip_horizontal:n \l_@@_space_between_dim
+                           }
+                         \box_use_drop:N \l_@@_box_four
+                         \strut
+                       }
+                   }
+                 \right .
+                 \c_math_toggle_token
+               }
+             \skip_vertical:N \l_@@_bottom_dim
+           }
+       }
+    \group_end:
+}
+%    \end{macrocode}
+%
 % 
 % \bigskip
 %    \begin{macrocode}
 \msg_new:nnn 
   { cascade }
-  { Cascade~in~math~mode }
+  { math~mode }
   {
-    The~commands~\token_to_str:N \Cascade\
-    and~\token_to_str:N \ShortCascade\  
+    The~commands~of~the~extension~'cascade'~
     should~be~used~in~text~mode~only.~However,~you~can~
     go~on~for~this~time.
   }
@@ -688,6 +812,15 @@
   { \Cascade [ #1 ] { } { #2 } { } { #3 } }
 %    \end{macrocode}
 %
+% \bigskip
+% \DescribeMacro{\ShortEdacsac}
+% Idem for |\ShortEdacsac|
+%    \begin{macrocode}
+\NewDocumentCommand \ShortEdacsac { O { } m m }
+  { \Edacsac [ #1 ] { #2 } { } { #3 } { } }
+%    \end{macrocode}
+%
+%
 % \vspace{1cm}
 % \section{History}
 %
@@ -695,7 +828,10 @@
 % 
 % New option |t|.
 % 
+% \subsection*{Changes between versions 1.0 and 1.1}
 %
+% New commands |\Edacsac| and |\ShortEdacsac|.
+% 
 %
 % \PrintIndex
 % \tableofcontents

Modified: trunk/Master/texmf-dist/source/latex/cascade/cascade.ins
===================================================================
--- trunk/Master/texmf-dist/source/latex/cascade/cascade.ins	2021-08-23 20:50:58 UTC (rev 60309)
+++ trunk/Master/texmf-dist/source/latex/cascade/cascade.ins	2021-08-23 20:51:12 UTC (rev 60310)
@@ -1,5 +1,5 @@
 %%
-%% Copyright (C) 2018 by F. Pantigny
+%% Copyright (C) 2018-2021 by F. Pantigny
 %%
 %%
 %% This file may be distributed and/or modified under the
@@ -17,7 +17,7 @@
 \usedir{tex/latex/cascade}
 \preamble
 
-Copyright (C) 2018 by F. Pantigny
+Copyright (C) 2018-2021 by F. Pantigny
 
 This file may be distributed and/or modified under the
 conditions of the LaTeX Project Public License, either

Modified: trunk/Master/texmf-dist/tex/latex/cascade/cascade.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/cascade/cascade.sty	2021-08-23 20:50:58 UTC (rev 60309)
+++ trunk/Master/texmf-dist/tex/latex/cascade/cascade.sty	2021-08-23 20:51:12 UTC (rev 60310)
@@ -6,7 +6,7 @@
 %%
 %% cascade.dtx  (with options: `package')
 %% 
-%% Copyright (C) 2018 by F. Pantigny
+%% Copyright (C) 2018-2021 by F. Pantigny
 %% 
 %% This file may be distributed and/or modified under the
 %% conditions of the LaTeX Project Public License, either
@@ -18,8 +18,8 @@
 %% and version 1.3 or later is part of all distributions of
 %% LaTeX version 2005/12/01 or later.
 %% 
-\def\myfileversion{1.1}
-\def\myfiledate{2020/07/05}
+\def\myfileversion{1.2}
+\def\myfiledate{2021/08/23}
 \RequirePackage{l3keys2e}
 \ProvidesExplPackage
   {cascade}
@@ -26,7 +26,6 @@
   {\myfiledate}
   {\myfileversion}
   {Easy presentation of demonstrations in cascades}
-\RequirePackage{xparse}
 %%
 %% The following macro is the same as the macro of amsmath
 \cs_if_free:NT \spread at equation
@@ -76,6 +75,15 @@
     space-between .dim_set:N = \l__cascade_space_between_dim ,
     space-between .value_required:n = true
   }
+\cs_new_protected:Npn \__cascade_initialisation:
+  {
+    \box_clear_new:N \l__cascade_box_one
+    \box_clear_new:N \l__cascade_box_two
+    \box_clear_new:N \l__cascade_box_three
+    \box_clear_new:N \l__cascade_box_four
+    \dim_zero_new:N \l__cascade_top_dim
+    \dim_zero_new:N \l__cascade_bottom_dim
+  }
 \NewDocumentCommand \CascadeOptions { m }
   { \keys_set:nn { cascade / global } { #1 } }
 %%
@@ -83,7 +91,7 @@
 \NewDocumentCommand \Cascade { O { } m m m m D < > { } }
   {
     \if_mode_math:
-      \msg_error:nn { cascade } { Cascade~in~math~mode }
+      \msg_error:nn { cascade } { math~mode }
     \fi:
     \mode_leave_vertical:
     \bool_if:NF \l__cascade_nested_command_bool
@@ -96,10 +104,7 @@
     \spread at equation
     \dim_set_eq:NN \l__cascade_interline_dim \l__cascade_interline_all_dim
     \keys_set:nn { cascade / command } { #1 }
-    \box_clear_new:N \l__cascade_box_one
-    \box_clear_new:N \l__cascade_box_two
-    \box_clear_new:N \l__cascade_box_three
-    \box_clear_new:N \l__cascade_box_four
+    \__cascade_initialisation:
     \hbox_set:Nn \l__cascade_box_one
       {
         \bool_set_true:N \l__cascade_first_argument_bool
@@ -114,7 +119,6 @@
         #4
       }
     \hbox_set:Nn \l__cascade_box_four { #5 }
-    \dim_zero_new:N \l__cascade_top_dim
     \dim_set:Nn \l__cascade_top_dim
       {
         \dim_max:nn
@@ -121,7 +125,6 @@
           \c_zero_dim
           { \box_ht:N \l__cascade_box_one - \box_ht:N \l__cascade_box_two }
       }
-    \dim_zero_new:N \l__cascade_bottom_dim
     \dim_set:Nn \l__cascade_bottom_dim
       {
         \dim_max:nn
@@ -146,7 +149,7 @@
                   { \dim_max:nn { \box_ht:N \l__cascade_box_two } { \box_ht:N \strutbox } }
                 \dim_gadd:Nn \g__cascade_yoffset_dim \l_tmpa_dim
               }
-            \hbox:n
+            \hbox
               {
                 \c_math_toggle_token
                 \left .
@@ -187,7 +190,7 @@
             \halign
               {
                 \hfil ## \cr
-                \hbox:n
+                \hbox
                   {
                     \tl_if_empty:nF { #1 }
                       {
@@ -199,7 +202,7 @@
                   }
                 \cr
                 \noalign { \skip_vertical:n \l__cascade_interline_dim }
-                \hbox:n
+                \hbox
                   {
                     \tl_if_empty:nF { #2 }
                       {
@@ -215,12 +218,81 @@
         \c_math_toggle_token
       }
   }
+\NewDocumentCommand \Edacsac { O { } m m m m }
+  {
+    \if_mode_math:
+      \msg_error:nn { cascade } { math~mode }
+    \fi:
+    \mode_leave_vertical:
+    \group_begin:
+    \spread at equation
+    \dim_set_eq:NN \l__cascade_interline_dim \l__cascade_interline_all_dim
+    \keys_set:nn { cascade / command } { #1 }
+    \__cascade_initialisation:
+    \hbox_set:Nn \l__cascade_box_one { #2 }
+    \hbox_set:Nn \l__cascade_box_two { #3 }
+    \hbox_set:Nn \l__cascade_box_three { #4 }
+    \hbox_set:Nn \l__cascade_box_four { #5 }
+    \dim_set:Nn \l__cascade_top_dim
+      {
+        \dim_max:nn
+          \c_zero_dim
+          { \box_ht:N \l__cascade_box_two - \box_ht:N \l__cascade_box_one }
+      }
+    \dim_set:Nn \l__cascade_bottom_dim
+      {
+        \dim_max:nn
+          \c_zero_dim
+          { \box_dp:N \l__cascade_box_four - \box_dp:N \l__cascade_box_three }
+      }
+    \box_set_ht:Nn \l__cascade_box_two \c_zero_dim
+    \box_set_dp:Nn \l__cascade_box_four \c_zero_dim
+    \vbox
+       {
+         \skip_vertical:N \l__cascade_top_dim
+         \vtop
+           {
+             \hbox
+               {
+                 \c_math_toggle_token
+                 \left \{
+                 \vcenter
+                   {
+                     \hbox
+                       {
+                         \tl_if_empty:nF { #2 }
+                           {
+                             \box_use_drop:N \l__cascade_box_one
+                             \skip_horizontal:n \l__cascade_space_between_dim
+                           }
+                         \box_use_drop:N \l__cascade_box_two
+                         \strut
+                       }
+                     \skip_vertical:N \l__cascade_interline_dim
+                     \hbox
+                       {
+                         \tl_if_empty:nF { #4 }
+                           {
+                             \box_use_drop:N \l__cascade_box_three
+                             \skip_horizontal:n \l__cascade_space_between_dim
+                           }
+                         \box_use_drop:N \l__cascade_box_four
+                         \strut
+                       }
+                   }
+                 \right .
+                 \c_math_toggle_token
+               }
+             \skip_vertical:N \l__cascade_bottom_dim
+           }
+       }
+    \group_end:
+}
 \msg_new:nnn
   { cascade }
-  { Cascade~in~math~mode }
+  { math~mode }
   {
-    The~commands~\token_to_str:N \Cascade\
-    and~\token_to_str:N \ShortCascade\
+    The~commands~of~the~extension~'cascade'~
     should~be~used~in~text~mode~only.~However,~you~can~
     go~on~for~this~time.
   }
@@ -234,6 +306,8 @@
   }
 \NewDocumentCommand \ShortCascade { O { } m m }
   { \Cascade [ #1 ] { } { #2 } { } { #3 } }
+\NewDocumentCommand \ShortEdacsac { O { } m m }
+  { \Edacsac [ #1 ] { #2 } { } { #3 } { } }
 
 \endinput
 %%



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