summaryrefslogtreecommitdiff
path: root/graphics
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2020-02-27 03:01:13 +0000
committerNorbert Preining <norbert@preining.info>2020-02-27 03:01:13 +0000
commitcfcab0823d16bb9acd6d6a7d3f80a7b2176a6260 (patch)
tree4db3d6f79edb6570d6c812c4962a4322c0605534 /graphics
parent2dfd6df5d1db270dc874c6c319d51eed43defb91 (diff)
CTAN sync 202002270301
Diffstat (limited to 'graphics')
-rw-r--r--graphics/pstricks/contrib/pst-eucl/Changes5
-rw-r--r--graphics/pstricks/contrib/pst-eucl/doc/pst-eucl-doc.bib49
-rw-r--r--graphics/pstricks/contrib/pst-eucl/doc/pst-eucl-doc.pdfbin1709884 -> 1714126 bytes
-rw-r--r--graphics/pstricks/contrib/pst-eucl/doc/pst-eucl-doc.tex4
-rw-r--r--graphics/pstricks/contrib/pst-eucl/tex/pst-eucl.tex203
5 files changed, 213 insertions, 48 deletions
diff --git a/graphics/pstricks/contrib/pst-eucl/Changes b/graphics/pstricks/contrib/pst-eucl/Changes
index 671f670121..09287f4f16 100644
--- a/graphics/pstricks/contrib/pst-eucl/Changes
+++ b/graphics/pstricks/contrib/pst-eucl/Changes
@@ -6,6 +6,11 @@ pst-eucl.pro --------
pst-eucl.tex --------
+1.71 2020/02/26 - add macro to wrap the native macro \pspolygon just group the parameters as local, \pstPolygon.
+ - update macro \pstCircleOA and \pstCircleAB to clear \pst@par like as \pst@object clear it. This change update the issue that some rendering options used at last will be taken, e.g. if you call \pspolygon with fillcolor, and then call \pstCircleOA, the circle will be filled with same color.
+ - add macro to draw the nine point circle and its center, \pstTriangleNC.
+ - add macro to draw the general ellipse by its focus and one node on it, \pstGeneralEllipseFFN.
+ - add macro to draw the general hyperbola by its focus and one node on it, \pstGeneralHyperbolaFFN.
1.70 2020/01/29 - add optional argument RightAngleDotDistance to controll the the dot
position for right angles (type german or swissromand)
1.69 2020/01/09 - add macro to get the chord with specified length, \pstCircleChordNode.
diff --git a/graphics/pstricks/contrib/pst-eucl/doc/pst-eucl-doc.bib b/graphics/pstricks/contrib/pst-eucl/doc/pst-eucl-doc.bib
index 9fc9a97eaf..7e9f03b000 100644
--- a/graphics/pstricks/contrib/pst-eucl/doc/pst-eucl-doc.bib
+++ b/graphics/pstricks/contrib/pst-eucl/doc/pst-eucl-doc.bib
@@ -1,18 +1,19 @@
@STRING{tugboat = {TUGboat} }
-@STRING{dtk = {{D}ie {\TeX}nische {K}om{\"o}die} }
+@STRING{dtk = {Die {\TeX}nische Komödie} }
+@STRING{bretter = {Bretter, die die Welt bedeuten } }
@Book{companion,
- author = {Michel Goosens and Frank Mittelbach and Sebastian Rahtz and Dennis Roegel and Herbert Vo\ss},
- title = {The {\LaTeX} {G}raphics {C}ompanion},
- publisher = {{Addison-Wesley Publishing Company}},
- edition = {second},
- year = {2007},
- address = {Boston, Mass.}
+ author = {Michel Goosens and Frank Mittelbach and Sebastian Rahtz and Dennis Roegel and Herbert Voß},
+ title = {The {\LaTeX} Graphics Companion},
+ publisher = {Addison-Wesley Publishing Company},
+ edition = {2},
+ date = {2007},
+ location = {Boston, Mass.}
}
@Article{girou:01:,
author = {Denis Girou},
- title = {Pr\'esentation de {PST}ricks},
+ title = {Présentation de PSTricks},
journal = {Cahier {GUT}enberg},
year = 1994,
volume = {16},
@@ -21,7 +22,7 @@
}
@Article{girou:02:,
- author = {{Timothy Van} Zandt and Denis Girou},
+ author = {Timothy Van Zandt and Denis Girou},
title = {Inside {PST}ricks},
journal = TUGboat,
year = 1994,
@@ -32,8 +33,7 @@
@Book{PostScript,
Author = {Kollock, Nikolai G.},
- Title = {Post{S}cript richtig eingesetzt: vom {K}onzept zum
- praktischen {E}insatz},
+ Title = {PostScript richtig eingesetzt: vom Konzept zum praktischen Einsatz},
Publisher = {IWT},
Address = {Vaterstetten},
year = 1989,
@@ -50,25 +50,25 @@ version = {1.42}
@Book{PSTricks2,
- author = {Herbert Vo\ss{}},
+ author = {Herbert Voß},
title = {\texttt{PSTricks} -- {G}rafik f\"ur \TeX{} und \LaTeX},
edition = {7},
- publisher = {DANTE -- Lehmanns},
- year = {2016},
+ publisher = {DANTE {\eV} and Lehmanns Media},
+ date = {2016},
address = {Heidelberg and Hamburg}
}
@Book{PSTricksE,
- author = {Herbert Vo\ss{}},
- title = {\texttt{PSTricks} -- {G}raphics and {P}ost{S}cript for \LaTeX},
+ author = {Herbert Voß},
+ title = {\texttt{PSTricks} -- Graphics and PostScript for \LaTeX},
edition = {1},
publisher = {UIT},
- year = {2011},
+ date = {2011},
address = {Cambridge -- UK}
}
@Book{LTXquick,
- author = {Herbert Vo\ss{}},
+ author = {Herbert Voß},
title = {{\LaTeX} quick reference},
edition = {1},
publisher = {UIT},
@@ -77,11 +77,11 @@ version = {1.42}
}
@Book{presentations,
- author = {Herbert Vo\ss},
+ author = {Herbert Voß},
title = {Presentations with \LaTeX},
- edition = {1},
- publisher = {DANTE -- Lehmanns Media},
- year = {2012},
+ edition = {2},
+ publisher = {DANTE {\eV} and Lehmanns Media},
+ year = {2019},
address = {Heidelberg and Berlin}
}
@@ -90,7 +90,7 @@ version = {1.42}
author = {Victor Eijkhout},
title = {\TeX\ by Topic -- {A} \TeX{}nician Reference},
edition = {1},
- publisher = {DANTE -- Lehmanns media},
+ publisher = {DANTE {\eV} and Lehmanns Media},
year = {2014},
address = {Heidelberg and Berlin}
}
@@ -98,7 +98,7 @@ version = {1.42}
@Article{dtk02.1:voss:mathematischen,
- author = {Herbert Vo{\ss}},
+ author = {Herbert Voß},
title = {Die mathematischen {F}unktionen von {P}ostscript},
journal = dtk,
year = 2002,
@@ -108,7 +108,6 @@ version = {1.42}
month = mar,
pages = {40-47},
annote = bretter,
- keywords = {},
abstract = { \PS, faktisch genauso alt wie {\TeX}, ist im
Verh{\"a}ltnis dazu allgemein noch weniger bekannt, wenn es
darum geht zu beurteilen, was es denn nun im eigentlichen
diff --git a/graphics/pstricks/contrib/pst-eucl/doc/pst-eucl-doc.pdf b/graphics/pstricks/contrib/pst-eucl/doc/pst-eucl-doc.pdf
index 65737c9ba1..14c1e0c046 100644
--- a/graphics/pstricks/contrib/pst-eucl/doc/pst-eucl-doc.pdf
+++ b/graphics/pstricks/contrib/pst-eucl/doc/pst-eucl-doc.pdf
Binary files differ
diff --git a/graphics/pstricks/contrib/pst-eucl/doc/pst-eucl-doc.tex b/graphics/pstricks/contrib/pst-eucl/doc/pst-eucl-doc.tex
index 6100efcb86..c3b6bed35c 100644
--- a/graphics/pstricks/contrib/pst-eucl/doc/pst-eucl-doc.tex
+++ b/graphics/pstricks/contrib/pst-eucl/doc/pst-eucl-doc.tex
@@ -7,6 +7,8 @@
\newtheorem{theorem}{Theorem}
\usepackage{pst-func,pst-plot,paralist}
\usepackage[mathscr]{eucal}
+\def\eV{e.\kern-1pt{}V\kern-1pt}
+
\lstset{pos=l,wide=false,basicstyle=\footnotesize\ttfamily,explpreset={language=[PSTricks]{TeX}}}
%
@@ -544,6 +546,7 @@ The symbol is controlled by the parameter \Lkeyword{RightAngleType}
\item \Lkeyval{suisseromand} : swiss romand symbol (given P. Schnewlin).
\end{compactitem}
+\begin{sloppypar}
The only parameters controlling this command, excepting the ones which
controlled the line, is \Lkeyword{RightAngleSize} which defines the size
of the symbol \DefaultVal{0.28 unit} and \Lkeyword{RightAngleDotDistance}. For a
@@ -551,6 +554,7 @@ right angle style \Lkeyval{german} or \Lkeyval{swissromand} the distance of the
is preset to 0.5 (\Lkeyval{german}) or 0.45 (\Lkeyval{swissromand}), relative to the radius.
It can be controlled by the optional argument \Lkeyword{RightAngleDotDistance} which is
preset to 1. A greater value moves the dot away from the reference point.
+\end{sloppypar}
diff --git a/graphics/pstricks/contrib/pst-eucl/tex/pst-eucl.tex b/graphics/pstricks/contrib/pst-eucl/tex/pst-eucl.tex
index 68dbf939fb..c5e67dae20 100644
--- a/graphics/pstricks/contrib/pst-eucl/tex/pst-eucl.tex
+++ b/graphics/pstricks/contrib/pst-eucl/tex/pst-eucl.tex
@@ -20,8 +20,8 @@
\csname PSTEuclideLoaded\endcsname
\let\PSTEuclideLoaded\endinput
%
-\def\fileversion{1.70}
-\def\filedate{2020/01/29}
+\def\fileversion{1.71}
+\def\filedate{2020/02/26}
%%
\message{`PST-Euclide v\fileversion, \filedate\space (dr,hv)}%
%% prologue for postcript
@@ -287,6 +287,31 @@
\@ifnextchar(\Pst@Geonode@ii{\pst@MngTransformCurve\endgroup}}% DR 22032005
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%% \pstPolygon[options](A)(B)(C)(D)...
+%% create a polygon with some given node names, unlike the native pstrick pspolygon macro,
+%% this macro group the options as local variables, i.e, it is same as
+%% \begingroup
+%% \pspolygon[options](A)(B)(C)(D)...
+%% \endgroup
+%% if you use pspolygon without the begingroup and endgroup, then the options will be
+%% used for the subsequent macros.
+%%
+%% #1 -> options
+%% #2,#3,#4,... -> node names
+\def\pstPolygon{\@ifnextchar[\Pst@Polygon{\Pst@Polygon[]}}
+\def\Pst@Polygon[#1]{%
+ \begingroup
+ \xdef\@@GenCourbe{}%%for accumulating points
+ \psset{#1}%
+ \ifx\psk@CurveType\@none\psset{CurveType=polygon}\fi
+ \pstPolygon@ii%
+}
+\def\pstPolygon@ii(#1){%
+ \xdef\@@GenCourbe{\@@GenCourbe(#1)}%
+ \@ifnextchar(\pstPolygon@ii{\pst@MngTransformCurve\endgroup}%
+}%
+%
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% Create a point with an associated node, in a new
%% landmark
%% #1 -> options
@@ -1079,13 +1104,11 @@
%% #3 -> [input] the node A on the circle or empty if you setup Radius/Diameter
%% #4 -> [input] optional. start angle from angleA to angleB, going counter clockwise.
%% #5 -> [input] optional, start angle from angleA to angleB, going counter clockwise.
-\def\pstCircleOA{\@ifnextchar[\Pst@CircleOA{\Pst@CircleOA[]}}
-\def\Pst@CircleOA[#1]#2#3{%
- \begingroup
- \psset{#1}%
- \def\pst@circle@center{#2}
- \def\pst@circle@node{#3}
- \@ifnextchar[\pstCircleOA@i{\pstCircleOA@j}}%
+\def\pstCircleOA{\pst@object{Pst@CircleOA}}
+\def\Pst@CircleOA@i#1#2{%
+ \def\pst@circle@center{#1}%
+ \def\pst@circle@node{#2}%
+ \@ifnextchar[\pstCircleOA@i\pstCircleOA@j}%
\def\pstCircleOA@i[#1][#2]{%
\begin@OpenObj
\def\pst@linetype{4}%
@@ -1100,11 +1123,9 @@
\else\psk@Radius\space
\fi
end
- %\psk@dimen CLW mul sub 0 360 arc closepath}%
- #1 #2 arc}%
+ \psk@dimen CLW mul sub #1 #2 arc}%
\showpointsfalse
\end@OpenObj
- \endgroup%
}%
\def\pstCircleOA@j{%
\begin@ClosedObj
@@ -1120,19 +1141,15 @@
\else\psk@Radius\space
\fi
end
- %\psk@dimen CLW mul sub 0 360 arc closepath}%
- 0 360 arc closepath}%
+ \psk@dimen CLW mul sub 0 360 arc closepath}%
\showpointsfalse
\end@ClosedObj
- \endgroup%
}%
%% #2 #3 -> 2 nodes defining a diameter of the circle
-\def\pstCircleAB{\@ifnextchar[\Pst@CircleAB{\Pst@CircleAB[]}}
-\def\Pst@CircleAB[#1]#2#3{%
- \begingroup
- \psset{#1}%
- \def\pst@circle@diameter@A{#2}
- \def\pst@circle@diameter@B{#3}
+\def\pstCircleAB{\pst@object{Pst@CircleAB}}
+\def\Pst@CircleAB@i#1#2{%
+ \def\pst@circle@diameter@A{#1}
+ \def\pst@circle@diameter@B{#2}
\@ifnextchar[\pstCircleAB@i{\pstCircleAB@j}}%
\def\pstCircleAB@i[#1][#2]{%
\Pst@MiddleAB[PointSymbol=none, PointName=none]{\pst@circle@diameter@B}{\pst@circle@diameter@A}{PST@CIRCLE@MAB}
@@ -1147,7 +1164,6 @@
\psk@dimen\space CLW mul sub #1 #2 arc}%
\showpointsfalse
\end@OpenObj
- \endgroup%
}%
\def\pstCircleAB@j{%
\Pst@MiddleAB[PointSymbol=none, PointName=none]{\pst@circle@diameter@B}{\pst@circle@diameter@A}{PST@CIRCLE@MAB}
@@ -1162,7 +1178,6 @@
\psk@dimen\space CLW mul sub 0 360 arc closepath}%
\showpointsfalse
\end@ClosedObj
- \endgroup%
}%
%% #2 #3 #4 -> 3 nodes defining the center and two points on the circle
\def\pstArcOAB{\pst@object{pstArcOAB}}%
@@ -2306,6 +2321,46 @@
\endgroup
}%
%
+%% \pstTriangleNC[Options]{A}{B}{C}{N}[M1][M2][M3]
+%% Draw the nine point circle center of triangle ABC
+%% Parameters:
+%% #1 -> options
+%% #2 -> [input] the node A
+%% #3 -> [input] the node B
+%% #4 -> [input] the node C
+%% #5 -> [output] the output nine point circle center N
+%% #6 -> [output] the optional output Middle of BC
+%% #7 -> [output] the optional output Middle of CA
+%% #8 -> [output] the optional output Middle of AB
+\def\pstTriangleNC{\@ifnextchar[\Pst@TriangleNC{\Pst@TriangleNC[]}}
+\def\Pst@TriangleNC[#1]#2#3#4#5{%
+ \begingroup
+ \@InitListMng %
+ \psset{#1}%
+ \def\pst@triangle@node@A{#2}
+ \def\pst@triangle@node@B{#3}
+ \def\pst@triangle@node@C{#4}
+ \def\pst@triangle@node@N{#5}
+ \@ifnextchar[\Pst@TriangleNC@i{\Pst@TriangleNC@j[BC_M][CA_M][AB_M]}}
+\def\Pst@TriangleNC@i[#1][#2][#3]{%
+ \pstMiddleAB[PointName=none,PointSymbol=none]{\pst@triangle@node@B}{\pst@triangle@node@C}{#1}
+ \pstMiddleAB[PointName=none,PointSymbol=none]{\pst@triangle@node@C}{\pst@triangle@node@A}{#2}
+ \pstMiddleAB[PointName=none,PointSymbol=none]{\pst@triangle@node@A}{\pst@triangle@node@B}{#3}
+ \pstTriangleOC[PointName=none,PointSymbol=none]{#1}{#2}{#3}[\pst@triangle@node@N]
+ \Pst@ManageParamList{\pst@triangle@node@N}%
+ \Pst@ManageParamList{#1}%
+ \Pst@ManageParamList{#2}%
+ \Pst@ManageParamList{#3}%
+ \endgroup
+}%
+\def\Pst@TriangleNC@j[#1][#2][#3]{%
+ \pstMiddleAB[PointName=none,PointSymbol=none]{\pst@triangle@node@B}{\pst@triangle@node@C}{#1}
+ \pstMiddleAB[PointName=none,PointSymbol=none]{\pst@triangle@node@C}{\pst@triangle@node@A}{#2}
+ \pstMiddleAB[PointName=none,PointSymbol=none]{\pst@triangle@node@A}{\pst@triangle@node@B}{#3}
+ \pstTriangleOC{#1}{#2}{#3}[\pst@triangle@node@N]
+ \endgroup
+}%
+%
%% Distance between two points
\def\pstDist#1#2{%
tx@EcldDict begin /N@#1 GetNode /N@#2 GetNode ABDist end
@@ -4338,6 +4393,57 @@
\endgroup%
}%
%
+%% \pstGeneralEllipseFFN[Options]{F1}{F2}{N}{O}{R}{\theta}
+%% Calculate the center and the radii of a General Ellipse with two focus $F_1$, $F_2$, and one node $N$ on it,
+%% then you can access the ellipse with them.
+%% Parameters:
+%% #1 -> options
+%% #2 -> [input] the given focus F_1
+%% #3 -> [input] the given focus F_2
+%% #4 -> [input] the given node N on the ellipse
+%% #5 -> [output] the center of the ellipse.
+%% #6 -> [output] the pair of major and minor radius of the ellipse.
+%% #7 -> [output] the rotation of the ellipse major axis.
+\def\pstGeneralEllipseFFN{\@ifnextchar[\Pst@GeneralEllipseFFN{\Pst@GeneralEllipseFFN[]}}
+\def\Pst@GeneralEllipseFFN[#1]#2#3#4#5#6#7{
+ \begingroup
+ \psset{#1}%
+ \pst@getcoor{#2}\pst@tempFa%
+ \pst@getcoor{#3}\pst@tempFb%
+ \pst@getcoor{#4}\pst@tempN%
+ \pnode(!
+ \pst@tempFa \tx@UserCoor /Fay ED /Fax ED
+ \pst@tempFb \tx@UserCoor /Fby ED /Fbx ED
+ \pst@tempN \tx@UserCoor /Ny ED /Nx ED
+ Fax Fbx add 2 div /EllipseOx ED
+ Fay Fby add 2 div /EllipseOy ED
+ Fax Fay Fbx Fby
+ tx@EcldDict begin ABDist end
+ 2 div /EllipseC ED
+ Nx Ny Fax Fay
+ tx@EcldDict begin ABDist end
+ Nx Ny Fbx Fby
+ tx@EcldDict begin ABDist end
+ add 2 div /EllipseA ED
+ EllipseA dup mul EllipseC dup mul sub sqrt /EllipseB ED
+ Fay Fby lt {
+ Fby Fay sub Fbx Fax sub atan /#7 ED
+ } {
+ Fay Fby sub Fax Fbx sub atan /#7 ED
+ } ifelse
+ EllipseOx EllipseOy
+ ){#5}
+ \Pst@geonodelabel{#5}%
+ \pnode(! EllipseA EllipseB){#6}
+ \ifPst@CodeFig
+ \begingroup\psset{PointName=none,linecolor=\psk@CodeFigColor}
+ \pstLineAB[nodesep=-0.6]{#2}{#3}
+ \pstLineAA[nodesepA=-1.5,nodesepB=-0.5]{#5}{#7 90 add}{PST@ELLIPSE@Y}
+ \endgroup
+ \fi
+ \endgroup%
+}%
+%
%% \pstGeneralEllipseFle[Options]{F}{l_A}{l_B}{e}{O}{R}{\theta}
%% Calculate the center and the radii of a General Ellipse with directrix line $l$, focus $F$ and eccentricity $e$,
%% then you can access the ellipse with them.
@@ -8502,6 +8608,57 @@
}%
}%
%
+%% \pstGeneralHyperbolaFFN[Options]{F1}{F2}{N}{O}{R}{\theta}
+%% Calculate the center and the radii of a General Hyperbola with two focus $F_1$, $F_2$, and one node $N$ on it,
+%% then you can access the hyperbola with them.
+%% Parameters:
+%% #1 -> options
+%% #2 -> [input] the given focus F_1
+%% #3 -> [input] the given focus F_2
+%% #4 -> [input] the given node N on the hyperbola
+%% #5 -> [output] the center of the hyperbola.
+%% #6 -> [output] the pair of major and minor radius of the hyperbola.
+%% #7 -> [output] the rotation of the hyperbola major axis.
+\def\pstGeneralHyperbolaFFN{\@ifnextchar[\Pst@GeneralHyperbolaFFN{\Pst@GeneralHyperbolaFFN[]}}
+\def\Pst@GeneralHyperbolaFFN[#1]#2#3#4#5#6#7{
+ \begingroup
+ \psset{#1}%
+ \pst@getcoor{#2}\pst@tempFa%
+ \pst@getcoor{#3}\pst@tempFb%
+ \pst@getcoor{#4}\pst@tempN%
+ \pnode(!
+ \pst@tempFa \tx@UserCoor /Fay ED /Fax ED
+ \pst@tempFb \tx@UserCoor /Fby ED /Fbx ED
+ \pst@tempN \tx@UserCoor /Ny ED /Nx ED
+ Fax Fbx add 2 div /HyperbolaOx ED
+ Fay Fby add 2 div /HyperbolaOy ED
+ Fax Fay Fbx Fby
+ tx@EcldDict begin ABDist end
+ 2 div /HyperbolaC ED
+ Nx Ny Fax Fay
+ tx@EcldDict begin ABDist end
+ Nx Ny Fbx Fby
+ tx@EcldDict begin ABDist end
+ sub 2 div abs /HyperbolaA ED
+ HyperbolaC dup mul HyperbolaA dup mul sub sqrt /HyperbolaB ED
+ Fay Fby lt {
+ Fby Fay sub Fbx Fax sub atan /#7 ED
+ } {
+ Fay Fby sub Fax Fbx sub atan /#7 ED
+ } ifelse
+ HyperbolaOx HyperbolaOy
+ ){#5}
+ \Pst@geonodelabel{#5}%
+ \pnode(! HyperbolaA HyperbolaB){#6}
+ \ifPst@CodeFig
+ \begingroup\psset{PointName=none,linecolor=\psk@CodeFigColor}
+ \pstLineAB[nodesep=-0.6]{#2}{#3}
+ \pstLineAA[nodesepA=-1.5,nodesepB=-0.5]{#5}{#7 90 add}{PST@HYPERBOLA@Y}
+ \endgroup
+ \fi
+ \endgroup%
+}%
+%
%% \pstGeneralHyperbolaFle[Options]{F}{l_A}{l_B}{e}{O}{R}{\theta}
%% Calculate the center and the radii of a General Hyperbola with directrix line $l$, focus $F$ and eccentricity $e$,
%% then you can access the hyperbola with them.