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 =========================================================================*/
39 #ifndef vtkPolyLineWidget_h
40 #define vtkPolyLineWidget_h
41 
42 #include "vtkInteractionWidgetsModule.h" // For export macro
43 #include "vtkAbstractWidget.h"
44 
46 
47 class VTKINTERACTIONWIDGETS_EXPORT vtkPolyLineWidget : public vtkAbstractWidget
48 {
49 public:
50  static vtkPolyLineWidget* New();
52  void PrintSelf(ostream& os, vtkIndent indent) override;
53 
60  {
61  this->Superclass::SetWidgetRepresentation(
62  reinterpret_cast<vtkWidgetRepresentation*>(r));
63  }
64 
69  void CreateDefaultRepresentation() override;
70 
71 protected:
73  ~vtkPolyLineWidget() override;
74 
76  enum _WidgetState {Start=0,Active};
77 
78  // These methods handle events
79  static void SelectAction(vtkAbstractWidget*);
80  static void EndSelectAction(vtkAbstractWidget*);
81  static void TranslateAction(vtkAbstractWidget*);
82  static void ScaleAction(vtkAbstractWidget*);
83  static void MoveAction(vtkAbstractWidget*);
84 
85 private:
86  vtkPolyLineWidget(const vtkPolyLineWidget&) = delete;
87  void operator=(const vtkPolyLineWidget&) = delete;
88 
89 };
90 
91 #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:39
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...