G^F
次の図では、破線矢印のラベルを中央に配置したいと思います。
ただし、とpos
の間に「ジャンプ」があるように見えるため、変更は機能しないようです。pos=0.41
pos=0.42
ラベルを中央に配置する方法はありますか? (実際、なぜデフォルトで中央に配置されないのか、または で中央に配置されないのかが気になりますpos=0.5
)
以下は MWE です。
\documentclass{article}
\usepackage{tikz-cd}
\begin{document}
\begin{tikzcd}
& A \\
C & \widehat{C}
\arrow["{F}", from=2-1, to=1-2]
\arrow["{Y}"', from=2-1, to=2-2]
\arrow["{N^F}"', "{\vdash}"{inner sep=.3ex}, from=1-2, to=2-2]
\arrow["{G^F}"'{pos=.41}, dashed, bend right, from=2-2, to=1-2]
\end{tikzcd}
\end{document}
答え1
これは、曲がった矢印が非常に短い場合に発生します。 2 つの提案:
sep
ノード間の距離が広がるように増やします。- 角度を小さくします。図で
bend
使用しました。(その後、矢印も右にする必要があります。)bend right=15
shift
コードは次のとおりです:
\documentclass{article}
\usepackage{tikz-cd}
\begin{document}
\begin{tikzcd}[sep=large]
& A \\
C & \widehat{C}
\arrow["F", from=2-1, to=1-2]
\arrow["Y"', from=2-1, to=2-2]
\arrow["N^F"', "{\vdash}"{inner sep=.3ex}, from=1-2, to=2-2]
\arrow["G^F"', dashed, bend right=15, shift right=1.5, from=2-2, to=1-2]
\end{tikzcd}
\end{document}