Closed vikraman closed 3 years ago
I agree this would be useful, especially for 2-cells. The question is what the different possible settings should be. I'll probably add this after #5, because I'm having to rewrite the arrow drawing code for that anyway.
The difficulty with this feature is that shorten
in TikZ does not behave well for curved arrows (see this TeX.SE answer, for instance). I'd rather implement a version that works well in any situation, but I need to investigate if that's even possible. If possible, I'd also like a shorten
that accepts a percentage rather than an absolute length.
The arrow library in quiver already has the ability to shorten.
This was added in https://github.com/varkor/quiver/commit/1fa8e4ab56626ff00f97c72637fa2a0cb6318fed. The tikz-cd output isn't yet so good for curved arrows, because shorten
doesn't work properly there, but it works well for the original use case (shortening 2-cells).
Would it be possible to have a slider to change arrow lengths? This could be achieved using the tikzcd shorten option, and is very useful for the 2-arrows in pasting diagrams.