shamansir / elm-graph-render / Graph.Geometry.Make

make : Way a -> (a -> { width : Basics.Float, height : Basics.Float }) -> Graph.Tree.Forest a -> Graph.Geometry.Geometry a

Distribute the forest over the area: calculate positions for all the items in the requested way and the area they will take. As the next step Geometry is provided to the rendering function to actually apply it.

Way


type Way a
    = Vertical Graph.Geometry.Vertical.Options
    | Radial (Graph.Geometry.Radial.Options a)

The way graph is distributed.

For Vertical way, provide options from Graph.Geometry.Vertical, and for Radial, the ones from Graph.Geometry.Radial, correspondingly.

defaultWay : Way a

vertical : Graph.Geometry.Vertical.Options -> Way a

radial : Graph.Geometry.Radial.Options a -> Way a