Customizing a topology widget layout
A topology widget can be configured to display a layout
view other than the default tree layout.
About this task
Procedure
- Create a properties file for the topology widget using
the following file naming convention (unless a properties file already
exists for the policy):
$IMPACT_HOME/uiproviderconfig/properties/Policy_<PolicyName>_<Output Parameter name>.properties
For example, for a policy named
TestTopologyand an output parameter namedResult, the properties file would be:$IMPACT_HOME/uiproviderconfig/properties/Policy_TestTopology_Result.properties
- Edit the file and add the following properties:
topology.layout=hierarchical topology.layout.params={flowDirection: "bottom", globalLinkStyle: "orthogonal"}In this example, the layout has been set tohierarchical. You can settopology.layoutto one of the following values:treehierarchicalgridforceDirectedshortLinklongLink
Each layout is configured by a set of parameters. The parameters are specified by setting
topology.layout.paramsto a comma-separated list ofkey:valuepairs. The following tables show the parameters that are available of each of thetopology.layoutvalues.Table 1. Parameters available with tree.Key
Available Values
layoutModefreeleveltip overtip leaves overtip roots overtip roots and leaves overradialalternating radial
flowDirectionrightlefttopbottom
globalLinkStylestraightno reshapeorthogonalmixed
connectorStyleautomaticcenteredevenly spaced
globalAlignmentcenterborder centereastwesttip overtip over westtip over east westtip over both sidesmixed
levelAlignmentcenternorthsouth
aspectRatio110
Table 2. Parameters available with hierarchical.Key
Available Values
flowDirectionrightlefttopbottom
levelJustificationcenterleftrighttopbottom
levelingStrategyoptimalsemi optimalhigher levelslower levelsspread out
globalLinkStylepolylineorthogonalstraightmixedno reshape
connectorStyleautomaticcenteredevenly spaced
horizontalNodeOffset0100
horizontalLinkOffset0100
horizontalNodeLinkOffset0100
verticalNodeOffset0100
verticalLinkOffset0100
verticalNodeLinkOffset0100
Table 3. Parameters available with grid.Key
Available Values
layoutModetile to grid fixed heighttile to grid fixed widthtile to columnstile to rows
globalHorizontalAlignmentcenterleftright
globalVerticalAlignmentcentertopbottom
maxNumberOfNodesPerRowOrColumn110
compareModeorder by indexorder alphabetically
Table 4. Parameters available with forceDirected.Key
Available Values
layoutModefast multilevelincrementalnon incremental
preferredLinksLength2545
linkStylestraightno reshape
maxAllowedMaxPerIteration525
allowedNumberOfIterations2501250
convergenceThreshold0.13.5
Table 5. Parameters available with shortLink.Key
Available Values
globalLinkStyledirectorthogonalmixedno reshape
globalSelfLinkStyletwo bends orthogonalthree bends orthogonal
globalConnectorStyleautomaticfixed offsetevenly spacedmixed
linkOffset020
minFinalSegmentLength10100
flowDirectionrightlefttopbottom
levelJustificationcenterleftrighttopbottom
levelingStrategyoptimalsemi optimalhigher levelslower levelsspread out
connectorStyleautomaticcenteredevenly spaced
Table 6. Parameters available with longLink.Key
Available Values
globalLinkStyledirectorthogonalmixedno reshape
verticalMinOffset120
horizontalMinOffset120
flowDirectionrightlefttopbottom
levelJustificationcenterleftrighttopbottom
levelingStrategyoptimalsemi optimalhigher levelslower levelsspread out
connectorStyleautomaticcenteredevenly spaced
Note:Changes to the properties file do not appear in the widget immediately, you have to wait for the automatic refresh that is done by Impact in the backend or restart Impact UI server.