Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

Loading...
Searching...
No Matches
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
39namespace ogdf {
40class Color;
41class GraphAttributes;
42
44OGDF_EXPORT extern const std::array<Color, 63> colors;
45
47OGDF_EXPORT void spreadParallels(GraphAttributes& GA, double min_spread = 0.1,
48 double max_spread = 0.6, double max_abs = 100);
49
51OGDF_EXPORT void fixLoops(Graph& G, const std::function<void(edge, edge)>& cb);
52
54OGDF_EXPORT void fixParallels(Graph& G, const std::function<void(edge, edge)>& cb);
55
58OGDF_EXPORT void bendEdge(GraphAttributes& GA, edge e, double bend);
59
60}
Includes declaration of graph class.
Basic declarations, included by all source files.
Class for the representation of edges.
Definition Graph_d.h:364
Stores additional attributes of a graph (like layout information).
Data type for general directed graphs (adjacency list representation).
Definition Graph_d.h:866
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF dynamic library (shared object / DLL),...
Definition config.h:117
The namespace for all OGDF objects.
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.
const std::array< Color, 63 > colors
An array of 63 different colors to cycle through.
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.
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.
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...