diff options
Diffstat (limited to 'Master/texmf-dist/tex/latex')
-rw-r--r-- | Master/texmf-dist/tex/latex/nicematrix/nicematrix.sty | 44 |
1 files changed, 26 insertions, 18 deletions
diff --git a/Master/texmf-dist/tex/latex/nicematrix/nicematrix.sty b/Master/texmf-dist/tex/latex/nicematrix/nicematrix.sty index 700a079f4d8..2b86f50602f 100644 --- a/Master/texmf-dist/tex/latex/nicematrix/nicematrix.sty +++ b/Master/texmf-dist/tex/latex/nicematrix/nicematrix.sty @@ -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{2.1} -\def\myfiledate{2018/08/12} +\def\myfileversion{2.1.1} +\def\myfiledate{2018/09/16} \RequirePackage{tikz} \usetikzlibrary{fit} \RequirePackage{l3keys2e} @@ -91,6 +91,8 @@ NullifyDots .meta:n = nullify-dots, code-for-last-col .tl_set:N = \l__nm_code_for_last_col_tl, code-for-last-col .value_required:n = true, + code-for-first-row .tl_set:N = \l__nm_code_for_first_row_tl, + code-for-first-row .value_required:n = true, exterior-arraycolsep .bool_set:N = \l__nm_exterior_arraycolsep_bool , exterior-arraycolsep .default:n = true, columns-width .code:n = \str_if_eq:nnTF {#1} {auto} @@ -105,7 +107,7 @@ unknown .code:n = \__nm_msg_error:n {Unknown~key~for~NiceMatrixOptions}} \msg_new:nnnn {nicematrix} {Unknown~key~for~NiceMatrixOptions} - {The~key~"\tl_use:N\l_keys_key_tl"~is~unknown~for~the~command + {The~key~"\tl_use:N\l_keys_key_tl"~is~unknown~for~the~command~ \token_to_str:N \NiceMatrixOptions.\\ If~you~go~on,~it~will~be~ignored.\\ For~a~list~of~the~available~keys,~type~H~<return>.} @@ -285,6 +287,9 @@ \NewDocumentEnvironment {NiceArray} {O{} m O{}} {\cs_if_exist:NT \__nm_in_NiceArray: {\__nm_msg_error:n {We~are~yet~in~an~environment~NiceArray}} + \ifcsname tikz@library@external@loaded\endcsname + \tikzset{external/export = false} + \fi \cs_set:Npn \__nm_in_NiceArray: {--Void--} \aftergroup \__nm_after_array: \tl_gclear_new:N \g__nm_lines_to_draw_tl @@ -427,7 +432,10 @@ {\int_use:N \g__nm_row_int} {\int_use:N \g__nm_column_int}}} \cs_new_protected:Nn \__nm_after_array: - { + {\group_begin: + \ifcsname tikz@library@external@loaded\endcsname + \tikzset{external/export = false} + \fi \int_gset_eq:NN \g__nm_column_int \g__nm_column_total_int \bool_if:NT \l__nm_exterior_column_bool {\int_gdecr:N \g__nm_column_int} \seq_gclear_new:N \g__nm_yet_drawn_seq @@ -448,7 +456,6 @@ \__nm_bool_new:N \l__nm_final_open_bool \g__nm_lines_to_draw_tl} \tl_gclear:N \g__nm_lines_to_draw_tl - \group_begin: \tikzset{every~picture/.style = {overlay, remember~picture, name~prefix = nm-\int_use:N \g__nm_env_int-}} @@ -757,6 +764,8 @@ \dim_zero_new:N \g__nm_y_initial_dim \dim_zero_new:N \g__nm_x_final_dim \dim_zero_new:N \g__nm_y_final_dim + \__nm_bool_new:N \l__nm_initial_open_bool + \__nm_bool_new:N \l__nm_final_open_bool \begin{tikzpicture} \path~(#1)~--~(#2)~node[at~start]~(i)~{}~node[at~end]~(f)~{} ; \tikz@parse@node\pgfutil@firstofone (i) @@ -841,22 +850,11 @@ >{\int_gincr:N \g__nm_column_int \int_gset:Nn \g__nm_column_total_int {\int_max:nn \g__nm_column_total_int \g__nm_column_int} - \hbox_set:Nw \l_tmpa_box - \tikz[remember~picture, inner~sep=0pt, minimum~width=0pt, baseline] - \node [anchor=base, - name = nm-\int_use:N \g__nm_env_int- - \int_use:N \g__nm_row_int- - \int_use:N \g__nm_column_int, - alias = \tl_if_empty:NF \l__nm_name_tl - {\l__nm_name_tl- - \int_use:N \g__nm_row_int- - \int_use:N \g__nm_column_int}] - \bgroup $ % $ + \hbox_set:Nw \l_tmpa_box $ % $ \l__nm_code_for_last_col_tl } l <{ $ % $ - \egroup ; \hbox_set_end: \dim_gset:Nn \g__nm_width_last_col_dim {\dim_max:nn \g__nm_width_last_col_dim @@ -866,7 +864,16 @@ {\skip_horizontal:n { 2\arraycolsep + \l__nm_right_margin_dim + \l__nm_extra_right_margin_dim} - \box_use:N \l_tmpa_box}}}} + \tikz[remember~picture, inner~sep=0pt, minimum~width=0pt, baseline] + \node [anchor=base, + name = nm-\int_use:N \g__nm_env_int- + \int_use:N \g__nm_row_int- + \int_use:N \g__nm_column_int, + alias = \tl_if_empty:NF \l__nm_name_tl + {\l__nm_name_tl- + \int_use:N \g__nm_row_int- + \int_use:N \g__nm_column_int}] + {\box_use:N \l_tmpa_box} ; } }}} \NewDocumentEnvironment{NiceArrayCwithDelims} {mm O{} m O{}} {\dim_gzero_new:N \g__nm_width_last_col_dim \keys_set:nn {NiceMatrix/NiceArrayC} {#3,#5} @@ -901,6 +908,7 @@ nullify-dots .bool_set:N = \l__nm_nullify_dots_bool , nullify-dots .default:n = true, code-for-first-row .tl_set:N = \l__nm_code_for_first_row_tl, + code-for-first-row .value_required:n = true, code-for-last-col .tl_set:N = \l__nm_code_for_last_col_tl, code-for-last-col .value_required:n = true, columns-width .code:n = \str_if_eq:nnTF {#1} {auto} |