130 if (w > 0.0 && w <= 100.0) {
131 m_weightSegments = w;
140 if (w >= 0.0 && w <= 100.0) {
141 m_weightBalancing = w;
Declaration of interface hierarchy layout algorithms (3.
Stores additional attributes of a graph (like layout information).
Interface of hierarchy layout algorithms.
The LP-based hierarchy layout algorithm.
void weightBalancing(double w)
Sets the weight for balancing successors below a node to w; 0.0 means no balancing.
OptimalHierarchyLayout & operator=(const OptimalHierarchyLayout &)
Assignment operator.
bool m_fixedLayerDistance
Use fixed layer distances?
bool fixedLayerDistance() const
Returns the current setting of option fixedLayerDistance.
void computeYCoordinates(const HierarchyLevelsBase &levels, GraphAttributes &AGC)
double weightSegments() const
Returns the weight of edge segments connecting to vertical segments.
double m_nodeDistance
The minimal distance between nodes.
void layerDistance(double x)
Sets the minimal allowed y-distance between layers to x.
double layerDistance() const
Returns the minimal allowed y-distance between layers.
double m_weightBalancing
The weight for balancing.
OptimalHierarchyLayout(const OptimalHierarchyLayout &)
Copy constructor.
~OptimalHierarchyLayout()
OptimalHierarchyLayout()
Creates an instance of optimal hierarchy layout.
void fixedLayerDistance(bool b)
Sets the option fixedLayerDistance to b.
double m_layerDistance
The minimal distance between layers.
void weightSegments(double w)
Sets the weight of edge segments connecting to vertical segments to w.
double weightBalancing() const
Returns the weight for balancing successors below a node; 0.0 means no balancing.
virtual void doCall(const HierarchyLevelsBase &levels, GraphAttributes &AGC) override
Implements the algorithm call.
double nodeDistance() const
Returns the minimal allowed x-distance between nodes on a layer.
void nodeDistance(double x)
Sets the minimal allowed x-distance between nodes on a layer to x.
double m_weightSegments
The weight of edge segments.
void computeXCoordinates(const HierarchyLevelsBase &levels, GraphAttributes &AGC)
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
static MultilevelBuilder * getDoubleFactoredZeroAdjustedMerger()
The namespace for all OGDF objects.