diff options
author | Karl Berry <karl@freefriends.org> | 2023-02-05 21:15:42 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2023-02-05 21:15:42 +0000 |
commit | 1826cb7a886c82a06bcc09d387800419855f672d (patch) | |
tree | be969865ae45e1f4e7714cc383efee2fb02b7aa0 /Master/texmf-dist/source | |
parent | 066ec7a62734c87398bf9c05c269c21b668d9124 (diff) |
nicematrix (5feb23)
git-svn-id: svn://tug.org/texlive/trunk@65739 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source')
-rw-r--r-- | Master/texmf-dist/source/latex/nicematrix/nicematrix.dtx | 79 | ||||
-rw-r--r-- | Master/texmf-dist/source/latex/nicematrix/nicematrix.ins | 2 |
2 files changed, 63 insertions, 18 deletions
diff --git a/Master/texmf-dist/source/latex/nicematrix/nicematrix.dtx b/Master/texmf-dist/source/latex/nicematrix/nicematrix.dtx index 71f6ee632c6..02d0f8e8b8c 100644 --- a/Master/texmf-dist/source/latex/nicematrix/nicematrix.dtx +++ b/Master/texmf-dist/source/latex/nicematrix/nicematrix.dtx @@ -2,7 +2,7 @@ % % This file should be compiled with $xelatex$. % -% Copyright (C) 2018-2022 by F. Pantigny +% Copyright (C) 2018-2023 by F. Pantigny % ----------------------------------- % % This file may be distributed and/or modified under the @@ -17,8 +17,8 @@ % % \fi % \iffalse -\def\myfileversion{6.13e} -\def\myfiledate{2022/12/12} +\def\myfileversion{6.13f} +\def\myfiledate{2023/02/05} % % %<*batchfile> @@ -29,7 +29,7 @@ \preamble -Copyright (C) 2018-2022 by F. Pantigny +Copyright (C) 2018-2023 by F. Pantigny ----------------------------------- This file may be distributed and/or modified under the @@ -2258,7 +2258,8 @@ version 2005/12/01 or later. % parameter is |\linewidth| (and not |\textwidth|). % % For sake of similarity with the environment |{tabularx}|, \pkg{nicematrix} -% also provides an environment |{NiceTabularX}| with a first mandatory argument +% also provides an environment |{NiceTabularX}| with a syntax similar to the +% syntax of |{tabularx}|, that is to say with a first mandatory argument % which is the width of the tabular.\footnote{If \pkg{tabularx} is loaded, one % must use |{NiceTabularX}| (and not |{NiceTabular}|) in order to use the % columns |X| (this point comes from a conflict in the definitions of the @@ -3262,6 +3263,15 @@ version 2005/12/01 or later. % \end{pNiceArray}\] % % +% \bigskip +% The command |\SubMatrix| is, in fact, also available in the |\CodeBefore|. By +% using |\SubMatrix| in the |\CodeBefore|, the delimiters drawn by those +% commands |\SubMatrix| are taken into account to limit the continuous dotted +% lines (drawn by |\Cdots|, |\Vdots|, etc.) which have an open extremity. +% +% For an example, see voir \ref{submatrix-in-codebefore} +% p.~\pageref{submatrix-in-codebefore}. +% % \subsection{The commands \textbackslash OverBrace and \textbackslash % UnderBrace in the \textbackslash CodeAfter} % @@ -5733,6 +5743,8 @@ version 2005/12/01 or later. % % \subsection{Utilisation of \textbackslash SubMatrix in the \textbackslash CodeBefore} % +% \label{submatrix-in-codebefore} +% % In the following example, we illustrate the mathematical product of two % matrices. % @@ -10753,7 +10765,12 @@ version 2005/12/01 or later. \int_compare:nNnT { \box_ht:N \l_@@_cell_box } > - { \box_ht:N \@arstrutbox } +% \end{macrocode} +% Previously, we had |\@arstrutbox| and not |\strutbox| in the following line +% but the code in \pkg{array} has changed in v 2.5g and we follow the change +% (see \emph{array: Correctly identify single-line m-cells} in LaTeX~News~36). +% \begin{macrocode} + { \box_ht:N \strutbox } { \hbox_set:Nn \l_@@_cell_box { @@ -11120,27 +11137,32 @@ version 2005/12/01 or later. % \bigskip % After a specifier of column, we have to test whether there is one or several % |<{..}| because, after those potential |<{...}|, we have to insert -% |!{\skip_horizontal:N ...}| when the key |vlines| is used. +% |!{\skip_horizontal:N ...}| when the key |vlines| is used. In fact, we have +% also to test wheter there is, after the |<{...}|, a |@{...}|. % \begin{macrocode} \cs_new_protected:Npn \@@_patch_preamble_xi:n #1 { \str_if_eq:nnTF { #1 } { < } \@@_patch_preamble_xiii:n { - \tl_if_eq:NnTF \l_@@_vlines_clist { all } - { - \tl_gput_right:Nn \g_@@_preamble_tl - { ! { \skip_horizontal:N \arrayrulewidth } } - } - { - \exp_args:NNx - \clist_if_in:NnT \l_@@_vlines_clist { \int_eval:n { \c@jCol + 1 } } + \str_if_eq:nnTF { #1 } { @ } + \@@_patch_preamble_xv:n + { + \tl_if_eq:NnTF \l_@@_vlines_clist { all } { \tl_gput_right:Nn \g_@@_preamble_tl { ! { \skip_horizontal:N \arrayrulewidth } } } - } - \@@_patch_preamble:n { #1 } + { + \exp_args:NNx + \clist_if_in:NnT \l_@@_vlines_clist { \int_eval:n { \c@jCol + 1 } } + { + \tl_gput_right:Nn \g_@@_preamble_tl + { ! { \skip_horizontal:N \arrayrulewidth } } + } + } + \@@_patch_preamble:n { #1 } + } } } % \end{macrocode} @@ -11153,6 +11175,29 @@ version 2005/12/01 or later. } % \end{macrocode} % +% We have to catch a |@{...}| after a specifier of column because, if we have to +% draw a vertical rule, we have to add in that |@{...}| a |\hskip| corresponding +% to the width of the vertical rule. +% \begin{macrocode} +\cs_new_protected:Npn \@@_patch_preamble_xv:n #1 + { + \tl_if_eq:NnTF \l_@@_vlines_clist { all } + { + \tl_gput_right:Nn \g_@@_preamble_tl + { @ { #1 \skip_horizontal:N \arrayrulewidth } } + } + { + \exp_args:NNx + \clist_if_in:NnT \l_@@_vlines_clist { \int_eval:n { \c@jCol + 1 } } + { + \tl_gput_right:Nn \g_@@_preamble_tl + { @ { #1 \skip_horizontal:N \arrayrulewidth } } + } + } + \@@_patch_preamble:n + } +% \end{macrocode} +% % \bigskip % \begin{macrocode} \cs_new_protected:Npn \@@_set_preamble:Nn #1 #2 diff --git a/Master/texmf-dist/source/latex/nicematrix/nicematrix.ins b/Master/texmf-dist/source/latex/nicematrix/nicematrix.ins index 2bfd59f5679..814600f7c2b 100644 --- a/Master/texmf-dist/source/latex/nicematrix/nicematrix.ins +++ b/Master/texmf-dist/source/latex/nicematrix/nicematrix.ins @@ -17,7 +17,7 @@ \usedir{tex/latex/nicematrix} \preamble -Copyright (C) 2018-2022 by F. Pantigny +Copyright (C) 2018-2023 by F. Pantigny This file may be distributed and/or modified under the conditions of the LaTeX Project Public License, either |