texlive[65585] Master/texmf-dist: fancyvrb (19jan23)

commits+karl at tug.org commits+karl at tug.org
Thu Jan 19 22:02:19 CET 2023


Revision: 65585
          http://tug.org/svn/texlive?view=revision&revision=65585
Author:   karl
Date:     2023-01-19 22:02:19 +0100 (Thu, 19 Jan 2023)
Log Message:
-----------
fancyvrb (19jan23)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/latex/fancyvrb/Changes
    trunk/Master/texmf-dist/doc/latex/fancyvrb/fancyvrb-doc.pdf
    trunk/Master/texmf-dist/doc/latex/fancyvrb/fancyvrb-doc.tex
    trunk/Master/texmf-dist/tex/latex/fancyvrb/fancyvrb.sty

Modified: trunk/Master/texmf-dist/doc/latex/fancyvrb/Changes
===================================================================
--- trunk/Master/texmf-dist/doc/latex/fancyvrb/Changes	2023-01-19 21:01:53 UTC (rev 65584)
+++ trunk/Master/texmf-dist/doc/latex/fancyvrb/Changes	2023-01-19 21:02:19 UTC (rev 65585)
@@ -1,4 +1,5 @@
 --- fancyvrb.sty
+4.5a 2023/01/19   - modified documentation (hv)
 4.5  2022/06/06   - added \noniterlineskip for frame=lines (hv)
 4.4  2022/06/03   - fix for deleted \@penalty command _before_ top rule(hv)
 4.3  2022/06/02   - prevent pagebreak after top rule (hv)

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

Modified: trunk/Master/texmf-dist/doc/latex/fancyvrb/fancyvrb-doc.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/fancyvrb/fancyvrb-doc.tex	2023-01-19 21:01:53 UTC (rev 65584)
+++ trunk/Master/texmf-dist/doc/latex/fancyvrb/fancyvrb-doc.tex	2023-01-19 21:02:19 UTC (rev 65585)
@@ -1,7 +1,7 @@
 \listfiles
 \documentclass[twoside]{article}
-\usepackage{libertinus-otf}
-\setmonofont[Scale=MatchLowercase,FakeStretch=0.9]{AnonymousPro-Regular.ttf}
+\usepackage[TT={Scale=MatchLowercase,FakeStretch=0.88}]{lucida-otf}
+\setmonofont[Scale=MatchLowercase,FakeStretch=0.85]{DejaVu Sans Mono}
 \newif\ifChangeBar \ChangeBarfalse
 \usepackage{fancyvrb}
 \usepackage{fancyvrb-ex}
@@ -261,15 +261,24 @@
   \item[formatcom (command)]: command to execute before printing verbatim
   text
   (\emph{Default: empty}).
+  \item[formatcom* (command)]: add definition to an existing one
 \end{optlist}
 
 \begin{SideBySideExample}
-  \begin{Verbatim}[formatcom=\color{red}]
-    First verbatim line.
-    Second verbatim line.
-  \end{Verbatim}
+\begin{Verbatim}[formatcom=\color{red}]
+First verbatim line.
+Second verbatim line.
+\end{Verbatim}
 \end{SideBySideExample}
 
+\begin{SideBySideExample}
+\fvset{formatcom=\color{red}}
+\begin{Verbatim}[formatcom*=\itshape]
+First verbatim line.
+Second verbatim line.
+\end{Verbatim}
+\end{SideBySideExample}
+
 \subsubsection{Changing individual line formatting}
 
   The macro \cs{FancyVerbFormatLine} defines the way each line is formatted.
@@ -965,22 +974,40 @@
 \begin{optlist}
   \item[codes (macro)]: to specify \emph{catcode} changes (\emph{Default:
   empty}).
+  \item[codes* (macro)]: add to an existing definition.
 \end{optlist}
 
   For instance, this allows us to include formatted mathematics in verbatim
 text:
 
-{\fvset{fontsize=\small}
+{\fvset{fontsize=\small}%
 \begin{SideBySideExample}
-  Z\fvset{fontsize=\normalsize}
-  \begin{Verbatim}[commandchars=\\\{\},
+\begin{Verbatim}[commandchars=\\\{\},
          codes={\catcode`$=3\catcode`^=7}]
     x=1/sqrt(z**2) ! $\frac{1}{\sqrt{z^2}}$
-  \end{Verbatim}
+\end{Verbatim}
 \end{SideBySideExample}
 }  %$
 
 
+With \verb|codes*| we can add code to an already existing definition of \Verb|codes|:
+
+{\fvset{fontsize=\small}%
+\begin{SideBySideExample}
+\fvset{codes={\catcode`$=3\catcode`^=7}}
+\begin{Verbatim}[commandchars=\\\{\},
+   % _add_ to codes
+   codes*={\color{blue}}]
+x=1/sqrt(z**2) ! $\frac{1}{\sqrt{z^2}}$
+\end{Verbatim}
+\end{SideBySideExample}
+}  %$
+
+
+
+
+
+
 \subsubsection{Active characters}
 
 \begin{optlist}
@@ -987,6 +1014,7 @@
   \item[defineactive (macro)]: to define the effect of \emph{active}
   characters
   (\emph{Default: empty}).
+  \item[defineactive* (macro)]: add the definition to an existing one.
 \end{optlist}
 
   This allows us to do some devious tricks: see the example in Section

Modified: trunk/Master/texmf-dist/tex/latex/fancyvrb/fancyvrb.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/fancyvrb/fancyvrb.sty	2023-01-19 21:01:53 UTC (rev 65584)
+++ trunk/Master/texmf-dist/tex/latex/fancyvrb/fancyvrb.sty	2023-01-19 21:02:19 UTC (rev 65585)
@@ -2,7 +2,7 @@
 %% This is file `fancyvrb.sty',
 %%
 %% COPYRIGHT 1992-1999, by Timothy Van Zandt <tvz at zandtwerk.kellogg.nwu.edu>
-%%           2000-2022 ... , by Herbert Voss <hvoss at tug.org>
+%%           2000-2023 ... , by Herbert Voss <hvoss at tug.org>
 %%
 %% This package may be distributed under the terms of the LaTeX Project Public
 %% License, as described in lppl.txt in the base LaTeX distribution.
@@ -13,8 +13,8 @@
 %%   verbatim environments and commands and extensive documentation.
 %%
 \NeedsTeXFormat{LaTeX2e}
-\def\fileversion{4.5}
-\def\filedate{2022/06/06}
+\def\fileversion{4.5a}
+\def\filedate{2023/01/19}
 \ProvidesPackage{fancyvrb}[\filedate\space \fileversion\space verbatim text (tvz,hv)]
 %\message{Style option: `fancyvrb' v\fileversion \space  <\filedate> (tvz)}
 \csname fancyvrb at loaded\endcsname
@@ -827,7 +827,8 @@
 %% DG/SR modification end
   \penalty\@M
   \FV at SingleFrameSep
-  \penalty\@M}
+  \penalty\@M
+}
 %% DG/SR modification begin - May. 19, 1998
 \define at key{FV}{label}{%
   \def\@tempa{#1}%
@@ -868,7 +869,7 @@
 \def\FV at SingleFrameLine#1{%
   \hbox to\z@{%
     \kern\leftmargin
-    \ifnum#1=\z@
+    \ifnum#1=\z@%   top line?
       \let\FV at Label\FV at LabelBegin
     \else
       \let\FV at Label\FV at LabelEnd
@@ -876,7 +877,7 @@
     \ifx\FV at Label\relax
       \FancyVerbRuleColor{\vrule \@width\linewidth \@height\FV at FrameRule}%
     \else
-      \ifnum#1=\z@
+      \ifnum#1=\z@% top line
         \setbox\z@\hbox{\strut\enspace\FV at LabelBegin\enspace\strut}%
       \else
         \setbox\z@\hbox{\strut\enspace\FV at LabelEnd\enspace\strut}%



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