VTK  9.0.20201019
vtkAxesTransformWidget.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkAxesTransformWidget.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 =========================================================================*/
87 #ifndef vtkAxesTransformWidget_h
88 #define vtkAxesTransformWidget_h
89 
90 #include "vtkAbstractWidget.h"
91 #include "vtkInteractionWidgetsModule.h" // For export macro
92 
94 class vtkHandleWidget;
95 
96 class VTKINTERACTIONWIDGETS_EXPORT vtkAxesTransformWidget : public vtkAbstractWidget
97 {
98 public:
102  static vtkAxesTransformWidget* New();
103 
105 
109  void PrintSelf(ostream& os, vtkIndent indent) override;
111 
116  void SetEnabled(int enabling) override;
117 
124  {
125  this->Superclass::SetWidgetRepresentation(reinterpret_cast<vtkWidgetRepresentation*>(r));
126  }
127 
132  {
133  return reinterpret_cast<vtkAxesTransformRepresentation*>(this->WidgetRep);
134  }
135 
139  void CreateDefaultRepresentation() override;
140 
145  void SetProcessEvents(vtkTypeBool) override;
146 
147 protected:
149  ~vtkAxesTransformWidget() override;
150 
153  {
154  Start = 0,
155  Active
156  };
158 
159  // These methods handle events
160  static void SelectAction(vtkAbstractWidget*);
161  static void EndSelectAction(vtkAbstractWidget*);
162  static void MoveAction(vtkAbstractWidget*);
163 
164  // The positioning handle widgets
165  vtkHandleWidget* OriginWidget; // first end point
166  vtkHandleWidget* SelectionWidget; // used when selecting any one of the axes
167 
168 private:
170  void operator=(const vtkAxesTransformWidget&) = delete;
171 };
172 
173 #endif
vtkAxesTransformWidget::CurrentHandle
int CurrentHandle
Definition: vtkAxesTransformWidget.h:157
vtkHandleWidget
a general widget for moving handles
Definition: vtkHandleWidget.h:78
vtkAbstractWidget::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkAxesTransformWidget::SetRepresentation
void SetRepresentation(vtkAxesTransformRepresentation *r)
Specify an instance of vtkWidgetRepresentation used to represent this widget in the scene.
Definition: vtkAxesTransformWidget.h:123
vtkAbstractWidget.h
vtkObject::New
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on.
vtkAxesTransformWidget
3D widget for performing 3D transformations around an axes
Definition: vtkAxesTransformWidget.h:96
vtkAbstractWidget
define the API for widget / widget representation
Definition: vtkAbstractWidget.h:65
vtkAxesTransformWidget::GetLineRepresentation
vtkAxesTransformRepresentation * GetLineRepresentation()
Return the representation as a vtkAxesTransformRepresentation.
Definition: vtkAxesTransformWidget.h:131
vtkAbstractWidget::CreateDefaultRepresentation
virtual void CreateDefaultRepresentation()=0
Create the default widget representation if one is not set.
vtkAxesTransformWidget::SelectionWidget
vtkHandleWidget * SelectionWidget
Definition: vtkAxesTransformWidget.h:166
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:33
vtkAxesTransformWidget::_WidgetState
_WidgetState
Definition: vtkAxesTransformWidget.h:152
vtkAbstractWidget::SetEnabled
void SetEnabled(int) override
Methods for activating this widget.
vtkAxesTransformRepresentation
represent the vtkAxesTransformWidget
Definition: vtkAxesTransformRepresentation.h:49
vtkAbstractWidget::SetProcessEvents
virtual void SetProcessEvents(vtkTypeBool)
Methods to change whether the widget responds to interaction.
vtkAxesTransformWidget::WidgetState
int WidgetState
Definition: vtkAxesTransformWidget.h:151
vtkAxesTransformWidget::OriginWidget
vtkHandleWidget * OriginWidget
Definition: vtkAxesTransformWidget.h:165
vtkTypeBool
int vtkTypeBool
Definition: vtkABI.h:69