texlive[54657] Master/texmf-dist: curve2e (10apr20)

commits+karl at tug.org commits+karl at tug.org
Sun Apr 12 00:22:35 CEST 2020


Revision: 54657
          http://tug.org/svn/texlive?view=revision&revision=54657
Author:   karl
Date:     2020-04-12 00:22:35 +0200 (Sun, 12 Apr 2020)
Log Message:
-----------
curve2e (10apr20)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/latex/curve2e/README.txt
    trunk/Master/texmf-dist/doc/latex/curve2e/curve2e-manual.pdf
    trunk/Master/texmf-dist/doc/latex/curve2e/curve2e-manual.tex
    trunk/Master/texmf-dist/doc/latex/curve2e/curve2e.pdf
    trunk/Master/texmf-dist/source/latex/curve2e/curve2e.dtx
    trunk/Master/texmf-dist/tex/latex/curve2e/curve2e.sty

Modified: trunk/Master/texmf-dist/doc/latex/curve2e/README.txt
===================================================================
--- trunk/Master/texmf-dist/doc/latex/curve2e/README.txt	2020-04-11 22:22:22 UTC (rev 54656)
+++ trunk/Master/texmf-dist/doc/latex/curve2e/README.txt	2020-04-11 22:22:35 UTC (rev 54657)
@@ -10,7 +10,7 @@
 %%   License information appended
 %% 
 File README.txt for package curve2e
-        [2020-02-28 v.2.2.3 Extension package for pict2e]
+        [2020-04-02 v.2.2.6 Extension package for pict2e]
 The package bundle curve2e is composed of the following files
 
 curve2e.dtx

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

Modified: trunk/Master/texmf-dist/doc/latex/curve2e/curve2e-manual.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/curve2e/curve2e-manual.tex	2020-04-11 22:22:22 UTC (rev 54656)
+++ trunk/Master/texmf-dist/doc/latex/curve2e/curve2e-manual.tex	2020-04-11 22:22:35 UTC (rev 54657)
@@ -36,17 +36,19 @@
 \renewcommand\cs[1]{{\normalfont\texttt{\char92#1}}}
 
 \providecommand\Pbox{}
-\RenewDocumentCommand\Pbox{D(){0,0} O{cc} m O{0.5ex}}{%
-\put(#1){%
-\dimendef\Dim=2566\relax
-\settowidth\Dim{#2}%
-\edef\Rapp{\fpeval{\Dim/{1ex}}}%
+\newlength\PbDim
+\RenewDocumentCommand\Pbox{D(){0,0} O{cc} m O{0.5ex} s D<>{0}}{%
+\put(#1){\rotatebox{#6}{\makebox(0,0){%
+\settowidth\PbDim{#2}%
+\edef\Rapp{\fpeval{\PbDim/{1ex}}}%
 \fptest{\Rapp > 1.5}{\fboxsep=0.5ex}{\fboxsep=0.75ex}%
-\fboxrule=0pt
-\fptest{#4 = 0sp}{\makebox(0,0)[#2]{\fbox{$\relax#3\relax$}}}%
-{\edef\Diam{\fpeval{#4/\unitlength}}%
-\makebox(0,0){\circle*{\Diam}}%
-\makebox(0,0)[#2]{\fbox{$\relax\mathsf#3\relax$}}}%
+\IfBooleanTF{#5}{\fboxrule=0.4pt}{\fboxrule=0pt}%
+\fptest{#4 = 0sp}%
+  {\makebox(0,0)[#2]{\fbox{$\relax#3\relax$}}}%
+  {\edef\Diam{\fpeval{(#4)/\unitlength}}%
+   \makebox(0,0){\circle*{\Diam}}%
+   \makebox(0,0)[#2]{\fbox{$\relax\mathsf#3\relax$}}%
+  }}}%
 }\ignorespaces}
 
 \def\LissajousCoefs#1,#2,#3,#4,#5,#6!{%

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

Modified: trunk/Master/texmf-dist/source/latex/curve2e/curve2e.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/curve2e/curve2e.dtx	2020-04-11 22:22:22 UTC (rev 54656)
+++ trunk/Master/texmf-dist/source/latex/curve2e/curve2e.dtx	2020-04-11 22:22:35 UTC (rev 54657)
@@ -46,7 +46,7 @@
 %<+package>\ProvidesPackage{curve2e}%
 %<+readme>File README.txt for package curve2e
 %<*package|readme>
-        [2020-02-28 v.2.2.3 Extension package for pict2e]
+        [2020-04-02 v.2.2.6 Extension package for pict2e]
 %</package|readme>
 %<*driver>
 \documentclass{ltxdoc}\errorcontextlines=9
@@ -81,17 +81,19 @@
 \renewcommand\eTeX{\lower0.5ex\hbox{$\varepsilon\!$}\TeX}
 
 \providecommand\Pbox{}
-\RenewDocumentCommand\Pbox{D(){0,0} O{cc} m O{0.5ex}}{%
-\put(#1){%
-\dimendef\Dim=2566\relax
-\settowidth\Dim{#2}%
-\edef\Rapp{\fpeval{\Dim/{1ex}}}%
+\newlength\PbDim
+\RenewDocumentCommand\Pbox{D(){0,0} O{cc} m O{0.5ex} s D<>{0}}{%
+\put(#1){\rotatebox{#6}{\makebox(0,0){%
+\settowidth\PbDim{#2}%
+\edef\Rapp{\fpeval{\PbDim/{1ex}}}%
 \fptest{\Rapp > 1.5}{\fboxsep=0.5ex}{\fboxsep=0.75ex}%
-\fboxrule=0pt
-\fptest{#4 = 0sp}{\makebox(0,0)[#2]{\fbox{$\relax#3\relax$}}}%
-{\edef\Diam{\fpeval{#4/\unitlength}}%
-\makebox(0,0){\circle*{\Diam}}%
-\makebox(0,0)[#2]{\fbox{$\relax\mathsf#3\relax$}}}%
+\IfBooleanTF{#5}{\fboxrule=0.4pt}{\fboxrule=0pt}%
+\fptest{#4 = 0sp}%
+  {\makebox(0,0)[#2]{\fbox{$\relax#3\relax$}}}%
+  {\edef\Diam{\fpeval{(#4)/\unitlength}}%
+   \makebox(0,0){\circle*{\Diam}}%
+   \makebox(0,0)[#2]{\fbox{$\relax\mathsf#3\relax$}}%
+  }}}%
 }\ignorespaces}
 
 \def\LissajousCoefs#1,#2,#3,#4,#5,#6!{%
@@ -181,7 +183,7 @@
 %</driver>
 % \fi
 %
-% \CheckSum{5581}
+% \CheckSum{5594}
 % \begin{abstract}
 % This file documents the |curve2e| extension package to  the |pict2e|
 % bundle implementation; the latter was described by Lamport
@@ -486,6 +488,11 @@
 % necessary any more, but it's true that it became imperative when older
 % versions were used.
 %
+% Some others users spotted other “features” that did not produce the
+% desired results; they have been acknowledged by footnotes in
+% correspondence with the corrections that were made tanks their
+% contribution.
+%
 % \StopEventually{%
 % \begin{thebibliography}{9}
 % \bibitem{pict2e} Gäßlein H.,  Niepraschk R., and Tkadlec J.
@@ -1000,7 +1007,7 @@
     {\IfNoValueTF{#3}{\PackageError{curve2e}
       {\string\multiput\space Increment components missing}%
       {Nothing done}
-    }
+    }%
     {\put(#1){\let\c at multicnt\@multicnt
       \CopyVect #2 to \R 
       \CopyVect#3 to\D 
@@ -1009,9 +1016,9 @@
           \put(\R){#5}%
           \IfValueTF{#6}{#6}{\AddVect#3 and\R to \R}%
           \advance\@multicnt\m at ne
-        }
-      }
-    }
+        }%
+      }%
+    }%
   }\ignorespaces
 }
 %    \end{macrocode}
@@ -1637,7 +1644,7 @@
 %    \begin{macrocode}
 \def\ArgOfVect#1to#2{\GetCoord(#1){\t at X}{\t at Y}%
 \fptest{\t at X=\z@ && \t at Y=\z@}{\edef#2{0}%
-\PackageWarning{curve2e}{Null vector}{Check your data\Messagebreak
+\PackageWarning{curve2e}{Null vector}{Check your data\MessageBreak
 Computations go on, but the results may be meaningless}}{%
 \edef#2{\fpeval{round(atand(\t at Y,\t at X),6)}}}\ignorespaces}
 %    \end{macrocode}
@@ -2690,10 +2697,22 @@
 % the distances of the control points from the adjacent nodes using the
 % half chord length, not the full length. We also distinguish between the
 % computations relative to the arc starting point and those relative to
-% the end point.
+% the end point. Notice that if the directions of two successive nodes are
+% identical, it is necessary to draw a line, not a third order
+% spline\footnote{Many thanks to John Hillas who spotted this bug, that
+% passed unnoticed fora long time, because it is a very unusual situation.};
+% therefore it is necessary to make a suitable test that is more
+% comfortable to do after the chord has been rotated to be horizontal;
+% in facts, if the two directions are equal, the vertical componente
+% of the directions are both  vanishing values; probably, instead of
+% testing with respect to zero, it might be advisable to test the
+% absolute value with respect to a small number such as, for example,
+% “1.e-6.”
 %
 %    \begin{macrocode}
-\ifdim\@DXpzero\p@=\z@
+\fptest{\@DYpuno=0 && \@DYpzero=0}{\GetCoord(\@Puno)\@tX\@tY
+  \pIIe at lineto{\@tX\unitlength}{\@tY\unitlength}}%
+{\ifdim\@DXpzero\p@=\z@
    \@tdA=1.333333\p@
    \Numero\@KCzero{\@semichord\@tdA}%
 \fi
@@ -2757,7 +2776,7 @@
 \GetCoord(\@CPuno)\@XCPuno\@YCPuno
 \pIIe at curveto{\@XCPzero\unitlength}{\@YCPzero\unitlength}%
              {\@XCPuno\unitlength}{\@YCPuno\unitlength}%
-             {\@XPuno\unitlength}{\@YPuno\unitlength}\egroup
+             {\@XPuno\unitlength}{\@YPuno\unitlength}}\egroup
 %    \end{macrocode}
 % It does not have to stroke the curve because other Bézier splines
 % might still be added to the path. On the opposite it memorises the
@@ -2774,7 +2793,10 @@
 % selected color, while the latter just strokes the path. Both 
 % recursively examine an arbitrary list of nodes and directions; node
 % coordinates are grouped within round parentheses while direction
-% components are grouped within angle brackets. The first call of the
+% components are grouped within angle brackets. Before testing for a
+% possible star, this initial command kills any space or glue that
+% might precede it\footnote{Thanks to John Hillas who spotted the
+% effects of this missing glue elimination.} The first call of the
 % macro initialises the drawing process and checks for the next node and
 % direction; if a second node is missing, it issues a warning message and
 % does not draw anything. It does not check for a change in direction,
@@ -2791,7 +2813,7 @@
 % regular |\ChangeDir| macro, but also for recursing again by recalling
 % |\@Curve|.
 %    \begin{macrocode}
-\def\Curve{\@ifstar{\let\fillstroke\fillpath\Curve@}%
+\def\Curve{\@killglue\@ifstar{\let\fillstroke\fillpath\Curve@}%
 {\let\fillstroke\strokepath\Curve@}}
 
 \def\Curve@(#1)<#2>{%

Modified: trunk/Master/texmf-dist/tex/latex/curve2e/curve2e.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/curve2e/curve2e.sty	2020-04-11 22:22:22 UTC (rev 54656)
+++ trunk/Master/texmf-dist/tex/latex/curve2e/curve2e.sty	2020-04-11 22:22:35 UTC (rev 54657)
@@ -11,7 +11,7 @@
 %% 
 \NeedsTeXFormat{LaTeX2e}[2019/01/01]
 \ProvidesPackage{curve2e}%
-        [2020-02-28 v.2.2.3 Extension package for pict2e]
+        [2020-04-02 v.2.2.6 Extension package for pict2e]
 \IfFileExists{xfp.sty}{%
   \RequirePackage{color}
   \RequirePackageWithOptions{pict2e}[2014/01/01]
@@ -161,7 +161,7 @@
     {\IfNoValueTF{#3}{\PackageError{curve2e}
       {\string\multiput\space Increment components missing}%
       {Nothing done}
-    }
+    }%
     {\put(#1){\let\c at multicnt\@multicnt
       \CopyVect #2 to \R
       \CopyVect#3 to\D
@@ -170,9 +170,9 @@
           \put(\R){#5}%
           \IfValueTF{#6}{#6}{\AddVect#3 and\R to \R}%
           \advance\@multicnt\m at ne
-        }
-      }
-    }
+        }%
+      }%
+    }%
   }\ignorespaces
 }
 \NewDocumentCommand{\xmultiput}{O{0,0} d() d() m m o }{%
@@ -315,7 +315,7 @@
 \def\CosOf#1to#2{\edef#2{\fpeval{round(cosd#1,6)}}}\relax
 \def\ArgOfVect#1to#2{\GetCoord(#1){\t at X}{\t at Y}%
 \fptest{\t at X=\z@ && \t at Y=\z@}{\edef#2{0}%
-\PackageWarning{curve2e}{Null vector}{Check your data\Messagebreak
+\PackageWarning{curve2e}{Null vector}{Check your data\MessageBreak
 Computations go on, but the results may be meaningless}}{%
 \edef#2{\fpeval{round(atand(\t at Y,\t at X),6)}}}\ignorespaces}
 \def\MakeVectorFrom#1#2to#3{\edef#3{#1,#2}\ignorespaces}%
@@ -615,7 +615,9 @@
 \GetCoord(\@Dpzero)\@DXpzero\@DYpzero
 \GetCoord(\@Dpuno)\@DXpuno\@DYpuno
 \DivideFN\@Chord by2 to\@semichord
-\ifdim\@DXpzero\p@=\z@
+\fptest{\@DYpuno=0 && \@DYpzero=0}{\GetCoord(\@Puno)\@tX\@tY
+  \pIIe at lineto{\@tX\unitlength}{\@tY\unitlength}}%
+{\ifdim\@DXpzero\p@=\z@
    \@tdA=1.333333\p@
    \Numero\@KCzero{\@semichord\@tdA}%
 \fi
@@ -662,11 +664,11 @@
 \GetCoord(\@CPuno)\@XCPuno\@YCPuno
 \pIIe at curveto{\@XCPzero\unitlength}{\@YCPzero\unitlength}%
              {\@XCPuno\unitlength}{\@YCPuno\unitlength}%
-             {\@XPuno\unitlength}{\@YPuno\unitlength}\egroup
+             {\@XPuno\unitlength}{\@YPuno\unitlength}}\egroup
 \CopyVect\@Puno to\@Pzero
 \CopyVect\@Duno to\@Dzero
 \ignorespaces}%
-\def\Curve{\@ifstar{\let\fillstroke\fillpath\Curve@}%
+\def\Curve{\@killglue\@ifstar{\let\fillstroke\fillpath\Curve@}%
 {\let\fillstroke\strokepath\Curve@}}
 
 \def\Curve@(#1)<#2>{%



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