Files
Sourcetrail/src/lib/component/view/GraphView.h
T
Eberhard Graether 52b0cd2017 ui: redesigned graph overview and use new list layouting within overview bundles
* overview bundles imitate style of bundled node type
* removed bundle for built-in types
* show contents of overview bundle in vertical list layouted with new ListLayouter
* nodes starting with the same letter are grouped with the letter displayed above
* pressing the letter key will scroll to the group
* also use this list layouting for namespace & package contents
* renamed BucketGrid to BucketLayouter
* moved used functions of GraphPostProcessor to GraphViewStyle and removed GraphPostProcessor

fortune cookie message = Don't be afraid to take that big step
2017-02-02 13:29:40 +01:00

48 lines
954 B
C++

#ifndef GRAPH_VIEW_H
#define GRAPH_VIEW_H
#include <vector>
#include "utility/math/Vector2.h"
#include "utility/types.h"
#include "component/view/View.h"
struct DummyEdge;
struct DummyNode;
class Graph;
class GraphView
: public View
{
public:
struct GraphParams
{
bool animatedTransition;
bool centerActiveNode;
bool scrollToTop;
bool isIndexedList;
};
GraphView(ViewLayout* viewLayout);
virtual ~GraphView();
virtual std::string getName() const;
virtual void rebuildGraph(
std::shared_ptr<Graph> graph,
const std::vector<std::shared_ptr<DummyNode>>& nodes,
const std::vector<std::shared_ptr<DummyEdge>>& edges,
const GraphParams params) = 0;
virtual void clear() = 0;
virtual void focusTokenIds(const std::vector<Id>& focusedTokenIds) = 0;
virtual void defocusTokenIds(const std::vector<Id>& defocusedTokenIds) = 0;
virtual void resizeView() = 0;
virtual Vec2i getViewSize() const = 0;
};
#endif // GRAPH_VIEW_H