summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/tkz-euclide/tkz-obj-eu-compass.tex
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/tkz-euclide/tkz-obj-eu-compass.tex')
-rw-r--r--Master/texmf-dist/tex/latex/tkz-euclide/tkz-obj-eu-compass.tex53
1 files changed, 30 insertions, 23 deletions
diff --git a/Master/texmf-dist/tex/latex/tkz-euclide/tkz-obj-eu-compass.tex b/Master/texmf-dist/tex/latex/tkz-euclide/tkz-obj-eu-compass.tex
index dd1c46863a0..50cda7b15b5 100644
--- a/Master/texmf-dist/tex/latex/tkz-euclide/tkz-obj-eu-compass.tex
+++ b/Master/texmf-dist/tex/latex/tkz-euclide/tkz-obj-eu-compass.tex
@@ -1,11 +1,21 @@
% tkz-obj-eu-compass.tex
-% Copyright 2020 by Alain Matthes
-% This file may be distributed and/or modified
-% 1. under the LaTeX Project Public License and/or
-% 2. under the GNU Public License.
-\def\fileversion{3.02c}
-\def\filedate{2020/01/24}
-\typeout{2020/01/24 3.02c tkz-obj-eu-compass.tex}
+% Copyright 2020 Alain Matthes
+% This work may be distributed and/or modified under the
+% conditions of the LaTeX Project Public License, either version 1.3
+% of this license or (at your option) any later version.
+% The latest version of this license is in
+% http://www.latex-project.org/lppl.txt
+% and version 1.3 or later is part of all distributions of LaTeX
+% version 2005/12/01 or later.
+%
+% This work has the LPPL maintenance status “maintained”.
+%
+% The Current Maintainer of this work is Alain Matthes.
+
+% utf8 encoding
+\def\fileversion{3.05c}
+\def\filedate{2020/03/03}
+\typeout{2020/03/03 3.05c tkz-obj-eu-compass.tex}
\makeatletter
%<--------------------------------------------------------------------------–>
% Author Alain Matthes
@@ -16,24 +26,22 @@
%<--------------------------------------------------------------------------–>
% Setup Compass
%<--------------------------------------------------------------------------–>
-\pgfkeys{%
- tkzsucompass/.cd,
+\pgfkeys{tkzsucompass/.cd,
line width/.code = {\global\edef\tkz@compass@lw{#1}},
color/.code = {\global\edef\tkz@compass@color{#1}},
style/.code = {\global\edef\tkz@compass@style{#1}},
}
%<--------------------------------------------------------------------------–>
-%<--------------------------------------------------------------------------–>
-\def\tkzSetUpCompass{\pgfutil@ifnextchar[{\tkzActivOff\tkz@SetUpCompass}{%
- \tkzActivOff\tkz@SetUpCompass[]}}
+\def\tkzSetUpCompass{\pgfutil@ifnextchar[{\tkz@SetUpCompass}{% remove tkzActivOff 3.03
+ \tkz@SetUpCompass[]}}
%<--------------------------------------------------------------------------–>
\def\tkz@SetUpCompass[#1]{%
-\pgfkeys{%
- tkzsucompass/.cd,
+\pgfkeys{tkzsucompass/.cd,
line width = \tkz@euc@compasswidth,
color = \tkz@euc@compasscolor,
- style = \tkz@euc@compassstyle
- }
+ style = \tkz@euc@compassstyle,
+ /tkzsucompass/.search also = {/tikz}
+}
\pgfqkeys{/tkzsucompass}{#1}
\tikzset{compass style/.style={color = \tkz@compass@color,
line width = \tkz@compass@lw,
@@ -56,7 +64,7 @@
/tkzcompass/length/.code = {\def\tkz@length{#1}},
/tkzcompass/ratio/.code = {\def\tkz@ratio{#1}},
/tkzcompass/.unknown/.code = {\let\searchname=\pgfkeyscurrentname
- \pgfkeysalso{\searchname/.try=#1,
+ \pgfkeysalso{\searchname/.try=#1,
/tikz/\searchname/.retry=#1}}
}
@@ -70,15 +78,14 @@
ratio = .5
}
\pgfkeys{tkzcompass/.cd,#1}
- \tkzCalcLength(#2,#3)\tkzGetLength{tkz@tempLen}
+\tkzCalcLength(#2,#3)\tkzGetLength{tkz@tempLen}
\ifnum\tkz@delta=0 %
\pgfmathsetmacro{\tkz@delta}{min(deg(\tkz@length cm/ \tkz@tempLen pt),180)/2}
\fi
- \tkzFindSlopeAngle(#2,#3)\tkzGetAngle{tkz@angle}%
- \draw[shift ={(#2)},/tkzcompass/.cd,compass style,#1]%
- (\tkz@angle-\tkz@delta:\tkz@tempLen pt)%
- arc (\tkz@angle-\tkz@delta:\tkz@angle+\tkz@delta:\tkz@tempLen pt);
- %};
+\tkzFindSlopeAngle(#2,#3)\tkzGetAngle{tkz@angle}%
+\draw[shift ={(#2)},/tkzcompass/.cd,compass style,#1]%
+ (\tkz@angle-\tkz@delta:\tkz@tempLen pt)%
+ arc (\tkz@angle-\tkz@delta:\tkz@angle+\tkz@delta:\tkz@tempLen pt);
\endgroup}
%<--------------------------------------------------------------------------–>
\def\tkz@multiCompass#1 #2\@nil{%