texlive[45978] Master/texmf-dist: pst-tools (3dec17)

commits+karl at tug.org commits+karl at tug.org
Sun Dec 3 23:19:10 CET 2017


Revision: 45978
          http://tug.org/svn/texlive?view=revision&revision=45978
Author:   karl
Date:     2017-12-03 23:19:10 +0100 (Sun, 03 Dec 2017)
Log Message:
-----------
pst-tools (3dec17)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/generic/pst-tools/Changes
    trunk/Master/texmf-dist/doc/generic/pst-tools/pst-tools-doc.pdf
    trunk/Master/texmf-dist/doc/generic/pst-tools/pst-tools-doc.tex
    trunk/Master/texmf-dist/dvips/pst-tools/pst-tools.pro
    trunk/Master/texmf-dist/tex/generic/pst-tools/pst-tools.tex
    trunk/Master/texmf-dist/tex/latex/pst-tools/pst-tools.sty

Modified: trunk/Master/texmf-dist/doc/generic/pst-tools/Changes
===================================================================
--- trunk/Master/texmf-dist/doc/generic/pst-tools/Changes	2017-12-03 22:18:59 UTC (rev 45977)
+++ trunk/Master/texmf-dist/doc/generic/pst-tools/Changes	2017-12-03 22:19:10 UTC (rev 45978)
@@ -1,4 +1,6 @@
 ..... pst-tools.tex
+0.09b 2017-12-03  - modified pro file
+                  - added PostScript function list to the documentation
 0.09a 2017-11-29  - modified pro file
 0.09  2017-10-04  - renamed macro \psGetElement to \psRegisterList
 0.08  2017-10-02  - new macro \psGetElement
@@ -19,6 +21,7 @@
 
 
 ---- pst-tools.pro
+0.06  2017-11-30  - added function concatarray 
 0.05  2017-11-29  - added function concatstrings 
 0.04  2013-10-26  - added function /ps at reverseOrderOfPoints 
                   - modified /rightTrim

Modified: trunk/Master/texmf-dist/doc/generic/pst-tools/pst-tools-doc.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/doc/generic/pst-tools/pst-tools-doc.tex
===================================================================
--- trunk/Master/texmf-dist/doc/generic/pst-tools/pst-tools-doc.tex	2017-12-03 22:18:59 UTC (rev 45977)
+++ trunk/Master/texmf-dist/doc/generic/pst-tools/pst-tools-doc.tex	2017-12-03 22:19:10 UTC (rev 45978)
@@ -1,6 +1,6 @@
-%% $Id: pst-tools-doc.tex 613 2017-10-04 07:29:50Z herbert $
-\documentclass[11pt,english,BCOR10mm,DIV12,bibliography=totoc,parskip=false,
-   smallheadings, headexclude,footexclude,oneside]{pst-doc}
+%% $Id: pst-tools-doc.tex 675 2017-12-03 08:39:12Z herbert $
+\documentclass[11pt,english,BCOR=10mm,DIV=13,toc=bibliography,parskip=false,
+   headings=small, headinclude=false,footinclude=false,oneside]{pst-doc}
 \usepackage[utf8]{inputenc}
 \usepackage{pst-tools}
 \let\pstToolsFV\fileversion
@@ -213,8 +213,46 @@
 \end{pspicture}
 
 
+\section{List of the defined PostScript functions}
 
+\footnotesize
+\begin{verbatim}
+/Pi2 1.57079632679489661925640 def
+/factorial { % n on stack, returns n! 
+/MoverN { % m n on stack, returns the binomial coefficient m over n
+/ps at ReverseOrderOfPoints { % on stack [P1 P2 P3 ...Pn]=>[Pn,Pn-1,...,P2,P1]
+/cxadd {		% [a1 b1] [a2 b2] = [a1+a2 b1+b2]
+/cxneg {		% [a b]
+/cxsub { cxneg cxadd } def  % same as negative addition
+/cxmul {		% [a1 b1] [a2 b2]
+/cxsqr {		% % [a b]^2 = [a^2-b^2 2ab] = [a2 b2]
+/cxsqrt {		% 
+/cxarg { 		% [a b]->arg(z)=atan(b/a)
+/cxlog {		% [a b]->log[a b] = [a^2-b^2 2ab] = [a2 b2]
+/cxnorm2 {		% [a b]->a^2+b^2
+/cxnorm {		% 
+/cxconj {		% [a b]->[a -b]
+/cxre { 0 get } def	% real value
+/cxim { 1 get } def	% imag value
+/cxrecip {		% [a b]->1/[a b] = ([a -b]/(a^2+b^2)
+/cxmake1 { 0 2 array astore } def % make a complex number, real given
+/cxmake2 { 2 array astore } def	  % dito, both given
+/cxdiv { cxrecip cxmul } def
+/cxrmul {		% [a b] r->[r*a r*b]
+/cxrdiv {		% [a b] r->[1/r*a 1/r*b]
+/cxconv {		% theta->exp(i theta) = cos(theta)+i sin(theta) polar<->cartesian
+/bubblesort { % on stack must be an array [ ... ]
+/concatstringarray{  %  [(a) (b) ... (z)] --> (ab...z)  20100422
+/concatstrings{ % (a) (b) -> (ab)  
+/reversestring { % (aBC) -> (CBa)
+/concatarray{ % [a c] [b d] -> [a c b d]  
+/dot2comma {% on stack a string (...) 
+/rightTrim { % on stack the string and the character number to be stripped  
+/psStringwidth /stringwidth load def
+/psShow /show load def
+\end{verbatim}
 
+\normalsize
 
 \clearpage
 \section{List of all optional arguments for \texttt{pst-tools}}

Modified: trunk/Master/texmf-dist/dvips/pst-tools/pst-tools.pro
===================================================================
--- trunk/Master/texmf-dist/dvips/pst-tools/pst-tools.pro	2017-12-03 22:18:59 UTC (rev 45977)
+++ trunk/Master/texmf-dist/dvips/pst-tools/pst-tools.pro	2017-12-03 22:19:10 UTC (rev 45978)
@@ -1,7 +1,7 @@
 % $Id: pst-tools.pro 842 2013-10-26 10:25:41Z herbert $
 %
 %% PostScript tools prologue for pstricks.tex.
-%% Version 0.05, 2017/11/29
+%% Version 0.06, 2017/12/03
 %%
 %% This program can be redistributed and/or modified under the terms
 %% of the LaTeX Project Public License Distributed from CTAN archives
@@ -210,13 +210,38 @@
   pop  
 } bind def
 %
-/concatstrings % (a) (b) -> (ab)  
-   { exch dup length    
-     2 index length add string    
-     dup dup 4 2 roll copy length
-     4 -1 roll putinterval
-   } bind def
+/concatstrings{ % (a) (b) -> (ab)  
+  1 dict begin
+  exch dup length    
+  2 index length add string    
+  dup dup 4 2 roll copy length
+  4 -1 roll putinterval
+  end
+} def
 %
+/reversestring { % (aBC) -> (CBa)
+  5 dict begin
+  /str exch def
+  /L str length def
+  /strTemp L string def
+  /i 0 def
+  L { 
+    /I L 1 sub i sub def
+    strTemp i str I 1 getinterval putinterval
+    /i i 1 add def
+  } repeat
+  strTemp
+  end
+} def
+%
+/concatarray{ % [a c] [b d] -> [a c b d]  
+  2 dict begin
+  /a2 exch def
+  /a1 exch def
+  [ a1 aload pop a2 aload pop ]
+  end
+} def
+%
 /dot2comma {% on stack a string (...) 
   2 dict begin
   /Output exch def

Modified: trunk/Master/texmf-dist/tex/generic/pst-tools/pst-tools.tex
===================================================================
--- trunk/Master/texmf-dist/tex/generic/pst-tools/pst-tools.tex	2017-12-03 22:18:59 UTC (rev 45977)
+++ trunk/Master/texmf-dist/tex/generic/pst-tools/pst-tools.tex	2017-12-03 22:19:10 UTC (rev 45978)
@@ -1,4 +1,4 @@
-%% $Id: pst-tools.tex 666 2017-11-29 19:00:27Z herbert $
+%% $Id: pst-tools.tex 674 2017-12-02 22:04:53Z herbert $
 %%
 %% This is file `pst-tools.tex',
 %%
@@ -26,8 +26,8 @@
 % interface to the `xkeyval' package
 \pst at addfams{pst-tools}
 %
-\def\fileversion{0.09a}
-\def\filedate{2017/11/29}
+\def\fileversion{0.09b}
+\def\filedate{2017/12/03}
 \message{`PST-tools' v\fileversion, \filedate\space (hv)}
 %
 \define at key[psset]{pst-tools}{decimalSeparator}[.]{\def\psk at decimalSeparator{#1}}%

Modified: trunk/Master/texmf-dist/tex/latex/pst-tools/pst-tools.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/pst-tools/pst-tools.sty	2017-12-03 22:18:59 UTC (rev 45977)
+++ trunk/Master/texmf-dist/tex/latex/pst-tools/pst-tools.sty	2017-12-03 22:19:10 UTC (rev 45978)
@@ -5,7 +5,7 @@
 \ProvidesFile{pst-tools.tex}
   [\filedate\space v\fileversion\space `PST-tools' (hv)]
 \IfFileExists{pst-tools.pro}{%
-   \ProvidesFile{pst-tools.pro}[2013/10/26 v 0.04, PostScript prologue file]
+   \ProvidesFile{pst-tools.pro}[2017/12/03 v 0.06, PostScript prologue file]
      \@addtofilelist{pst-tools.pro}}{}%
 
 \endinput



More information about the tex-live-commits mailing list