Open
Graph Drawing
Framework

 v. 2020.02 (Catalpa)
 

ClusterPlanarizationLayout.h
Go to the documentation of this file.
1 
33 #pragma once
34 
37 #include <memory>
38 
39 namespace ogdf {
40 
42 
81 {
82 public:
85 
88 
89 
90 
92 
98  virtual void call(
99  Graph& G,
100  ClusterGraphAttributes& acGraph,
101  ClusterGraph& cGraph,
102  bool simpleCConnect = true);
104 
111  virtual void call(
112  Graph& G,
113  ClusterGraphAttributes& acGraph,
114  ClusterGraph& cGraph,
115  EdgeArray<double>& edgeWeight,
116  bool simpleCConnect = true);
117 
118 
120  double pageRatio() const {
121  return m_pageRatio;
122  }
123 
125  void pageRatio(double ratio) {
126  m_pageRatio = ratio;
127  }
128 
131  m_planarLayouter.reset(pPlanarLayouter);
132  }
133 
135  void setPacker(CCLayoutPackModule *pPacker) {
136  m_packer.reset(pPacker);
137  }
138 
139 #if 0
140  int numberOfCrossings() const {
142  return m_nCrossings;
143  }
144 #endif
145 
146 
147 protected:
149  {
150  double m_minx, m_maxx, m_miny, m_maxy, m_width, m_height;
151  };
152 
153  void computeClusterPositions(
154  ClusterPlanRep& CP,
155  Layout drawing,
157 
158 
159 private:
160  std::unique_ptr<LayoutClusterPlanRepModule> m_planarLayouter;
161  std::unique_ptr<CCLayoutPackModule> m_packer;
162 
163  double m_pageRatio;
164 
166 };
167 
168 }
Declaration of interface for planar layout algorithms for UML diagrams (used in planarization approac...
Data type for general directed graphs (adjacency list representation).
Definition: Graph_d.h:492
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Definition: config.h:99
Indexed arrays using hashing for element access.
Definition: HashArray.h:94
Representation of clustered graphs.
Definition: ClusterGraph.h:291
std::unique_ptr< CCLayoutPackModule > m_packer
The packing algorithm.
virtual ~ClusterPlanarizationLayout()
Destruction.
Base class of algorithms that arrange/pack layouts of connected components.
Stores additional attributes of a clustered graph (like layout information).
The cluster planarization layout algorithm.
Planarized representations for clustered graphs.
std::unique_ptr< LayoutClusterPlanRepModule > m_planarLayouter
The planar layouter.
void setPacker(CCLayoutPackModule *pPacker)
Sets the module option for the arrangement of connected components to pPacker.
Interface for planar cluster layout algorithms.
int m_nCrossings
The number of crossings (not yet used!).
The namespace for all OGDF objects.
void setPlanarLayouter(LayoutClusterPlanRepModule *pPlanarLayouter)
Sets the module option for the planar layout algorithm to pPlanarLayouter.
double pageRatio() const
Returns the current page ratio (= desired width / height of layout).
void pageRatio(double ratio)
Sets the page ratio to ratio.
Declaration of interface for algorithms that arrange/pack layouts of connected components.
Stores a layout of a graph (coordinates of nodes, bend points of edges).
Definition: Layout.h:46