VTK
9.1.0
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
Interaction
Widgets
vtkHoverWidget.h
Go to the documentation of this file.
1
/*=========================================================================
2
3
Program: Visualization Toolkit
4
Module: vtkHoverWidget.h
5
6
Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7
All rights reserved.
8
See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9
10
This software is distributed WITHOUT ANY WARRANTY; without even
11
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12
PURPOSE. See the above copyright notice for more information.
13
14
=========================================================================*/
95
#ifndef vtkHoverWidget_h
96
#define vtkHoverWidget_h
97
98
#include "
vtkAbstractWidget.h
"
99
#include "vtkInteractionWidgetsModule.h"
// For export macro
100
101
class
VTKINTERACTIONWIDGETS_EXPORT
vtkHoverWidget
:
public
vtkAbstractWidget
102
{
103
public
:
107
static
vtkHoverWidget
*
New
();
108
110
113
vtkTypeMacro(
vtkHoverWidget
,
vtkAbstractWidget
);
114
void
PrintSelf
(ostream& os,
vtkIndent
indent)
override
;
116
118
123
vtkSetClampMacro(TimerDuration,
int
, 1, 100000);
124
vtkGetMacro(TimerDuration,
int
);
126
131
void
SetEnabled
(
int
)
override
;
132
138
void
CreateDefaultRepresentation
()
override
{ this->WidgetRep =
nullptr
; }
139
140
protected
:
141
vtkHoverWidget
();
142
~vtkHoverWidget
()
override
;
143
144
// The state of the widget
145
146
enum
147
{
148
Start = 0,
149
Timing
,
150
TimedOut
151
};
152
153
int
WidgetState
;
154
155
// Callback interface to execute events
156
static
void
MoveAction
(
vtkAbstractWidget
*);
157
static
void
HoverAction
(
vtkAbstractWidget
*);
158
static
void
SelectAction
(
vtkAbstractWidget
*);
159
160
// Subclasses of this class invoke these methods. If a non-zero
161
// value is returned, a subclass is handling the event.
162
virtual
int
SubclassHoverAction
() {
return
0; }
163
virtual
int
SubclassEndHoverAction
() {
return
0; }
164
virtual
int
SubclassSelectAction
() {
return
0; }
165
167
170
int
TimerId
;
171
int
TimerDuration
;
173
174
private
:
175
vtkHoverWidget
(
const
vtkHoverWidget
&) =
delete
;
176
void
operator=(
const
vtkHoverWidget
&) =
delete
;
177
};
178
179
#endif
vtkAbstractWidget
define the API for widget / widget representation
Definition:
vtkAbstractWidget.h:66
vtkHoverWidget
invoke a vtkTimerEvent when hovering
Definition:
vtkHoverWidget.h:102
vtkHoverWidget::SubclassSelectAction
virtual int SubclassSelectAction()
Definition:
vtkHoverWidget.h:164
vtkHoverWidget::vtkHoverWidget
vtkHoverWidget()
vtkHoverWidget::TimerId
int TimerId
Helper methods for creating and destroying timers.
Definition:
vtkHoverWidget.h:170
vtkHoverWidget::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Standard methods for a VTK class.
vtkHoverWidget::New
static vtkHoverWidget * New()
Instantiate this class.
vtkHoverWidget::WidgetState
int WidgetState
Definition:
vtkHoverWidget.h:153
vtkHoverWidget::CreateDefaultRepresentation
void CreateDefaultRepresentation() override
A default representation, of which there is none, is created.
Definition:
vtkHoverWidget.h:138
vtkHoverWidget::HoverAction
static void HoverAction(vtkAbstractWidget *)
vtkHoverWidget::TimerDuration
int TimerDuration
Helper methods for creating and destroying timers.
Definition:
vtkHoverWidget.h:171
vtkHoverWidget::~vtkHoverWidget
~vtkHoverWidget() override
vtkHoverWidget::Timing
@ Timing
Definition:
vtkHoverWidget.h:149
vtkHoverWidget::MoveAction
static void MoveAction(vtkAbstractWidget *)
vtkHoverWidget::SelectAction
static void SelectAction(vtkAbstractWidget *)
vtkHoverWidget::SetEnabled
void SetEnabled(int) override
The method for activating and deactivating this widget.
vtkHoverWidget::SubclassEndHoverAction
virtual int SubclassEndHoverAction()
Definition:
vtkHoverWidget.h:163
vtkHoverWidget::SubclassHoverAction
virtual int SubclassHoverAction()
Definition:
vtkHoverWidget.h:162
vtkIndent
a simple class to control print indentation
Definition:
vtkIndent.h:113
vtkAbstractWidget.h
Generated on Fri Apr 21 2023 10:28:52 for VTK by
1.9.6