[pstricks] Another node connection needed

Herbert Voss Herbert.Voss at fu-berlin.de
Tue Jul 3 21:28:15 CEST 2007


Herbert Voss wrote:
> Boris Veytsman wrote:
>   
>> I think I need another type of node connection.  It is like ncbar (or
>> ncbarr in pstricks-add), but has 5 segments.
>>
>> 1.  Two segments armA and armB go from nodes A and B with angles
>>     angleA and angleB correspondingly.
>>
>> 2.  The ends are connected by \ncbar with arm armC and angle angleC.
>>
>> Here is an example with angleA=0, angleB=-180, angleC=90:
>>
>>      -----------
>>      |         |
>>   A---         -----B
>>     

if your angels are always 0 and 90 then use \ncloop, it is easier ...

\begin{pspicture}(5,5)
\pnode(1,3){A}\pnode(5,3){B}\psdot[linecolor=red](A)\psdot[linecolor=red](B)
\ncloop[angleB=180,loopsize=1cm,arm=1cm]{A}{B}
\rnode{A}{NodeA}\hspace{4cm}\ovalnode{B}{NodeB}
\ncloop[arm=1cm,angleB=180,loopsize=1.5cm,linestyle=dashed]{A}{B}
\end{pspicture}


Herbert



More information about the PSTricks mailing list