VTK
vtkPolyLineWidget.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkPolyLineWidget.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 =========================================================================*/
36 #ifndef vtkPolyLineWidget_h
37 #define vtkPolyLineWidget_h
38 
39 #include "vtkInteractionWidgetsModule.h" // For export macro
40 #include "vtkAbstractWidget.h"
41 
43 
44 class VTKINTERACTIONWIDGETS_EXPORT vtkPolyLineWidget : public vtkAbstractWidget
45 {
46 public:
47  static vtkPolyLineWidget* New();
49  void PrintSelf(ostream& os, vtkIndent indent) override;
50 
57  {
58  this->Superclass::SetWidgetRepresentation(
59  reinterpret_cast<vtkWidgetRepresentation*>(r));
60  }
61 
66  void CreateDefaultRepresentation() override;
67 
68 protected:
70  ~vtkPolyLineWidget() override;
71 
73  enum _WidgetState {Start=0,Active};
74 
75  // These methods handle events
76  static void SelectAction(vtkAbstractWidget*);
77  static void EndSelectAction(vtkAbstractWidget*);
78  static void TranslateAction(vtkAbstractWidget*);
79  static void ScaleAction(vtkAbstractWidget*);
80  static void MoveAction(vtkAbstractWidget*);
81 
82 private:
83  vtkPolyLineWidget(const vtkPolyLineWidget&) = delete;
84  void operator=(const vtkPolyLineWidget&) = delete;
85 
86 };
87 
88 #endif
widget for vtkPolyLineRepresentation.
void PrintSelf(ostream &os, vtkIndent indent) override
Standard macros implementing standard VTK methods.
virtual void CreateDefaultRepresentation()=0
Create the default widget representation if one is not set.
vtkWidgetRepresentation for a poly line.
a simple class to control print indentation
Definition: vtkIndent.h:33
define the API for widget / widget representation
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on.
void SetRepresentation(vtkPolyLineRepresentation *r)
Specify an instance of vtkWidgetRepresentation used to represent this widget in the scene.