Again, I would use tikz-cd
here.
The short
style helps us to draw a straight line only in a segment of the full path. (This isn’t that easy for curved line!)
If the nodes are not aligned in a matrix-like manner, one can use a normal TikZ picture if needed (see second example).
Code
\documentclass[tikz,convert=false]{standalone}
\usepackage{tikz-cd}
\usetikzlibrary{positioning}
\newcommand*{\tikzcdset}{\pgfqkeys{/tikz/commutative diagrams}}
\tikzset{tikzcd/.code=\tikzcdset{#1}}
\tikzcdset{
to node/.style={%
/tikz/execute at begin to=\edef\tikztotarget{#1}}}
\makeatletter
\tikzcdset{
short shift >/.initial=+.6em,
short shift </.initial=+.6em,
short center/.initial=.55,
short/.style={
to path={
\pgfextra
\pgfinterruptpath
\path (\tikztostart) coordinate (@aux1) -- (\tikztotarget) coordinate (@aux2);
\endpgfinterruptpath
\pgfpointdiff{\pgfpointanchor{@aux1}{center}}{\pgfpointanchor{@aux2}{center}}%
\pgfmathveclen@{\pgfmath@tonumber{\pgf@x}}{\pgfmath@tonumber{\pgf@y}}%
\edef\pgfpathlength{\pgfmathresult pt}%
\pgfcoordinate
{@@aux1}
{\pgfpointlineatdistance
{(\pgfkeysvalueof{/tikz/commutative diagrams/short center})*\pgfpathlength-\pgfkeysvalueof{/tikz/commutative diagrams/short shift <}}
{\pgfpointanchor{@aux1}{center}}
{\pgfpointanchor{@aux2}{center}}}%
\pgfcoordinate
{@@aux2}
{\pgfpointlineatdistance
{(\pgfkeysvalueof{/tikz/commutative diagrams/short center})*\pgfpathlength+\pgfkeysvalueof{/tikz/commutative diagrams/short shift >}}
{\pgfpointanchor{@aux1}{center}}
{\pgfpointanchor{@aux2}{center}}}%
\endpgfextra
(@@aux1) -- (@@aux2) \tikztonodes}}
}
\tikzset{% from CVS version
edge node/.code={\expandafter\def\expandafter\tikz@tonodes\expandafter{\tikz@tonodes #1}},
edge label/.style={/tikz/edge node={node[auto]{#1}}},
edge label'/.style={/tikz/edge node={node[auto,swap]{#1}}},
mlabel/.style={/tikz/edge node={node[auto]{$#1$}}},
mlabel'/.style={/tikz/edge node={node[auto,swap]{$#1$}}}
}
\makeatother
\begin{document}
\begin{tikzcd}
A \rar{a}
\drar[out=-90, in=180][coordinate,name=ac]{}
& B \dar{b}
\dar[short, Rightarrow, to node=ac]{c} \\ % doesn't matter what \*ar is used
& C
\end{tikzcd}
\begin{tikzpicture}[tikzcd=every diagram, node distance=.5cm and 1cm]
\node (B) {$B$};
\node at ([shift=(170:1.5)] B) (A) {$A$};
\node at ([shift=(-80:1.5)] B) (C) {$C$};
\path[tikzcd={every arrow, every label}] (A) edge[mlabel=a] (B)
edge[out=-90, in=180] coordinate (ac) (C)
(B) edge[mlabel=b] (C)
edge[tikzcd={short, Rightarrow}, mlabel=c] (ac);
\end{tikzpicture}
\end{document}
Output


B
between the&
and the `\` in the first line doesn’t work? – Qrrbrbirlbel Aug 22 '13 at 9:58