VTK  9.4.20241031
vtkImplicitConeWidget.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
3
102#ifndef vtkImplicitConeWidget_h
103#define vtkImplicitConeWidget_h
104
105#include "vtkAbstractWidget.h"
106#include "vtkInteractionWidgetsModule.h" // For export macro
107#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
108
109VTK_ABI_NAMESPACE_BEGIN
111
112class VTKINTERACTIONWIDGETS_EXPORT VTK_MARSHALAUTO vtkImplicitConeWidget : public vtkAbstractWidget
113{
114public:
117
124
129 {
130 return reinterpret_cast<vtkImplicitConeRepresentation*>(this->WidgetRep);
131 }
132
137
138private:
140 ~vtkImplicitConeWidget() override = default;
141
142 enum WidgetStateType
143 {
144 Idle = 0,
145 Active
146 };
147
148 // Manage the state of the widget
149 WidgetStateType WidgetState = vtkImplicitConeWidget::Idle;
150
151 // These methods handle events
152 static void SelectAction(vtkAbstractWidget* widget);
153 static void TranslateAction(vtkAbstractWidget* widget);
154 static void ScaleAction(vtkAbstractWidget* widget);
155 static void EndSelectAction(vtkAbstractWidget* widget);
156 static void MoveAction(vtkAbstractWidget* widget);
157 static void MoveConeAction(vtkAbstractWidget* widget);
158 static void TranslationAxisLock(vtkAbstractWidget* widget);
159 static void TranslationAxisUnLock(vtkAbstractWidget* widget);
160
165 bool UpdateCursorShape(int interactionState);
166
168 void operator=(const vtkImplicitConeWidget&) = delete;
169};
170
171VTK_ABI_NAMESPACE_END
172#endif
define the API for widget / widget representation
vtkWidgetRepresentation * WidgetRep
defining the representation for a vtkImplicitConeWidget
3D widget for manipulating an infinite cone
void CreateDefaultRepresentation() override
Create the default widget representation if one is not set.
void SetRepresentation(vtkImplicitConeRepresentation *rep)
Specify an instance of vtkWidgetRepresentation used to represent this widget in the scene.
vtkImplicitConeRepresentation * GetConeRepresentation()
Return the representation as a vtkImplicitConeRepresentation.
static vtkImplicitConeWidget * New()
#define VTK_MARSHALAUTO