*
* Option | Type | Default | Description
* |
* nodeDistance | double | 3.0
* | The minimal allowed x-distance between nodes on a layer.
* |
* layerDistance | double | 3.0
* | The minimal allowed y-distance between layers.
* |
* fixedLayerDistance | bool | false
* | If set to true, the distance between neighboured layers is always
* layerDistance; otherwise the distance is adjusted (increased) to improve readability.
* |
* weightSegments | double | 2.0
* | The weight of edge segments connecting to vertical segments.
* |
* weightBalancing | double | 0.1
* | The weight for balancing successors below a node; 0.0 means no balancing.
* |
* weightClusters | double | 0.05
* | The weight for cluster boundary variables.
* |
*
*/
class OGDF_EXPORT OptimalHierarchyClusterLayout : public HierarchyClusterLayoutModule
{
public:
//! Creates an instance of optimal hierarchy layout for clusters.
OptimalHierarchyClusterLayout();
//! Copy constructor.
OptimalHierarchyClusterLayout(const OptimalHierarchyClusterLayout &);
// destructor
~OptimalHierarchyClusterLayout() { }
//! Assignment operator.
OptimalHierarchyClusterLayout &operator=(const OptimalHierarchyClusterLayout &);
/**
* @name Optional parameters
* @{
*/
//! Returns the minimal allowed x-distance between nodes on a layer.
double nodeDistance() const {
return m_nodeDistance;
}
//! Sets the minimal allowed x-distance between nodes on a layer to \p x.
void nodeDistance(double x) {
if(x >= 0)
m_nodeDistance = x;
}
//! Returns the minimal allowed y-distance between layers.
double layerDistance() const {
return m_layerDistance;
}
//! Sets the minimal allowed y-distance between layers to \p x.
void layerDistance(double x) {
if(x >= 0)
m_layerDistance = x;
}
//! Returns the current setting of option