33 #ifndef __vtkMultiLineItem_h
34 #define __vtkMultiLineItem_h
36 #include "vtkViewsInfovisModule.h"
37 #include "vtkContextItem.h"
39 #include "vtkVector.h"
46 class vtkRenderWindowInteractor;
54 virtual void PrintSelf(ostream &os, vtkIndent indent);
58 virtual void SetGraph(vtkGraph *graph);
59 vtkGetObjectMacro(Graph, vtkGraph);
67 virtual void StartLayoutAnimation(vtkRenderWindowInteractor *interactor);
68 virtual void StopLayoutAnimation();
72 virtual void UpdateLayout();
80 virtual bool Paint(vtkContext2D *painter);
85 virtual void RebuildBuffers();
89 virtual void PaintBuffers(vtkContext2D *painter);
97 virtual bool IsDirty();
102 virtual vtkIdType NumberOfVertices();
106 virtual vtkIdType NumberOfEdges();
112 virtual vtkIdType NumberOfEdgePoints(vtkIdType edge);
117 virtual float EdgeWidth(vtkIdType edge, vtkIdType point);
122 virtual vtkColor4ub EdgeColor(vtkIdType edge, vtkIdType point);
128 virtual vtkVector2f EdgePosition(vtkIdType edge, vtkIdType point);
134 virtual float VertexSize(vtkIdType vertex);
138 virtual vtkColor4ub VertexColor(vtkIdType vertex);
144 virtual int VertexMarker(vtkIdType vertex);
150 virtual vtkVector2f VertexPosition(vtkIdType vertex);
154 virtual vtkStdString VertexTooltip(vtkIdType vertex);
158 static void ProcessEvents(vtkObject *caller,
unsigned long event,
159 void *clientData,
void *callerData);
163 virtual vtkIdType HitVertex(
const vtkVector2f &pos);
167 virtual bool MouseMoveEvent(
const vtkContextMouseEvent &event);
168 virtual bool MouseLeaveEvent(
const vtkContextMouseEvent &event);
169 virtual bool MouseEnterEvent(
const vtkContextMouseEvent &event);
170 virtual bool MouseButtonPressEvent(
const vtkContextMouseEvent &event);
171 virtual bool MouseButtonReleaseEvent(
const vtkContextMouseEvent &event);
172 virtual bool MouseWheelEvent(
const vtkContextMouseEvent &event,
int delta);
176 virtual bool Hit(
const vtkContextMouseEvent &event);
179 virtual void PlaceTooltip(vtkIdType v);
189 unsigned long GraphBuildTime;
190 vtkNew<vtkImageData> Sprite;
191 vtkNew<vtkIncrementalForceLayout> Layout;
192 vtkNew<vtkTooltipItem> Tooltip;
A 2D graphics item for rendering a graph.
incremental force-directed layout.