21 #ifndef _Tulip_NODELINKDIAGRAMCOMPONENT_H 22 #define _Tulip_NODELINKDIAGRAMCOMPONENT_H 24 #include <tulip/GlMainView.h> 25 #include <tulip/Camera.h> 28 class GridOptionsWidget;
36 class GlCompositeHierarchyManager;
37 class PropertyInterface;
39 class ViewToolTipAndUrlManager;
45 QDialog *_gridOptions;
46 GlCompositeHierarchyManager *manager;
49 void registerTriggers();
52 Ui::GridOptionsWidget *grid_ui;
55 static const std::string viewName;
57 "The Node Link Diagram view is the standard representation of relational data, " 58 "where entities are represented as nodes, and their relation as edges.<br>" 59 "This view allows you to change the glyph used to represent nodes (e.g. " 60 "square, round, cross, ...), as well as the shape of the arrows indicating the " 61 "direction of the relationship.",
64 NodeLinkDiagramComponent(const
tlp::PluginContext *context =
nullptr);
65 ~NodeLinkDiagramComponent() override;
66 std::
string icon()
const override {
67 return ":/tulip/gui/icons/32/node_link_diagram_view.png";
74 void requestChangeGraph(Graph *graph);
75 const Camera &goInsideItem(node meta);
86 void setZOrdering(
bool);
87 void showGridControl();
88 void fillContextMenu(QMenu *menu,
const QPointF &point)
override;
90 void addRemoveItemToSelection(
bool pushGraph =
true,
bool toggleSelection =
true,
91 bool selectValue =
false,
bool resetSelection =
false);
92 void addRemoveInNodesToSelection(
bool pushGraph =
true,
bool toggleSelection =
true,
93 bool selectValue =
false,
bool resetSelection =
false);
94 void addRemoveOutNodesToSelection(
bool pushGraph =
true,
bool toggleSelection =
true,
95 bool selectValue =
false,
bool resetSelection =
false);
96 void addRemoveInEdgesToSelection(
bool pushGraph =
true,
bool toggleSelection =
true,
97 bool selectValue =
false,
bool resetSelection =
false);
98 void addRemoveOutEdgesToSelection(
bool pushGraph =
true,
bool toggleSelection =
true,
99 bool selectValue =
false,
bool resetSelection =
false);
100 void addRemoveNodeAndAllNeighbourNodesAndEdges(
bool toggleSelection =
true,
101 bool selectValue =
false,
102 bool resetSelection =
false);
103 void addRemoveExtremitiesToSelection(
bool pushGraph =
true,
bool toggleSelection =
true,
104 bool selectValue =
false,
bool resetSelection =
false);
105 void addRemoveEdgeAndExtremitiesToSelection(
bool toggleSelection =
true,
bool selectValue =
false,
106 bool resetSelection =
false);
109 void selectInNodes(
bool pushGraph =
true);
110 void selectOutNodes(
bool pushGraph =
true);
111 void selectInEdges(
bool pushGraph =
true);
112 void selectOutEdges(
bool pushGraph =
true);
113 void selectNodeAndAllNeighbourNodesAndEdges();
114 void selectExtremities(
bool pushGraph =
true);
115 void selectEdgeAndExtremities();
117 void addItemToSelection();
118 void addInNodesToSelection(
bool pushGraph =
true);
119 void addOutNodesToSelection(
bool pushGraph =
true);
120 void addInEdgesToSelection(
bool pushGraph =
true);
121 void addOutEdgesToSelection(
bool pushGraph =
true);
122 void addNodeAndAllNeighbourNodesAndEdgesToSelection();
123 void addExtremitiesToSelection(
bool pushGraph =
true);
124 void addEdgeAndExtremitiesToSelection();
126 void removeItemFromSelection();
127 void removeInNodesFromSelection(
bool pushGraph =
true);
128 void removeOutNodesFromSelection(
bool pushGraph =
true);
129 void removeInEdgesFromSelection(
bool pushGraph =
true);
130 void removeOutEdgesFromSelection(
bool pushGraph =
true);
131 void removeNodeAndAllNeighbourNodesAndEdgesFromSelection();
132 void removeExtremitiesFromSelection(
bool pushGraph =
true);
133 void removeEdgeAndExtremitiesFromSelection();
138 ViewToolTipAndUrlManager *_tturlManager;
142 void createScene(Graph *graph, DataSet dataSet);
143 DataSet sceneData()
const;
144 void loadGraphOnScene(Graph *graph);
145 void useHulls(
bool hasHulls);
146 bool hasHulls()
const;
147 void setupWidget()
override;
148 void editValue(PropertyInterface *pi);
An abstract view that displays a GlMainWidget as its central widget.
A container that can store data from any type.
#define PLUGININFORMATION(NAME, AUTHOR, DATE, INFO, RELEASE, GROUP)
Declare meta-information for a plugin This is an helper macro that defines every function related to ...