Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

Drawing.h
Go to the documentation of this file.
1 
31 #pragma once
32 
33 #include <ogdf/basic/Graph.h>
34 
35 #include <array>
36 #include <functional>
37 
38 namespace ogdf {
39 class Color;
40 class GraphAttributes;
41 
43 OGDF_EXPORT extern const std::array<Color, 63> colors;
44 
46 OGDF_EXPORT void spreadParallels(GraphAttributes& GA, double min_spread = 0.1,
47  double max_spread = 0.6, double max_abs = 100);
48 
50 OGDF_EXPORT void fixLoops(Graph& G, const std::function<void(edge, edge)>& cb);
51 
53 OGDF_EXPORT void fixParallels(Graph& G, const std::function<void(edge, edge)>& cb);
54 
57 OGDF_EXPORT void bendEdge(GraphAttributes& GA, edge e, double bend);
58 
59 }
ogdf
The namespace for all OGDF objects.
Definition: AugmentationModule.h:36
Graph.h
Includes declaration of graph class.
ogdf::fixLoops
void fixLoops(Graph &G, const std::function< void(edge, edge)> &cb)
Safely call a function on all self-loops to, e.g., subdivide or remove them.
ogdf::fixParallels
void fixParallels(Graph &G, const std::function< void(edge, edge)> &cb)
Safely call a function on all parallel edges to, e.g., subdivide or remove them.
ogdf::spreadParallels
void spreadParallels(GraphAttributes &GA, double min_spread=0.1, double max_spread=0.6, double max_abs=100)
A bends to parallel edges to make them distinguishable.
ogdf::edge
EdgeElement * edge
The type of edges.
Definition: Graph_d.h:67
ogdf::colors
const std::array< Color, 63 > colors
An array of 63 different colors to cycle through.
ogdf::bendEdge
void bendEdge(GraphAttributes &GA, edge e, double bend)
Add a bendpoint to the middle of an edges that is shifted orthogonally by a certain fraction of the e...
OGDF_EXPORT
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Definition: config.h:101
ogdf::gdf::EdgeAttribute::Color
@ Color