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 #include <ogdf/basic/basic.h>
35 
36 #include <array>
37 #include <functional>
38 
39 namespace ogdf {
40 class Color;
41 class GraphAttributes;
42 
44 OGDF_EXPORT extern const std::array<Color, 63> colors;
45 
47 OGDF_EXPORT void spreadParallels(GraphAttributes& GA, double min_spread = 0.1,
48  double max_spread = 0.6, double max_abs = 100);
49 
51 OGDF_EXPORT void fixLoops(Graph& G, const std::function<void(edge, edge)>& cb);
52 
54 OGDF_EXPORT void fixParallels(Graph& G, const std::function<void(edge, edge)>& cb);
55 
58 OGDF_EXPORT void bendEdge(GraphAttributes& GA, edge e, double bend);
59 
60 }
ogdf
The namespace for all OGDF objects.
Definition: multilevelmixer.cpp:39
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:74
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...
basic.h
Basic declarations, included by all source files.
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