Open
Graph Drawing
Framework

 v. snapshot-2017-02-16
 

ClusterPlanarizationLayout.h
Go to the documentation of this file.
1 
33 #pragma once
34 
37 #include <memory>
38 
39 
40 namespace ogdf {
41 
42 
44 
83 {
84 public:
87 
90 
91 
92 
94 
100  virtual void call(
101  Graph& G,
102  ClusterGraphAttributes& acGraph,
103  ClusterGraph& cGraph,
104  bool simpleCConnect = true);
106 
113  virtual void call(
114  Graph& G,
115  ClusterGraphAttributes& acGraph,
116  ClusterGraph& cGraph,
117  EdgeArray<double>& edgeWeight,
118  bool simpleCConnect = true);
119 
120 
122  double pageRatio() const {
123  return m_pageRatio;
124  }
125 
127  void pageRatio(double ratio) {
128  m_pageRatio = ratio;
129  }
130 
133  m_planarLayouter.reset(pPlanarLayouter);
134  }
135 
137  void setPacker(CCLayoutPackModule *pPacker) {
138  m_packer.reset(pPacker);
139  }
140 
141 #if 0
142  int numberOfCrossings() const {
144  return m_nCrossings;
145  }
146 #endif
147 
148 
149 protected:
151  {
152  double m_minx, m_maxx, m_miny, m_maxy, m_width, m_height;
153  };
154 
155  void computeClusterPositions(
156  ClusterPlanRep& CP,
157  Layout drawing,
159 
160 
161 private:
162  std::unique_ptr<LayoutClusterPlanRepModule> m_planarLayouter;
163  std::unique_ptr<CCLayoutPackModule> m_packer;
164 
165  double m_pageRatio;
166 
168 };
169 
170 
171 } // end namespace ogdf
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:472
#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