Arrow Shapes | Graphviz - Graph Visualization Software

# Graphviz - Graph Visualization Software Drawing graphs since 1988

# Arrow Shapes Arrow shapes can be specified and named using the following simple grammar. Terminals are shown in bold font and nonterminals in italics. Literal characters are given in single quotes. Square brackets [ and ] enclose optional items. Vertical bars | separate alternatives.
arrowname | : | aname [ aname [ aname [ aname ] ] ]
aname | : | [ modifiers ] shape
modifiers | : | [ 'o' ] [ side ]
side | : | 'l'
| | | 'r'
shape | : | box
| | | crow
| | | curve
| | | diamond
| | | dot
| | | inv
| | | none
| | | normal
| | | tee
| | | vee
The primitive shapes are:
"box" |  | "crow" |  | "curve" |  | "diamond" |  | "dot" |
"inv" |  | "none" |  | "normal" |  | "tee" |  | "vee" |

As for the modifiers:

'l'
  Clip the shape, leaving only the part to the left of the edge.
'r'
  Clip the shape, leaving only the part to the right of the edge.
'o'
  Use an open (non-filled) version of the shape.

Left and right are defined as those directions determined by looking from the edge towards the point where the arrow "touches" the node.

As an example, the arrow shape `lteeoldiamond` is parsed as `'l' 'tee' 'o' 'l' 'diamond'` and corresponds to the shape

Note that the first arrow shape specified occurs closest to the node. Subsequent arrow shapes, if specified, occur further from the node. Also, a shape of `none` uses space, so, for example, the arrowhead `nonenormal` is not the same as `normal`.

Not all syntactically legal combinations of modifiers are meaningful or semantically valid. For example, none of the modifiers make any sense with `none`. The following table indicates which modifiers are allowed with which shapes.

Modifier | box | crow | curve | diamond | dot | inv | none | normal | tee | vee
--- | --- | --- | --- | --- | --- | --- | --- | --- | --- | ---
'l'/'r' | X | X | X | X |  | X |  | X | X | X
'o' | X |  |  | X | X | X |  | X |  |

This yields 39 different arrow shapes. The optional second, third, fourth shapes can independently be any of the 39, except the last cannot be `none` as this would create a redundant shape. Thus, there are 38 · 393 + 38 · 392 + 38 · 39 + 39 = 2,313,441 different combinations.

The following display contains the 39 combinations possible with a single arrow shape. The node attached to the arrow is not drawn but would appear on the right side of the edge.

box | lbox | rbox | obox | olbox | orbox
crow | lcrow | rcrow
diamond | ldiamond | rdiamond | odiamond | oldiamond | ordiamond
dot | odot
inv | linv | rinv | oinv | olinv | orinv
none
normal | lnormal | rnormal | onormal | olnormal | ornormal
tee | ltee | rtee
vee | lvee | rvee
curve | lcurve | rcurve

## Recent comments

- gvFreeLayout
  5 hours 16 min ago
- Can you be more specific as
  6 hours 19 min ago
- I don't understand. Anyone
  7 hours 52 min ago
- It looks somehow complicated
  16 hours 4 min ago
- Your patch has been applied.
  2 days 3 hours ago
- workaround: downgrade to 2.20.2, bug #2397 opened
  2 days 7 hours ago
- this is regression since graphviz 2.20.2
  2 days 10 hours ago
- Graphviz on iPhone
  4 days 12 hours ago
- You can certainly modify and
  1 week 1 day ago
- Future features should be
  1 week 1 day ago