ui: extented graph view ui features

* fitting boxes to name length
* highlighting active edges and nodes
* hover for edges and nodes
* single click selection for edges and nodes
* edges have transparent second line for easier clicking
* sub structure class members by public/protected/private
This commit is contained in:
Eberhard Graether
2014-11-09 05:18:37 +01:00
parent 3441b6a8f4
commit 5b230cefa0
26 changed files with 644 additions and 417 deletions
+11 -1
View File
@@ -4,10 +4,13 @@
#include <list>
#include <memory>
#include "utility/types.h"
#include "component/view/View.h"
struct DummyEdge;
struct DummyNode;
class Graph;
class GraphEdge;
class GraphNode;
@@ -19,11 +22,18 @@ public:
virtual std::string getName() const;
virtual void rebuildGraph(const std::vector<DummyNode>& nodes, const std::vector<DummyEdge>& edges) = 0;
virtual void rebuildGraph(
std::shared_ptr<Graph> graph,
std::vector<Id> activeTokenIds,
const std::vector<DummyNode>& nodes,
const std::vector<DummyEdge>& edges) = 0;
virtual void clear() = 0;
protected:
std::shared_ptr<Graph> m_graph;
std::vector<Id> m_activeTokenIds;
std::list<std::shared_ptr<GraphNode> > m_nodes;
std::list<std::weak_ptr<GraphEdge> > m_edges;
};