documentationfor yFiles for HTML 3.0.0.1

Radial Tree Layout (formerly: Balloon Layout)

This chapter describes the major API changes to the RadialTreeLayout (formerly called BalloonLayout) introduced with yFiles for HTML 3.0 and how to migrate from the older version.

Like all major layout algorithms, the class no longer inherits from MultiStageLayout, but implements ILayoutAlgorithm directly. The layout stages are now managed by a LayoutStageStack, which can be obtained via the layoutStages property; see the migration chapter Layout Stages and Multi-Stage Layouts for more details.

Renamed, Moved, and Removed Classes and Members

The following table lists the renamed, moved, and removed classes and members of the major classes of the RadialTreeLayout.

Renamed, moved, and removed members of classes related to the RadialTreeLayout (classes are bold)
yFiles for HTML 2.6 yFiles for HTML 3.0 Remarks
BalloonLayoutRadialTreeLayout
Properties in class RadialTreeLayout
comparerremovedUse childOrder instead
componentLayoutEnabledcomponentLayout.enabled
considerNodeLabelsnodeLabelPlacementHas been combined with properties IntegratedNodeLabeling and NodeLabelingPolicy.
fromSketchModeremovedUse the new enum value FROM_SKETCH instead.
hideGroupsStageremovedThe GroupHidingStage is enabled by default and can be accessed via the stack layoutStages.
hideGroupsStageEnabled
integratedEdgeLabelingedgeLabelPlacementIs now enabled by default (value INTEGRATED).
integratedNodeLabelingnodeLabelPlacementHas been combined with properties ConsiderNodeLabeling and NodeLabelingPolicy.
interleavedModeremovedInterleaved placement is automatically activated for nodes that are specified via property interleavedNodes.
labelingremovedTo influence the labeling, use the nodeLabelPlacement and edgeLabelPlacement properties.
labelingEnabled
layoutOrientationremovedChanging the layout orientation does not make sense for an undirected layout algorithm.
nodeLabelingPolicynodeLabelPlacementHas been combined with properties ConsiderNodeLabeling and IntegratedNodeLabeling.
orientationLayoutremovedChanging the layout orientation does not make sense for an undirected layout algorithm.
orientationLayoutEnabled
parallelEdgeRouterEnabledremovedUse property Enabled on parallelEdgeRouter instead.
preferredChildWedgepreferredChildSectorAngle
preferredRootWedgepreferredRootSectorAngle
rootNodePolicyremovedA custom root is now always used if defined in treeRoot.
selfLoopRouterEnabledremovedUse property Enabled on selfLoopRouter instead.
subgraphLayoutremovedIf necessary, the SubgraphLayoutStage can be accessed and enabled via method get<T> of property layoutStages, but this may lead to overlaps.
subgraphLayoutEnabled
BalloonLayoutDataRadialTreeLayoutData<TNode,TEdge,TNodeLabel,TEdgeLabel>
Properties in class RadialTreeLayoutData
abortHandlerremovedA LayoutAbortController is exposed by the LayoutExecutor; see Section Maximum Duration and Aborting of Algorithms for more details.
edgeLabelPreferredPlacementedgeLabelPreferredPlacements
nodeHalosnodeMargins
outEdgeComparerchildOrder

Changed Default Values and Behavior Changes

If non-tree graphs are provided as input, the layout algorithm now temporarily reduces them to trees by applying the TreeReductionStage. The non-tree edges are then routed using the router specified via the TreeReductionStage.nonTreeEdgeRouter. The TreeReductionStage used by the RadialTreeLayout is accessible via the property RadialTreeLayout.treeReductionStage.

The from-sketch mode (ordering policy FROM_SKETCH) does no longer take precedence over orders specified via layout data properties childOrder or nodeTypes.

Node labels are now considered by default. To change this behavior, set the nodeLabelPlacement property to the desired value. It is now also easier to place the node labels with GenericLabeling by setting the value to GENERIC.

Edge labels are now placed by default using an integrated edge labeling algorithm. To change this behavior set the edgeLabelPlacement property to the desired value. It is now also easier to place the edge labels with GenericLabeling by setting the value to GENERIC.

The default component arrangement style has been changed to PACKED_CIRCLE. The style can be specified via the ComponentLayout.style property. The ComponentLayout used by the RadialTreeLayout is accessible via the componentLayout property.

The compactnessFactor is now interpreted differently. Larger values now produce more compact layouts. The range of the compactness factor has been changed to the interval between 0 and 1.

Major Changes to Expert API

The changes described in this chapter only affect users who work directly with the LayoutGraph API, such as when writing custom layout algorithms.

Several methods for advanced customization of the layout result have been removed from the API, including calculateChildArrangement and calculateAngles. Overriding these methods should not have been necessary. To customize the preferred sector angles, the callback method getPreferredChildSectorAngle is still available.

The helper class BalloonLayoutNodeInfo has also been removed. It was only necessary and useful during the layout process and when overriding advanced methods that have now been removed.