# How to change the tips of the 2-cells in xy-pic?

I used the cmtip option in xypic, but this doesn't change the tips of the \xtwocells, and I have a lot of 2-cells. I am using cmtip because I want the tips in the diagrams to match the ones of the in-line arrows $A\to B$. It seems that the cmtip option is not compatible with the 2cell option. So how to change the tips of the 2-cells?

If this leads to also put any symbol (which can be oriented properly) in the place of the 2-cell. I would also like to know about that.

Here is a simple example. A square with a cell inside.

\documentclass{article}%
\usepackage[all,2cell,cmtip]{xy}
\UseAllTwocells
\begin{document}
$\vcenter{\hbox{\xymatrix@!0@=15mm{ tl\ar[r]^-{t}\ar[d]_-{l}\xtwocell[rd]{}<>{2}&tr\ar[d]^-{r}\\ bl\ar[r]_-{b}&br }}}$
\end{document}


\documentclass[12pt,a4paper]{article}

\usepackage{amssymb,amsmath}

\usepackage[all,cmtip]{xy}

\begin{document}

$$\xymatrix{ tl\ar[r]^t \ar[d]_l &tr\ar[d]^r\ar@{=>}[ld]^2\\ bl\ar[r]_b &br }$$

\end{document}

• Avoid using  in LaTeX, $....$ is better. – CarLaTeX Feb 7 '17 at 7:09
• – Werner Feb 7 '17 at 7:24
• Thanks for your answer, but unfortunately if I compile it as you wrote, it doesn't change the tip of the 2-cell. From your code I was not expecting this behaviour. Also, the 2cell is way too long, I prefer the shorter one as in the example I gave. – MetalMathician Feb 7 '17 at 9:35

Is a solution with tikz-cd Ok for you?

\documentclass{article}
\usepackage{tikz-cd}

\begin{document}
$\begin{tikzcd} tl\ar{r}{t} \ar{d}[swap]{l} &tr \arrow[Rightarrow]{ld}{2}\arrow{d}{r} \\ bl\ar{r}[swap]{b} &br \end{tikzcd}$
\end{document}


• Not really, I have a long document with many many diagrams that include 2cells, some of them quite complicated. But thanks. – MetalMathician Jan 22 '17 at 11:16
• @RamónAbudAlcalá Sorry, I can't help you with xymatrix. Perhaps if you add to your question one of your complex diagram someone else can understand better your problem and solve it. – CarLaTeX Jan 22 '17 at 11:45
• well the question is not about any particular diagram, is about the possibility to change the tips of the 2-cells of xy-pic. So that my document has a uniform look. – MetalMathician Jan 22 '17 at 11:48