Class mxOrganicLayoutPrefsCmd

java.lang.Object
org.scijava.AbstractContextual
org.scijava.command.ContextCommand
sc.fiji.snt.gui.cmds.mxOrganicLayoutPrefsCmd
All Implemented Interfaces:
Runnable, org.scijava.Cancelable, org.scijava.command.Command, org.scijava.Contextual, org.scijava.plugin.SciJavaPlugin

public class mxOrganicLayoutPrefsCmd extends org.scijava.command.ContextCommand
Command for setting parameters of the mxOrganicLayout Graph layout used in GraphEditor. Parameter descriptions taken directly from the mxOrganicLayout javadocs
Author:
Cameron Arshadi
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected double
    Cost factor applied to energy calculations for node proximity to the notional border of the graph.
    protected boolean
    Specifies if the STYLE_NOEDGESTYLE flag should be set on edges that are modified by the result.
    protected double
    Cost factor applied to energy calculations involving edges that cross over one another.
    protected double
    Cost factor applied to energy calculations involving the distance nodes and edges.
    protected double
    Cost factor applied to energy calculations for the edge lengths.
    protected double
    The radius below which fine-tuning of the layout should start This involves allowing the distance between nodes and edges to be taken into account in the total energy calculation.
    protected int
    Limit to the number of iterations that may take place.
    protected double
    Cost factor applied to energy calculations involving the general node distribution of the graph.
    protected double
    The factor by which the moveRadius is multiplied by after every iteration.
    protected boolean
    Specifies if all edge points of traversed edges should be removed.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static void
    main(String[] args)
     
    void
    run()
     

    Methods inherited from class org.scijava.command.ContextCommand

    cancel, getCancelReason, isCanceled

    Methods inherited from class org.scijava.AbstractContextual

    context, getContext

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.scijava.Contextual

    setContext
  • Field Details

    • radiusScaleFactor

      protected double radiusScaleFactor
      The factor by which the moveRadius is multiplied by after every iteration. A value of 0.75 is a good balance between performance and aesthetics. Increasing the value provides more chances to find minimum energy positions and decreasing it causes the minimum radius termination condition to occur more quickly.
    • fineTuningRadius

      protected double fineTuningRadius
      The radius below which fine-tuning of the layout should start This involves allowing the distance between nodes and edges to be taken into account in the total energy calculation. If this is set to zero, the layout will automatically determine a suitable value
    • maxIterations

      protected int maxIterations
      Limit to the number of iterations that may take place. This is only reached if one of the termination conditions does not occur first.
    • edgeDistanceCostFactor

      protected double edgeDistanceCostFactor
      Cost factor applied to energy calculations involving the distance nodes and edges. Increasing this value tends to cause nodes to move away from edges, at the partial cost of other graph aesthetics. isOptimizeEdgeDistance must be true for edge to nodes distances to be taken into account.
    • edgeCrossingCostFactor

      protected double edgeCrossingCostFactor
      Cost factor applied to energy calculations involving edges that cross over one another. Increasing this value tends to result in fewer edge crossings, at the partial cost of other graph aesthetics. isOptimizeEdgeCrossing must be true for edge crossings to be taken into account.
    • nodeDistributionCostFactor

      protected double nodeDistributionCostFactor
      Cost factor applied to energy calculations involving the general node distribution of the graph. Increasing this value tends to result in a better distribution of nodes across the available space, at the partial cost of other graph aesthetics. isOptimizeNodeDistribution must be true for this general distribution to be applied.
    • borderLineCostFactor

      protected double borderLineCostFactor
      Cost factor applied to energy calculations for node proximity to the notional border of the graph. Increasing this value results in nodes tending towards the centre of the drawing space, at the partial cost of other graph aesthetics. isOptimizeBorderLine must be true for border repulsion to be applied.
    • edgeLengthCostFactor

      protected double edgeLengthCostFactor
      Cost factor applied to energy calculations for the edge lengths. Increasing this value results in the layout attempting to shorten all edges to the minimum edge length, at the partial cost of other graph aesthetics. isOptimizeEdgeLength must be true for edge length shortening to be applied.
    • disableEdgeStyle

      protected boolean disableEdgeStyle
      Specifies if the STYLE_NOEDGESTYLE flag should be set on edges that are modified by the result. Default is true.
    • resetEdges

      protected boolean resetEdges
      Specifies if all edge points of traversed edges should be removed. Default is true.
  • Constructor Details

    • mxOrganicLayoutPrefsCmd

      public mxOrganicLayoutPrefsCmd()
  • Method Details

    • run

      public void run()
    • main

      public static void main(String[] args)