layered

package
v2.10.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 9, 2026 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package layered is a Layout for a directed acyclic graph: each group is a layer, drawn as a band from the top down in the order the engine numbers them, so every edge runs from a band to one above it or along its own. Within a band, nodes are ordered by where their neighbours sit (the barycentre heuristic of Sugiyama's method), sweeping down and back up a few times, so edges cross as little as that cheap pass allows. A band too wide to read wraps onto rows of its own. Deterministic: the same input is always placed the same way.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Layout

type Layout struct{}

Layout is the layered layout.

func New

func New() Layout

New returns the layered layout.

func (Layout) Place

func (Layout) Place(nodes []layout.Node, edges []layout.Edge) []layout.Point

Place puts each group on a band of its own, in group order.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL