Warum platziert \tkzLabelAngle das Etikett nicht im richtigen Winkel?

Warum platziert \tkzLabelAngle das Etikett nicht im richtigen Winkel?

In der folgenden Abbildung versuche ich, „angle“ zu beschriften (lA,A,oA), aber egal, was ich versuche, die Beschriftung landet immer in „angle“ (rA,A,B). Was ist hier los?

\documentclass[border=10pt]{standalone}
\usepackage{tkz-euclide}
\usetikzlibrary{arrows.meta}
\usetkzobj{all}

\newlength\aehlength
\setlength\aehlength{1in}

\begin{document}

\begin{tikzpicture}[my dot/.style={fill,circle,inner sep=1.5pt},>={To[scale=2]}]
  \coordinate (A) at (0,0);
  \coordinate (B) at (55:\aehlength);
  \coordinate (lA) at ($(A)+(180:\aehlength)$);
  \coordinate (rA) at ($(A)+(0:\aehlength)$);
  \coordinate (lB) at ($(B)+(180:\aehlength)$);
  \coordinate (rB) at ($(B)+(0:\aehlength)$);
  \coordinate (oA) at ($(A)!-1cm!(B)$);
  \coordinate (oB) at ($(B)!-1cm!(A)$);

  \foreach \mynA/\mypA/\mynB/\mypB in {A/2cm/B/2cm,lA/1cm/rA/1cm,lB/1cm/rB/1cm}
  {
    \draw[arrows=<->] ($(\mynA)!-\mypA!(\mynB)$) -- ($(\mynB)!-\mypB!(\mynA)$);
  }

  \foreach \myn/\myp in {A/90,B/90,lA/90,rA/90,lB/90,rB/90,oA/90,oB/90 }
  {
      \node[my dot] at (\myn) {};
      \node at ($(\myn)+(\myp:8pt)$) {\myn};
  }

  \tkzLabelAngle[pos=0.45](oA,A,lA) {$x$}
  \tkzLabelAngle[pos=0.45](lA,A,oA) {$x$}
  \tkzLabelAngle[pos=0.75](oB,B,rB) {$60^\circ$}

\end{tikzpicture}
\end{document}

Bildbeschreibung hier eingeben

Antwort1

Mit reiner tkz-euklidischer neuer VersionCTAN v 3.01

\documentclass[border=10pt]{standalone}
\usepackage{tkz-euclide}

\def\aehlength{3}
\begin{document}

\begin{tikzpicture}
  \tkzDefPoint(0,0){A}
  \tkzDefPoint(55:\aehlength){B}
  \tkzDefShiftPoint[A](180:\aehlength){lA}
  \tkzDefShiftPoint[A](0:\aehlength){rA}
  \tkzDefShiftPoint[B](180:\aehlength){lB}
  \tkzDefShiftPoint[B](0:\aehlength){rB}
  \tkzDefPointWith[linear normed,K=-1](A,B) \tkzGetPoint{oA}
  \tkzDefPointWith[linear normed,K=-1](B,A) \tkzGetPoint{oB}
  \tkzDrawLines[add=.5 and .5,<->](oA,oB rA,lA rB,lB)
  \tkzDrawPoints(A,B,lA,rA,oA,rB,lB,oB)
  \tkzLabelPoints[above=3pt](A,B,lA,rA,rB,lB)
  \tkzLabelPoints[right=3pt](oA,oB)
  \tkzLabelAngle[pos=0.75](oA,A,lA) {$x$}
  \tkzLabelAngle[pos=0.75](lA,A,oA) {$x$}     
  \tkzLabelAngle[pos=0.75](oB,B,rB) {$60^\circ$}

\end{tikzpicture}
\end{document}

Bildbeschreibung hier eingeben

Antwort2

Ich habe keine Ahnung, ob es sich um einen Fehler oder ein Feature handelt, aber verwenden Sie \tkzLabelAngle[pos=-0.45](lA,A,oA) {$x$}. Beachten Sie das Minuszeichen in pos.

\documentclass[border=10pt]{standalone}
\usepackage{tkz-euclide}
\usetikzlibrary{arrows.meta}
\usetkzobj{all}

\newlength\aehlength
\setlength\aehlength{1in}

\begin{document}

\begin{tikzpicture}[my dot/.style={fill,circle,inner sep=1.5pt},>={To[scale=2]}]
  \coordinate (A) at (0,0);
  \coordinate (B) at (55:\aehlength);
  \coordinate (lA) at ($(A)+(180:\aehlength)$);
  \coordinate (rA) at ($(A)+(0:\aehlength)$);
  \coordinate (lB) at ($(B)+(180:\aehlength)$);
  \coordinate (rB) at ($(B)+(0:\aehlength)$);
  \coordinate (oA) at ($(A)!-1cm!(B)$);
  \coordinate (oB) at ($(B)!-1cm!(A)$);

  \foreach \mynA/\mypA/\mynB/\mypB in {A/2cm/B/2cm,lA/1cm/rA/1cm,lB/1cm/rB/1cm}
  {
    \draw[arrows=<->] ($(\mynA)!-\mypA!(\mynB)$) -- ($(\mynB)!-\mypB!(\mynA)$);
  }

  \foreach \myn/\myp in {A/90,B/90,lA/90,rA/90,lB/90,rB/90,oA/90,oB/90 }
  {
      \node[my dot] at (\myn) {};
      \node at ($(\myn)+(\myp:8pt)$) {\myn};
  }

  \tkzLabelAngle[pos=0.45](oA,A,lA) {$x$}
  \tkzLabelAngle[pos=-0.45](lA,A,oA) {$x$}         %%% <=== here
  \tkzLabelAngle[pos=0.75](oB,B,rB) {$60^\circ$}

\end{tikzpicture}
\end{document}

Bildbeschreibung hier eingeben

Antwort3

Hier ist meine Lösung (um meine eigene Winkelhalbierende zu definieren):

\makeatletter
\newcommand\aeFindAngleBisector{\ae@find@angle@bisector}
\def\ae@find@angle@bisector(#1)(#2)(#3)[#4]{%%
  \bgroup
  \pgfmathanglebetweenpoints{\pgfpointanchor{#2}{center}}%%
                            {\pgfpointanchor{#1}{center}}%%
  \edef\ae@angle@start@position{\pgfmathresult}%%
  \pgfmathanglebetweenlines{\pgfpointanchor{#2}{center}}%%
                           {\pgfpointanchor{#1}{center}}%%
                           {\pgfpointanchor{#2}{center}}%%
                           {\pgfpointanchor{#3}{center}}%%
  \edef\ae@angle@between{\pgfmathresult}%%
  \pgfmathparse{(\ae@angle@start@position+\ae@angle@between/2}%%
  \xdef\ae@half@angle@bisector{\pgfmathresult}%%
  \coordinate (#4) at ($(#2)+(\ae@half@angle@bisector:10pt)$);
  \egroup
}%%
\makeatother

Das Modell nimmt einen Winkel ABCund definiert einen Punkt entlang der Winkelhalbierenden innerhalb des Winkels, der gegen den Uhrzeigersinn um den Scheitelpunkt herum definiert ist B.

verwandte Informationen