The layout engine allows to automatically arrange elements (nodes, edges and groups) of the graph using various layout algorithms. It offers an Automatic Layout option which ensures that the graph keeps its layout arrangement, even during user-interactions. The following layout algorithms are implemented within the Graph Framework. In Addition the object-oriented concept of the layout engine allows the implementation of customized layout algorithms or the extension of existing algorithms as a service provided from Tensegrity.
Edge Layout Algorithm
The Edge Layout Algorithm routes edges without moving any nodes. Most layout algorithms arrange nodes and edges at the same time; however, the Edge Layout Algorithm is able to route edges without moving nodes. An Edge Layout Algorithm is an essential part of every application that supports runtime user-interaction.
The provided Edge Layout Algorithm is an extremely fast layout algorithm. It can be used to route edges completely, or just to improve the existing layout of edges.
The Hierarchical Layout Algorithm uses a Sugiyama layout algorithm to arrange a graph by placing nodes in different layers (rows and columns of an imaginary 2D grid) in such a way that most visual edges flow in the same direction and the number of their intersections are minimized. Because graphs arranged by hierarchical layout show the flow and hierarchy very clearly, it is often chosen for the arrangement of flow diagrams, process charts and workflows.
The Energy Layout Algorithm uses a force-directed layout algorithm to arrange a given graph. The layout algorithm regards a graph as a system of forces and attempts to find a minimum energy configuration. In this system the nodes of a graph are regarded as electrically charged particles that repel one another and the edges are considered springs that hold them back. The result of the energy layout is very natural and harmonic and is ideal for the layout of social networks and for simulating physical and chemical models. The energy layout creates a harmonic and balanced result; however, it is not very fast, and it is unable to guarantee a graph without crossed edges.
The Circular Layout Algorithm emphasizes group and tree structures within a network. It partitions nodes into groups by analyzing the connectivity structure of the network. The detected groups are arranged on separate circles. The circles themselves are arranged in a radial-tree layout fashion. This Node Layout implementation might be used for the visualization of social, telecommunication and computer networks.
The Tree Layout Algorithm arranges trees, rooted graphs with no cycles ( the nodes are not allowed to have more the one parent). The Tree Layout Algorithm offers four different styles for arranging trees: plan, radial, loop and HV-diagram.
The Orgchart Layout Algorithm is a special kind of Tree Layout Algorithm. It provides some special arrangement styles which are usually used for the visualization of organization charts. The Orgchart Layout Algorithm also allows associated connections between nodes across the tree. Different styles can be used within the same graph without the need for groups.