[pstricks] hook and arrowinset
Herbert Voss
Herbert.Voss at FU-Berlin.DE
Tue Dec 11 14:31:50 CET 2007
Bernd Sellentin schrieb:
> Yes, thats what I wanted. Great. But one problem remains: by giving a negativ
> arrowsize, one could change the side, on which the hook is drawn. Thats wrong
> with this new one, see example:
>
> \documentclass[11pt]{minimal}
> \usepackage{pstricks-add}
> \makeatletter
> \edef\pst at arrowtable{\pst at arrowtable,D-D}
> \@namedef{psas at D}{
> false \psk at arrowinset \psk at arrowlength \psk at arrowsize
> CLW mul add dup
> 2 div /w ED
> mul dup /h ED
> mul /Inset ED
> { 0 h T 1 -1 scale } if
> 0 h Inset sub moveto
> w neg h L 0 0 L
> gsave fill grestore }
> \makeatother
\makeatletter
\edef\pst at arrowtable{\pst at arrowtable,D-D}
\@namedef{psas at D}{
\psk at arrowinset \psk at arrowlength \psk at arrowsize exch
dup 0 gt {/Positive true def}{/Positive false def} ifelse
abs exch
CLW mul add dup
2 div /w ED
mul dup /h ED
mul /Inset ED
0 h Inset sub moveto
w Positive {neg} if h L 0 0 L
gsave fill grestore }
\makeatother
Herbert
More information about the PSTricks
mailing list