Package sc.fiji.snt.gui.cmds
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
FieldsModifier and TypeFieldDescriptionprotected doubleCost factor applied to energy calculations for node proximity to the notional border of the graph.protected booleanSpecifies if the STYLE_NOEDGESTYLE flag should be set on edges that are modified by the result.protected doubleCost factor applied to energy calculations involving edges that cross over one another.protected doubleCost factor applied to energy calculations involving the distance nodes and edges.protected doubleCost factor applied to energy calculations for the edge lengths.protected doubleThe 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 intLimit to the number of iterations that may take place.protected doubleCost factor applied to energy calculations involving the general node distribution of the graph.protected doubleThe factor by which themoveRadiusis multiplied by after every iteration.protected booleanSpecifies if all edge points of traversed edges should be removed. -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class org.scijava.command.ContextCommand
cancel, getCancelReason, isCanceledMethods inherited from class org.scijava.AbstractContextual
context, getContextMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.scijava.Contextual
setContext
-
Field Details
-
radiusScaleFactor
protected double radiusScaleFactorThe factor by which themoveRadiusis 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 fineTuningRadiusThe 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 maxIterationsLimit 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 edgeDistanceCostFactorCost 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.isOptimizeEdgeDistancemust be true for edge to nodes distances to be taken into account. -
edgeCrossingCostFactor
protected double edgeCrossingCostFactorCost 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.isOptimizeEdgeCrossingmust be true for edge crossings to be taken into account. -
nodeDistributionCostFactor
protected double nodeDistributionCostFactorCost 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.isOptimizeNodeDistributionmust be true for this general distribution to be applied. -
borderLineCostFactor
protected double borderLineCostFactorCost 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.isOptimizeBorderLinemust be true for border repulsion to be applied. -
edgeLengthCostFactor
protected double edgeLengthCostFactorCost 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.isOptimizeEdgeLengthmust be true for edge length shortening to be applied. -
disableEdgeStyle
protected boolean disableEdgeStyleSpecifies if the STYLE_NOEDGESTYLE flag should be set on edges that are modified by the result. Default is true. -
resetEdges
protected boolean resetEdgesSpecifies 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
-