TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Consider the following snippet:

    \fill (0,0) circle (\ptRad);
    \fill (1,1) circle (\ptRad);
    \draw[<->, shorten <=\ptRad,shorten >=\ptRad] (0,0) -- (1,1);  

Is there a way to use only one shortening key for both ends at the same time?

share|improve this question
@Jake: This is for sure nicer then my code. Should I understand from this that there is no build in way (at least currently) to shorten both end at once? – Dror Feb 18 '13 at 13:30
Yes, at the moment there is no built-in key for this. – Jake Feb 18 '13 at 13:35
pstricks provides this shortening via the single key nodesep. Separate end shortening can be set using nodesepA (for the source) and nodesepB (for the target). – Werner Feb 18 '13 at 15:02
up vote 8 down vote accepted

You can define your own style that sets the shorten for both ends at the same time:

\tikzset{ shorten <>/.style={ shorten >=#1, shorten <=#1 } }
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.