1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
|
% tkz-obj-eu-points.tex
% Copyright 2023 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.
\def\fileversion{5.00c}
\def\filedate{2023/01/23}
\typeout{2023/01/23 5.00c tkz-obj-eu-points.tex}
\makeatletter
%<--------------------------------------------------------------------------->
% tkzSetUpPoint définit la forme d'un point
%<--------------------------------------------------------------------------->
\pgfkeys{/tkzsetuppt/.cd,
size/.store in = \tkz@pt@size,
color/.store in = \tkz@pt@color,
fill/.store in = \tkz@pt@fill,
shape/.store in = \tkz@pt@shape,
size = \tkz@euc@pointsize,
color = \tkz@euc@pointcolor,
fill = \tkz@euc@pointcolor,
shape = \tkz@euc@pointshape,
/tkzsetuppt/.search also = {/tikz},
}
\def\tkzSetUpPoint{\pgfutil@ifnextchar[{\tkz@SetUpPoint}{%
\tkz@SetUpPoint[]}}
\def\tkz@SetUpPoint[#1]{%
\pgfqkeys{/tkzsetuppt}{#1}
% redefine point style with new values
\tikzset{point style/.style={draw = \tkz@pt@color,
inner sep = 0pt,
shape = \tkz@pt@shape,
minimum size = \tkz@pt@size,
fill = \tkz@pt@fill}}
}% end setup
%<--------------------------------------------------------------------------->
% Draw Point
%<--------------------------------------------------------------------------->
\pgfkeys{/tkzdrawpt/.cd,
size/.code = {\tikzset{point style/.append style={minimum size = #1}}},
size = \tkz@euc@pointsize,
/tkzdrawpt/.search also = {/tikz},
}
%<--------------------------------------------------------------------------
\def\tkzDrawPoint{\pgfutil@ifnextchar[{\tkz@DrawPoint}{\tkz@DrawPoint[]}}
\def\tkz@DrawPoint[#1](#2){%
\begingroup
\pgfqkeys{/tkzdrawpt}{#1}
\node[point style,/tkzdrawpt/.cd,#1] at (#2) {};%2016
\endgroup
}
%<--------------------------------------------------------------------------->
\def\tkzDrawPoints{\pgfutil@ifnextchar[{\tkz@drawpts}{\tkz@drawpts[]}}
%<--------------------------------------------------------------------------->
\def\tkz@drawpts[#1](#2){%
\begingroup
\pgfqkeys{/tkzdrawpt}{#1}
\foreach \point in {#2}{\node[point style,/tkzdrawpt/.cd,#1] at (\point) {};} %2016
\endgroup
}
%<-------------------------------------------------------------------------->
% tkzLabelPoint Affichage des LABELS pour un point
%<-------------------------------------------------------------------------->
\def\tkzLabelPoint{\pgfutil@ifnextchar[{\tkz@LabelPoint}{\tkz@LabelPoint[]}}
\def\tkz@LabelPoint[#1](#2)#3{%
\node[label style,#1] at (#2) {#3};}%
%<--------------------------------------------------------------------------->
\def\tkzLabelPoints{\pgfutil@ifnextchar[{\tkz@LabelPoints}{\tkz@LabelPoints[]}}%
\def\tkz@LabelPoints[#1](#2){%
\foreach \point in {#2}{
\node[label style,#1] at (\point) {$\point$};}
}%
%<--------------------------------------------------------------------------->
\pgfkeys{/tkzsetuppt/.cd,
size/.store in = \tkz@pt@size,
color/.store in = \tkz@pt@color,
fill/.store in = \tkz@pt@fill,
shape/.store in = \tkz@pt@shape,
size = \tkz@euc@pointsize,
color = \tkz@euc@pointcolor,
fill = \tkz@euc@pointcolor,
shape = \tkz@euc@pointshape,
/tkzsetuppt/.search also = {/tikz},
}
\def\tkzSetUpPoint{\pgfutil@ifnextchar[{\tkz@SetUpPoint}{%
\tkz@SetUpPoint[]}}
\def\tkz@SetUpPoint[#1]{%
\pgfqkeys{/tkzsetuppt}{#1}
% redefine point style with new values
\tikzset{point style/.style={draw = \tkz@pt@color,
inner sep = 0pt,
shape = \tkz@pt@shape,
minimum size = \tkz@pt@size,
fill = \tkz@pt@fill}}
}% end setup
%<--------------------------------------------------------------------------->
%
%<--------------------------------------------------------------------------->
\def\tkzSetUpLabel{\pgfutil@ifnextchar[{\tkz@SetUpLabel}{%
\tkz@SetUpLabel[]}}
\def\tkz@SetUpLabel[#1]{%
\tikzset{label style/.style={#1}}
}% end setup
%<--------------------------------------------------------------------------->
\pgfkeys{/tkzautolab/.cd,
center/.store in = \tkz@center,
dist/.store in = \tkz@dist,
dist = 0.15,
/tkzautolab/.search also = {/tikz},
}
\def\tkzAutoLabelPoints{\pgfutil@ifnextchar[{\tkz@AutoLabelPoints}{\tkz@AutoLabelPoints[]}}%
\def\tkz@AutoLabelPoints[#1](#2){%
\begingroup
\pgfqkeys{/tkzautolab}{#1}
\foreach \point in {#2}{
\path (\tkz@center) -- ($ (\point) + \tkz@dist*($(\point)-(\tkz@center)$) $) node[/tkzautolab/.cd,label style,#1]{$\point$};}
\endgroup
}%
%<--------------------------------------------------------------------------->
% PointShowCoord
%<--------------------------------------------------------------------------->
\pgfkeys{/tkzprcoord/.cd,
xlabel/.store in = \tkz@xlabel,
ylabel/.store in = \tkz@ylabel,
xstyle/.code = {\tikzset{xcoord style/.append style={#1}}},
ystyle/.code = {\tikzset{ycoord style/.append style={#1}}},
noxdraw/.is if = tkz@coord@noxdraw,
noxdraw/.default = true,
noydraw/.is if = tkz@coord@noydraw,
noydraw/.default = true,
xlabel = {},
ylabel = {},
xstyle = {},
ystyle = {},
noxdraw = false,
noydraw = false,
/tkzprcoord/.search also = {/tikz},
}
\def\tkzPointShowCoord{\pgfutil@ifnextchar[{\tkz@PointShowCoord}{\tkz@PointShowCoord[]}}
\def\tkz@PointShowCoord[#1](#2){%
\begingroup
\pgfqkeys{/tkzprcoord}{#1}
% 2019 for showcoord
\iftkznodedefined{tkz@xline}{}{%
\path (0,0) --(1,0) node(tkz@xline){};
\path (0,0) --(0,1) node(tkz@yline){};
}
\iftkz@coord@noxdraw\else\draw[arrow coord style,/tkzprcoord/.cd,#1] (#2)--(#2 |- tkz@xline);\fi
\iftkz@coord@noydraw\else\draw[arrow coord style,/tkzprcoord/.cd,#1] (#2)--(#2 -| tkz@yline);\fi
\ifx\tkzutil@empty\tkz@xlabel
\else
\path (#2)--(#2 |- tkz@xline)
node[xcoord style] {\tkz@xlabel};
\fi
\ifx\tkzutil@empty\tkz@ylabel
\else
\path (#2)--(#2 -| tkz@yline)
node[ycoord style] {\tkz@ylabel};
\fi
\endgroup
}
\let\tkzShowPointCoord\tkzPointShowCoord
\endinput
|