diff options
Diffstat (limited to 'macros/latex-dev/required/tools/verbatim.dtx')
-rw-r--r-- | macros/latex-dev/required/tools/verbatim.dtx | 31 |
1 files changed, 24 insertions, 7 deletions
diff --git a/macros/latex-dev/required/tools/verbatim.dtx b/macros/latex-dev/required/tools/verbatim.dtx index 832f80ef3a..468dead3e8 100644 --- a/macros/latex-dev/required/tools/verbatim.dtx +++ b/macros/latex-dev/required/tools/verbatim.dtx @@ -1,6 +1,6 @@ % \iffalse meta-comment % -% Copyright (C) 1993-2023 +% Copyright (C) 1993-2024 % % The LaTeX Project and any individual authors listed elsewhere % in this file. @@ -55,7 +55,7 @@ \and Chris Rowley} -\date{2023/07/08} +\date{2023/11/06} \begin{document} \markboth{Verbatim style option}{Verbatim style option} \MaintainedByLaTeXTeam{tools} @@ -69,6 +69,8 @@ %\fi % % +% +% \changes{v1.5x}{2024/01/22}{Added TAB marking support to \cs{verbatiminput*}} % \changes{v1.5u}{2020-07-07}{Typo repair and added a missing comment % character} % \changes{v1.5q}{2003/08/22}{Reintroduced \cs{@noligs}, by popular @@ -508,7 +510,7 @@ %<*package> \NeedsTeXFormat{LaTeX2e} \ProvidesPackage{verbatim} - [2022-07-02 v1.5u LaTeX2e package for verbatim enhancements] + [2024-01-22 v1.5x LaTeX2e package for verbatim enhancements] \@ifundefined{verbatim@@@}{}{\endinput} % \end{macrocode} % @@ -549,9 +551,17 @@ % to be printed as spaces in the output. % \begin{macrocode} \begingroup - \catcode`\ =\active% - \def\x{\def\@vobeyspaces{\catcode`\ \active\let \@xobeysp}} - \expandafter\endgroup\x +\catcode`\ =\active% +% \end{macrocode} +% Because space is active we can't indent the following code +% nicely---we would then get the spaces at the beginning of the +% line as the third and fourth argument to \cs{@ifl@t@r}. +% \changes{v1.5v}{2023/11/06}{\cs{@vobeytabs} added when available (gh/1160)} +% \begin{macrocode} +\@ifl@t@r\fmtversion{2023-11-01}% +{\def\x{\def\@vobeyspaces{\catcode`\ \active\let \@xobeysp\@vobeytabs}}}% +{\def\x{\def\@vobeyspaces{\catcode`\ \active\let \@xobeysp}}}% +\expandafter\endgroup\x % \end{macrocode} % \end{macro} % @@ -1562,7 +1572,14 @@ % arguments, depending on whether an asterisk follows. % \begin{macrocode} \def\verbatiminput{\begingroup - \@ifstar{\verbatim@input\relax}% +% \end{macrocode} +% +% \changes{v1.5x}{2024/01/22}{Added TAB marking support into the +% starred version (gh/1245)} +% If starred, we mark spaces and TABs, the two +% added pieces are the same as for verbatim*. +% \begin{macrocode} + \@ifstar{\verbatim@input{\@setupverbvisiblespace\@vobeyspaces}}% {\verbatim@input{\frenchspacing\@vobeyspaces}}} % \end{macrocode} % \end{macro} |