VTK  9.2.6
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 =========================================================================*/
42 #ifndef vtkPolyLineWidget_h
43 #define vtkPolyLineWidget_h
44 
45 #include "vtkAbstractWidget.h"
46 #include "vtkDeprecation.h" // For VTK_DEPRECATED_IN_9_2_0
47 #include "vtkInteractionWidgetsModule.h" // For export macro
48 
50 
51 class VTKINTERACTIONWIDGETS_EXPORT vtkPolyLineWidget : public vtkAbstractWidget
52 {
53 public:
54  static vtkPolyLineWidget* New();
56  void PrintSelf(ostream& os, vtkIndent indent) override;
57 
64  {
65  this->Superclass::SetWidgetRepresentation(reinterpret_cast<vtkWidgetRepresentation*>(r));
66  }
67 
72  void CreateDefaultRepresentation() override;
73 
78  void SetEnabled(int enabling) override;
79 
80 protected:
82  ~vtkPolyLineWidget() override;
83 
86  {
87  Start = 0,
88  Active
89  };
90 #if !defined(VTK_LEGACY_REMOVE)
91  VTK_DEPRECATED_IN_9_2_0("because leading underscore is reserved")
93 #endif
94 
95  // These methods handle events
96  static void SelectAction(vtkAbstractWidget*);
97  static void EndSelectAction(vtkAbstractWidget*);
98  static void TranslateAction(vtkAbstractWidget*);
99  static void ScaleAction(vtkAbstractWidget*);
100  static void MoveAction(vtkAbstractWidget*);
101 
103  static void ProcessKeyEvents(vtkObject*, unsigned long, void*, void*);
104 
105 private:
106  vtkPolyLineWidget(const vtkPolyLineWidget&) = delete;
107  void operator=(const vtkPolyLineWidget&) = delete;
108 };
109 
110 #endif
widget for vtkPolyLineRepresentation.
abstract base class for most VTK objects
Definition: vtkObject.h:62
#define VTK_DEPRECATED_IN_9_2_0(reason)
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.
supports function callbacks
a simple class to control print indentation
Definition: vtkIndent.h:39
define the API for widget / widget representation
void SetEnabled(int) override
Methods for activating this widget.
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
vtkCallbackCommand * KeyEventCallbackCommand
void SetRepresentation(vtkPolyLineRepresentation *r)
Specify an instance of vtkWidgetRepresentation used to represent this widget in the scene...