VTK  9.3.20240328
vtkInteractorStyleAreaSelectHover.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-FileCopyrightText: Copyright 2008 Sandia Corporation
3 // SPDX-License-Identifier: LicenseRef-BSD-3-Clause-Sandia-USGov
21 #ifndef vtkInteractorStyleAreaSelectHover_h
22 #define vtkInteractorStyleAreaSelectHover_h
23 
25 #include "vtkViewsInfovisModule.h" // For export macro
26 
27 VTK_ABI_NAMESPACE_BEGIN
28 class vtkAreaLayout;
30 class vtkPoints;
31 class vtkRenderer;
32 class vtkTree;
34 class vtkPolyData;
35 
36 class VTKVIEWSINFOVIS_EXPORT vtkInteractorStyleAreaSelectHover
38 {
39 public:
42  void PrintSelf(ostream& os, vtkIndent indent) override;
43 
45 
49  void SetLayout(vtkAreaLayout* layout);
50  vtkGetObjectMacro(Layout, vtkAreaLayout);
52 
54 
57  vtkSetStringMacro(LabelField);
58  vtkGetStringMacro(LabelField);
60 
62 
66  vtkSetMacro(UseRectangularCoordinates, bool);
67  vtkGetMacro(UseRectangularCoordinates, bool);
68  vtkBooleanMacro(UseRectangularCoordinates, bool);
70 
75  void OnMouseMove() override;
76 
81 
85  void SetHighLightColor(double r, double g, double b);
86 
88 
91  void SetHighLightWidth(double lw);
94 
98  vtkIdType GetIdAtPos(int x, int y);
99 
100 protected:
103 
104 private:
106  void operator=(const vtkInteractorStyleAreaSelectHover&) = delete;
107 
108  // These methods are used internally
109  void GetBoundingAreaForItem(vtkIdType id, float* sinfo);
110 
111  vtkWorldPointPicker* Picker;
112  vtkBalloonRepresentation* Balloon;
113  vtkPolyData* HighlightData;
114  vtkActor* HighlightActor;
115  vtkAreaLayout* Layout;
116  char* LabelField;
117  bool UseRectangularCoordinates;
118 };
119 
120 VTK_ABI_NAMESPACE_END
121 #endif
represents an object (geometry & properties) in a rendered scene
Definition: vtkActor.h:150
layout a vtkTree into a tree map
Definition: vtkAreaLayout.h:32
represent the vtkBalloonWidget
a simple class to control print indentation
Definition: vtkIndent.h:108
An interactor style for an area tree view.
void OnMouseMove() override
Overridden from vtkInteractorStyleImage to provide the desired interaction behavior.
void SetHighLightWidth(double lw)
The width of the line around the hovered vertex.
vtkIdType GetIdAtPos(int x, int y)
Obtain the tree vertex id at the position specified.
double GetHighLightWidth()
The width of the line around the hovered vertex.
static vtkInteractorStyleAreaSelectHover * New()
void SetInteractor(vtkRenderWindowInteractor *rwi) override
Set the interactor that this interactor style works with.
void SetHighLightColor(double r, double g, double b)
Set the color used to highlight the hovered vertex.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void SetLayout(vtkAreaLayout *layout)
Must be set to the vtkAreaLayout used to compute the bounds of each vertex.
A rubber band interactor for a 2D view.
represent and manipulate 3D points
Definition: vtkPoints.h:138
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:180
platform-independent render window interaction including picking and frame rate control.
abstract specification for renderers
Definition: vtkRenderer.h:171
A rooted tree data structure.
Definition: vtkTree.h:145
find world x,y,z corresponding to display x,y,z
int vtkIdType
Definition: vtkType.h:315