Given an arbitrary point, let's say p, that may or may not be obtained by several indirect processes such as penpos or by intersections, how do I get to display the coordinates "(px,py)" of the point in the pdf generated ? when I don't have those coordinates to beguin with ? I remember having done this once already, but I forgot how to do it.
Given a pair
p, the two values are available as
xpart p and
To make a string representation of the pair try:
"(" & decimal xpart p & "," & decimal ypart p & ")"
You can then type set that string as usual with
infont or the
label.bot(TEX("$(" & decimal xpart p & "," & decimal ypart p & ")$"), (10, 20));
This is rather less cumbersome if you use the built-in plain shorthand notation for pairs. So given a pair variable
z1, the two values are available as
y1. And you can make a string representation as
"(" & decimal x1 & "," & decimal y1 & ")"