[pstricks] Node Coordinates

Douglas Reid douglas.reid at dunvegan.co.uk
Tue Jun 6 14:05:35 CEST 2006


Many thanks for your reply.

I appreciate the power of using nodes implicitly in the manner you illustrate.

However, I am still wondering how to recover the original x, y coordinates from the node name.

Surely, PSTricks stores the data that defines nodes in a form that is accessible to the programme?

Say I wanted to calculate the distance between node A and node B, how could that be done only using the nodes names implicitly?

pnodes are the simplest example.  The question is more complex where other types of nodes are involved in which it would also be interesting to determine the width and height of the node based on the node's name.

I have been spending a lot of time playing about with nodes.  There are various parameters the use of which is unclear.  For example, there is Xnodesep and Ynodesep.

One would assume that Xnodesep defines the x displacement from a node whilst Ynodesep determines the y displacement from the node.  However, this does not appear to be the reality, especially regarding Ynodesep!

There is an interesting example at

Denis Girou has defined the x and y displacements as follows:
\def\psset at Rx#1{\psset at XnodesepA{#1}}
\def\psset at Ry#1{\psset at offsetA{#1}}

His example works as described.

However, if the definition of Ry is changed to:
\def\psset at Ry#1{\psset at YnodesepA{#1}}
a different result is obtained.

For the cyan line, the resulting vertical displacement relative to B is 0 whereas one would expect it to be -2
So, the question arises as to what exactly YnodesepA does and why it appears to behave in a different manner to XnodesepA?

Is there any documentation available that explains the exact functionality of these parameters?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://tug.org/pipermail/pstricks/attachments/20060606/0f8ddbe1/attachment.html 

More information about the PSTricks mailing list