\input{preamble-standalone.ltx} \begin{document} % Ex. No. 162 (Section 22.4.1 : Exemple de marquage d'un angle droit) \begin{tikzpicture} \tkzDefPoints{0/0/A,3/1/B,0.9/-1.2/P} \tkzDefPointBy[projection = onto B--A](P) \tkzGetPoint{H} \tkzDrawLines[add=.5 and .5](P,H) \tkzMarkRightAngle[fill=blue!20,size=.5,draw](A,H,P) \tkzDrawPoints[](A,B,P,H) \tkzDrawLines[add=.5 and .5](A,B) \tkzMarkRightAngle[fill=red!20,size=.8](B,H,P) \end{tikzpicture} \end{document}