Open
Graph Drawing
Framework

 v. snapshot-2017-02-16
 

SimpleCCPacker.h
Go to the documentation of this file.
1 
35 #pragma once
36 
38 
39 
40 namespace ogdf {
41 
44 {
45 public:
46  // !Constructor for the CCPacker
47  explicit SimpleCCPackerModule(LayoutModule* pSubLayoutModule = nullptr) : m_pSubLayoutModule(pSubLayoutModule)
48 {
49  m_leftMargin = 10.0;
50  m_rightMargin = 10.0;
51  m_bottomMargin = 10.0;
52  m_topMargin = 10.0;
53 }
54 
55  void setMargins(double left, double top, double right, double bottom)
56  {
57  m_leftMargin = left;
58  m_rightMargin = right;
59  m_bottomMargin = bottom;
60  m_topMargin = top;
61  }
62 
63  virtual void call(GraphAttributes& GA) override;
64 
65 protected:
66  double m_leftMargin;
67  double m_rightMargin;
69  double m_topMargin;
70 
71  void computeBoundingBox(const GraphAttributes& graphAttributes, DPoint& min_coord, DPoint& max_coord);
73 };
74 
75 } // end of namespace ogdf
void computeBoundingBox(const GraphAttributes &graphAttributes, DPoint &min_coord, DPoint &max_coord)
LayoutModule * m_pSubLayoutModule
Real points.
Definition: geometry.h:219
virtual void call(GraphAttributes &GA) override
Computes a layout of graph GA.
Stores additional attributes of a graph (like layout information).
Declaration of interface for layout algorithms (class LayoutModule)
Interface of general layout algorithms.
Definition: LayoutModule.h:44
The namespace for all OGDF objects.
void setMargins(double left, double top, double right, double bottom)
SimpleCCPackerModule(LayoutModule *pSubLayoutModule=nullptr)
A Layout Module for using the TileToRowsCCPacker.