VTK  9.3.0
vtkButtonRepresentation.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-License-Identifier: BSD-3-Clause
26#ifndef vtkButtonRepresentation_h
27#define vtkButtonRepresentation_h
28
29#include "vtkDeprecation.h" // For VTK_DEPRECATED_IN_9_2_0
30#include "vtkInteractionWidgetsModule.h" // For export macro
31#include "vtkLegacy.h" // for VTK_LEGACY_REMOVE
33
34VTK_ABI_NAMESPACE_BEGIN
35class VTKINTERACTIONWIDGETS_EXPORT vtkButtonRepresentation : public vtkWidgetRepresentation
36{
37public:
39
43 void PrintSelf(ostream& os, vtkIndent indent) override;
45
47
50 vtkSetClampMacro(NumberOfStates, int, 1, VTK_INT_MAX);
52
54
57 vtkGetMacro(State, int);
59
61
67 virtual void SetState(int state);
68 virtual void NextState();
69 virtual void PreviousState();
71
73 {
74 Outside = 0,
75 Inside
76 };
77#if !defined(VTK_LEGACY_REMOVE)
78 VTK_DEPRECATED_IN_9_2_0("because leading underscore is reserved")
80#endif
81
83
92 {
95 HighlightSelecting
96 };
97#if !defined(VTK_LEGACY_REMOVE)
98 VTK_DEPRECATED_IN_9_2_0("because leading underscore is reserved")
100#endif
101 void Highlight(int) override;
102 vtkGetMacro(HighlightState, int);
104
108 void ShallowCopy(vtkProp* prop) override;
109
110protected:
113
114 // Values
116 int State;
118
119private:
121 void operator=(const vtkButtonRepresentation&) = delete;
122};
123
124VTK_ABI_NAMESPACE_END
125#endif
abstract class defines the representation for a vtkButtonWidget
void Highlight(int) override
These methods control the appearance of the button as it is being interacted with.
void ShallowCopy(vtkProp *prop) override
Satisfy some of vtkProp's API.
virtual void SetState(int state)
Manipulate the state.
HighlightStateType
These methods control the appearance of the button as it is being interacted with.
~vtkButtonRepresentation() override
void PrintSelf(ostream &os, vtkIndent indent) override
Standard methods for the class.
virtual void NextState()
Manipulate the state.
virtual void PreviousState()
Manipulate the state.
a simple class to control print indentation
Definition vtkIndent.h:29
abstract superclass for all actors, volumes and annotations
Definition vtkProp.h:43
abstract class defines interface between the widget and widget representation classes
#define VTK_DEPRECATED_IN_9_2_0(reason)
#define VTK_INT_MAX
Definition vtkType.h:144