From b74f40314c53a9b3e912e4e81e4729a6ba6f4327 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Wed, 23 Jan 2019 21:29:12 +0000 Subject: fancypar (23jan19) git-svn-id: svn://tug.org/texlive/trunk@49801 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf-dist/tex/latex/fancypar/fancypar.sty | 29 +++++++++++++---------- 1 file changed, 16 insertions(+), 13 deletions(-) (limited to 'Master/texmf-dist/tex/latex/fancypar') diff --git a/Master/texmf-dist/tex/latex/fancypar/fancypar.sty b/Master/texmf-dist/tex/latex/fancypar/fancypar.sty index ea9ac90276a..8cbd3761e94 100644 --- a/Master/texmf-dist/tex/latex/fancypar/fancypar.sty +++ b/Master/texmf-dist/tex/latex/fancypar/fancypar.sty @@ -6,7 +6,7 @@ %% %% fancypar.dtx (with options: `package') %% -%% Copyright (C) 2010 Gonzalo Medina (gmedinaar@unal.edu.co) +%% Copyright (C) 2010, 2019 Gonzalo Medina (gmedinaar@unal.edu.co) %% %% -------------------------------------------------------------------------- %% @@ -26,7 +26,7 @@ %% and the derived files fancypar.sty and fancypar.pdf. %% \NeedsTeXFormat{LaTeX2e} -\ProvidesPackage{fancypar}[2010/04/25 v1.1 fancy paragraphs] +\ProvidesPackage{fancypar}[2019/01/18 v1.2 fancy paragraphs] \@ifpackageloaded{xkeyval}{}{\RequirePackage{xkeyval}} \@ifpackageloaded{tikz}{\usetikzlibrary{calc}} @@ -67,7 +67,7 @@ \def\FancyMarkPosition{\llap{\mbox{\FancyMark\quad}}\box\linebox} \or \def\FancyMarkPosition{\box\linebox\rlap{\mbox{\quad\FancyMark}}} - \fi + \fi }{% \PackageWarning{fancypar}{erroneous input ignored}% } @@ -107,7 +107,7 @@ } %%%% notebook %%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\newcommand*\NotebookPar[2][]{% +\newcommand\NotebookPar[2][]{% \begingroup \setkeys[FP]{fancypar}{#1} \renewcommand\FancyPreFormat{\smallskip} @@ -135,7 +135,9 @@ \node (a) {\colorbox{\FancyNlColor}{% \vbox{% \vskip-0.5mm\parshape 1 0cm \FancyNTWidth% - #2\par\add@fancy@format% + \def\par{{\@@par}}% A trick that executes the real "par" = \@@par inside a group so that the parshape is restored. Thanks to Frank Mittelbach. + #2\@@par + \add@fancy@format% }% }% } {}; @@ -145,8 +147,8 @@ } \newcounter{fancycount} -\newcommand*\FancyZColor{} -\renewcommand*\FancyZColor{%alternate line colors +\newcommand\FancyZColor{} +\renewcommand\FancyZColor{%alternate line colors \ifodd\thefancycount % \FancyZColorOne% \else @@ -154,8 +156,8 @@ \fi } -\newcommand*\FancyZTextColor{} -\renewcommand*\FancyZTextColor{%alternate text colors +\newcommand\FancyZTextColor{} +\renewcommand\FancyZTextColor{%alternate text colors \ifodd\thefancycount % \FancyZTextColorOne% \else @@ -164,7 +166,7 @@ } %%%% zebra %%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\newcommand*\ZebraPar[2][]{% +\newcommand\ZebraPar[2][]{% \begingroup \setkeys[FP]{fancypar}{#1}% \renewcommand\FancyPreFormat{\setcounter{fancycount}{0}}% @@ -186,7 +188,7 @@ } %%%% dashed %%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\newcommand*\DashedPar[2][]{% +\newcommand\DashedPar[2][]{% \begingroup \setkeys[FP]{fancypar}{#1}% \renewcommand\FancyPreFormat{% @@ -205,7 +207,7 @@ }% %%%% marked %%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\newcommand*\MarkedPar[2][]{% +\newcommand\MarkedPar[2][]{% \begingroup \setkeys[FP]{fancypar}{#1} \renewcommand\FancyPreFormat{} @@ -220,7 +222,7 @@ } %%%% underlined %%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\newcommand*\UnderlinedPar[2][]{ +\newcommand\UnderlinedPar[2][]{ \begingroup \setkeys[FP]{fancypar}{#1} \renewcommand\FancyPreFormat{}% @@ -240,6 +242,7 @@ \ifvoid\linebox\FancyPreFormat\else \unskip \unpenalty + \unskip %Allows more than one paragraph in MarkedPar, DashedPar, ZebraPar, and UnderlinedPar. Thanks to Frank Mittelbach {\add@fancy@format}% \FancyFormat \fi -- cgit v1.2.3