#Arrows between shapes in cetz

8 messages · Page 1 of 1 (latest)

indigo brook
#

Is there a recommended way to draw arrows between shapes in cetz?

#

I am just starting to get into cetz (i have a moderate fluency in tikz) and want to draw an arrow between circles; am I missing something? how do I do it?
in tikz it would be something like:

\node[circle] (C1) at (0,0) {};
\node[circle] (C2) at (2,0) {};
\draw[->] (C1) -- (C2);

here I have the following for the circles:

#cetz.canvas(length: 1cm, {
  import cetz.draw: *

  circle((0,0), name: "C1")
  circle((3,0), name: "C2")
})

not sure how to draw a line between, though :/

#

argh, can't figure out how to link to another discord thread

magic slate
#

line("C1", "C2")?

#

or line("C1.right", "C2.left")

indigo brook
#

The latter... I was looking for the general case where they may not be horizontally or vertically aligned

#

but that gets me going, thanks