diff options
author | Karl Berry <karl@freefriends.org> | 2021-03-04 22:04:33 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2021-03-04 22:04:33 +0000 |
commit | 36076825de930027e22a2cda4e56dfc5cbd16c50 (patch) | |
tree | 18b3e978bda7e9bad72db1b0fb1ec4d91146ed92 /Master/texmf-dist/tex | |
parent | 63440db1104e290e1c083946a1c04136c92ab771 (diff) |
witharrows (4mar21)
git-svn-id: svn://tug.org/texlive/trunk@58120 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex')
-rw-r--r-- | Master/texmf-dist/tex/generic/witharrows/witharrows.sty | 62 |
1 files changed, 49 insertions, 13 deletions
diff --git a/Master/texmf-dist/tex/generic/witharrows/witharrows.sty b/Master/texmf-dist/tex/generic/witharrows/witharrows.sty index 3a9b68ff7fb..2eaeb3c7b33 100644 --- a/Master/texmf-dist/tex/generic/witharrows/witharrows.sty +++ b/Master/texmf-dist/tex/generic/witharrows/witharrows.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.6b} -\def\myfiledate{2021/01/31} +\def\myfileversion{2.6c} +\def\myfiledate{2021/03/04} \RequirePackage{tikz} \usetikzlibrary{arrows.meta,bending} \RequirePackage{l3keys2e} @@ -34,8 +34,9 @@ You~can~go~on~but~you~will~probably~have~other~errors~ if~you~use~the~functionalities~of~witharrows. } -\cs_if_exist:NF \l_keys_key_str +\cs_if_exist:NF \seq_set_map_x:NNn { \msg_error:nn { witharrows } { expl3~too~old } } +\RequirePackage { xparse } \RequirePackage { varwidth } \bool_new:N \c__witharrows_footnotehyper_bool \bool_new:N \c__witharrows_footnote_bool @@ -1867,6 +1868,21 @@ } ; \end{tikzpicture} } +\str_new:N \l_witharrows_body_str +\cs_new:Npn \__witharrows_potential_body_i: + { + \str_if_empty:NF \l_witharrows_body_str + { \\ If~you~want~to~see~the~body~of~the~environment,~type~H~<return>. } + } +\cs_new:Npn \__witharrows_potential_body_ii: + { + \str_if_empty:NTF \l_nicematrix_body_str + { No~further~help~available } + { + The~body~of~your~environment~was:\\ + \l_witharrows_body_str + } + } \str_const:Nn \c__witharrows_option_ignored_str { If~you~go~on,~this~option~will~be~ignored. } \str_const:Nn \c__witharrows_command_ignored_str @@ -1904,30 +1920,38 @@ (or~another~line)~of~your~environment~\{\l__witharrows_type_env_str\}.\\ You~can~go~on~but~you~may~have~others~errors. } -\__witharrows_msg_new:nn { newline~at~the~end~of~env } +\__witharrows_msg_new:nnn { newline~at~the~end~of~env } { The~environments~of~witharrows~(\{WithArrows\}~and~ \{DispWithArrows\})~should~not~end~by~\token_to_str:N \\.\\ However,~you~can~go~on~for~this~time.~No~similar~error~will~be~ raised~in~this~document. + \__witharrows_potential_body_i: } -\__witharrows_msg_new:nn { Invalid~option~format } + { \__witharrows_potential_body_ii: } +\__witharrows_msg_new:nnn { Invalid~option~format } { The~key~'format'~should~contain~only~letters~r,~c~and~l~and~ must~not~be~empty.\\ \c__witharrows_option_ignored_str + \__witharrows_potential_body_i: } -\__witharrows_msg_new:nn { invalid~key~o } + { \__witharrows_potential_body_ii: } +\__witharrows_msg_new:nnn { invalid~key~o } { The~key~'o'~for~individual~arrows~can~be~used~only~in~mode~ 'group'~or~in~mode~'groups'.\\ \c__witharrows_option_ignored_str + \__witharrows_potential_body_i: } -\__witharrows_msg_new:nn { Value~for~a~key } + { \__witharrows_potential_body_ii: } +\__witharrows_msg_new:nnn { Value~for~a~key } { The~key~'\l_keys_key_str'~should~be~used~without~value. \\ However,~you~can~go~on~for~this~time. + \__witharrows_potential_body_i: } + { \__witharrows_potential_body_ii: } \__witharrows_msg_new:nnn { Unknown~option~in~Arrow } { The~key~'\l_keys_key_str'~is~unknown~for~the~command~ @@ -1983,7 +2007,7 @@ The~available~keys~are~(in~alphabetic~order):~ \seq_use:Nnnn \l__witharrows_options_Arrow_code_after_seq {~and~} {,~} {~and~}. } -\__witharrows_msg_new:nn { Too~much~columns~in~WithArrows } +\__witharrows_msg_new:nnn { Too~much~columns~in~WithArrows } { Your~environment~\{\l__witharrows_type_env_str\}~has~\int_use:N \l__witharrows_nb_cols_int\ columns~and~you~try~to~use~one~more.~ @@ -1991,15 +2015,19 @@ If~you~really~want~to~use~more~columns~(after~the~arrows)~you~should~use~ the~option~'more-columns'~at~a~global~level~or~for~an~environment. \\ However,~you~can~go~one~for~this~time. + \__witharrows_potential_body_i: } -\__witharrows_msg_new:nn { Too~much~columns~in~DispWithArrows } + { \__witharrows_potential_body_ii: } +\__witharrows_msg_new:nnn { Too~much~columns~in~DispWithArrows } { Your~environment~\{\l__witharrows_type_env_str\}~has~\int_use:N \l__witharrows_nb_cols_int\ columns~and~you~try~to~use~one~more.~ Maybe~you~have~forgotten~a~\c_backslash_str\c_backslash_str\ at~the~end~of~row~\int_use:N \g__witharrows_line_int. \\ This~error~is~fatal. + \__witharrows_potential_body_i: } + { \__witharrows_potential_body_ii: } \__witharrows_msg_new:nn { Negative~jump } { You~can't~use~a~negative~value~for~the~option~'jump'~of~command~ @@ -2017,7 +2045,7 @@ 'groups'~in~your~environment~\{\l__witharrows_type_env_str\}. \\ \c__witharrows_option_ignored_str } -\__witharrows_msg_new:nn +\__witharrows_msg_new:nnn { Too~few~lines~for~an~arrow } { Line~\l__witharrows_input_line_str\ @@ -2025,25 +2053,31 @@ of~your~environment~\{\l__witharrows_type_env_str\}~can't~be~drawn~ because~it~arrives~after~the~last~row~of~the~environment. \\ If~you~go~on,~this~arrow~will~be~ignored. + \__witharrows_potential_body_i: } + { \__witharrows_potential_body_ii: } \__witharrows_msg_new:nn { o~arrow~with~no~arrow~under } { Line~\l__witharrows_input_line_str\ :~there~is~no~arrow~'under'~your~arrow~of~type~'o'.\\ If~you~go~on,~this~arrow~won't~be~drawn. } -\__witharrows_msg_new:nn { WithArrows~outside~math~mode } +\__witharrows_msg_new:nnn { WithArrows~outside~math~mode } { The~environment~\{\l__witharrows_type_env_str\}~should~be~used~only~in~math~mode~ like~the~environment~\{aligned\}~of~amsmath. \\ Nevertheless,~you~can~go~on. + \__witharrows_potential_body_i: } -\__witharrows_msg_new:nn { DispWithArrows~in~math~mode } + { \__witharrows_potential_body_ii: } +\__witharrows_msg_new:nnn { DispWithArrows~in~math~mode } { The~environment~\{\l__witharrows_type_env_str\}~should~be~used~only~outside~math~ mode~like~the~environments~\{align\}~and~\{align*\}~of~amsmath. \\ This~error~is~fatal. + \__witharrows_potential_body_i: } + { \__witharrows_potential_body_ii: } \__witharrows_msg_new:nn { Incompatible~options~in~Arrow } { You~try~to~use~the~option~'\l_keys_key_str'~but~ @@ -2063,13 +2097,15 @@ }. \\ \c__witharrows_option_ignored_str } -\__witharrows_msg_new:nn { Arrow~not~in~last~column } +\__witharrows_msg_new:nnn { Arrow~not~in~last~column } { You~should~use~the~command~\l__witharrows_string_Arrow_for_msg_str\ only~in~the~last~column~(column~\int_use:N\l__witharrows_nb_cols_int)~ of~your~environment~\{\l__witharrows_type_env_str\}.\\ However~you~can~go~on~for~this~time. + \__witharrows_potential_body_i: } + { \__witharrows_potential_body_ii: } \__witharrows_msg_new:nn { Wrong~line~in~Arrow } { The~specification~of~line~'#1'~you~use~in~the~command~ |