
Hi,
On Thu, Feb 27, 2025 at 9:04 PM Matthias Weber
Thanks!
Now, I would like to have arrows between cells. I have tried using overlays (see below), and I understand that an overlay is centered within the cell. How do I move the arrow so that it points from 6 to 7, for instance? (Starting a little to the right and above the 6, ending below and to the left of the 7)
Matthias
\starttext \startuseMPgraphic{DiagonalArrow} numeric w, h; w := OverlayWidth ; h := OverlayHeight ; draw lmt_arrow [ path =((.5*w,.5*w) -- (2*w,2*w)), ] withpen pencircle scaled (h/40) withcolor "darkgreen" ; \stopuseMPgraphic
\defineoverlay [DiagonalArrow] [\useMPgraphic{DiagonalArrow}]
\setupTABLE[c][width=1cm,offset=overlay,align={middle,lohi}] \setupTABLE[r][height=1cm] \bTABLE \bTR \bTD 17 \eTD \bTD 24 \eTD \bTD 1 \eTD \bTD 8\eTD \bTD 15 \eTD \eTR \bTR \bTD 23 \eTD \bTD 5 \eTD \bTD 7 \eTD \bTD 14\eTD \bTD 16 \eTD \eTR \bTR \bTD 4 \eTD \bTD [background=DiagonalArrow] 6 \eTD \bTD 13 \eTD \bTD 20\eTD \bTD 22 \eTD \eTR \bTR \bTD 10 \eTD \bTD 12 \eTD \bTD 19 \eTD \bTD 21\eTD \bTD 3 \eTD \eTR \bTR \bTD 11 \eTD \bTD 18 \eTD \bTD 25 \eTD \bTD 2\eTD \bTD 9 \eTD \eTR \eTABLE \stopExample
\stoptext
Maybe https://www.pragma-ade.com/general/manuals/metafun-p.pdf, section 5, Positional graphics, is what you look for? /Mikael