VTK  9.5.2
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
73
74#ifndef vtkImplicitConeWidget_h
75#define vtkImplicitConeWidget_h
76
77#include "vtkAbstractWidget.h"
78#include "vtkInteractionWidgetsModule.h" // For export macro
79#include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
80
81VTK_ABI_NAMESPACE_BEGIN
83
84class VTKINTERACTIONWIDGETS_EXPORT VTK_MARSHALAUTO vtkImplicitConeWidget : public vtkAbstractWidget
85{
86public:
87 static vtkImplicitConeWidget* New();
88 vtkTypeMacro(vtkImplicitConeWidget, vtkAbstractWidget);
89
96
104
109
110private:
111 vtkImplicitConeWidget();
112 ~vtkImplicitConeWidget() override = default;
113
114 enum WidgetStateType
115 {
116 Idle = 0,
117 Active
118 };
119
120 // Manage the state of the widget
121 WidgetStateType WidgetState = vtkImplicitConeWidget::Idle;
122
123 // These methods handle events
124 static void SelectAction(vtkAbstractWidget* widget);
125 static void TranslateAction(vtkAbstractWidget* widget);
126 static void ScaleAction(vtkAbstractWidget* widget);
127 static void EndSelectAction(vtkAbstractWidget* widget);
128 static void MoveAction(vtkAbstractWidget* widget);
129 static void MoveConeAction(vtkAbstractWidget* widget);
130 static void TranslationAxisLock(vtkAbstractWidget* widget);
131 static void TranslationAxisUnLock(vtkAbstractWidget* widget);
132
137 bool UpdateCursorShape(int interactionState);
138
140 void operator=(const vtkImplicitConeWidget&) = delete;
141};
142
143VTK_ABI_NAMESPACE_END
144#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