角度ラベルの移動

ラベルには中かっこ({…})でオプションを追加できます。

\documentclass[tikz,border=10pt]{standalone}
\usetikzlibrary{angles,quotes}
\begin{document}
\begin{tikzpicture}[every node/.style = {font = \scriptsize}]
  % Axes
  \draw[-stealth] (-1.2,0) -- (2.2,0) node[right] {$x$};
  \draw[-stealth] (0,-1.2) -- (0,1.5) node[above] {$y$};
  % Circle
  \draw circle(1);
  % Labels
  \node at (1.1,0) [below] {1};
  \node at (0.2,1.15)      {1};
  \node at (2,0) [below]   {2};
  \node at (0.2,0) [below] {0};
  % Line from origin to (2,1)
  \draw (-1.2,-0.6) -- (2,1);
  % Dashed projection lines
  \draw[dashed] (2,1) -- (2,0);
  \draw[dashed] (2,1) -- (0,1);
  \coordinate (0) at       (0,0);
  \coordinate (A) at     (0.2,0);
  \coordinate (B) at (-0.2,-0.1);
  % Angle arc with label
  \pic[draw, -stealth, "$\theta$"{shift = (20:-0.20)},
    angle radius = 8, angle eccentricity = 1.3]
    {angle = A--0--B};
\end{tikzpicture}
\end{document}

LaTeX output

Xで@TeXgalleryフォローしてね〜(^▽^)

Leave a Reply

Your email address will not be published. Required fields are marked *