VTK  9.0.1
vtkParallelopipedWidget.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkParallelopipedWidget.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 =========================================================================*/
41 #ifndef vtkParallelopipedWidget_h
42 #define vtkParallelopipedWidget_h
43 
44 #include "vtkAbstractWidget.h"
45 #include "vtkInteractionWidgetsModule.h" // For export macro
46 
48 class vtkHandleWidget;
49 class vtkWidgetSet;
50 
51 class VTKINTERACTIONWIDGETS_EXPORT vtkParallelopipedWidget : public vtkAbstractWidget
52 {
53 
54  friend class vtkWidgetSet;
55 
56 public:
61 
63  void PrintSelf(ostream& os, vtkIndent indent) override;
64 
70  void SetEnabled(int) override;
71 
78  {
79  this->Superclass::SetWidgetRepresentation(reinterpret_cast<vtkWidgetRepresentation*>(r));
80  }
81 
86  {
87  return reinterpret_cast<vtkParallelopipedRepresentation*>(this->WidgetRep);
88  }
89 
91 
95  vtkSetMacro(EnableChairCreation, vtkTypeBool);
96  vtkGetMacro(EnableChairCreation, vtkTypeBool);
97  vtkBooleanMacro(EnableChairCreation, vtkTypeBool);
99 
104 
110 
111 protected:
114 
121 
122  // Control whether chairs can be created
124 
129 
130  // helper methods for cursor management
131  void SetCursor(int state) override;
132 
133  // To break reference count loops
134  void ReportReferences(vtkGarbageCollector* collector) override;
135 
136  // The positioning handle widgets
138 
143  {
144  RequestResizeEvent = 10000,
146  RequestChairModeEvent
147  };
148 
150 
151 private:
153  void operator=(const vtkParallelopipedWidget&) = delete;
154 };
155 
156 #endif
vtkParallelopipedWidget::ReportReferences
void ReportReferences(vtkGarbageCollector *collector) override
vtkParallelopipedWidget::RequestResizeCallback
static void RequestResizeCallback(vtkAbstractWidget *)
vtkParallelopipedWidget::New
static vtkParallelopipedWidget * New()
Instantiate the object.
vtkParallelopipedWidget::BeginTranslateAction
void BeginTranslateAction(vtkParallelopipedWidget *dispatcher)
vtkHandleWidget
a general widget for moving handles
Definition: vtkHandleWidget.h:73
vtkParallelopipedWidget::RequestResizeAlongAnAxisCallback
static void RequestResizeAlongAnAxisCallback(vtkAbstractWidget *)
vtkParallelopipedWidget::SetProcessEvents
void SetProcessEvents(vtkTypeBool) override
Methods to change the whether the widget responds to interaction.
vtkParallelopipedWidget::SetEnabled
void SetEnabled(int) override
Override the superclass method.
vtkAbstractWidget.h
vtkParallelopipedWidget::SetCursor
void SetCursor(int state) override
vtkWidgetRepresentation
abstract class defines interface between the widget and widget representation classes
Definition: vtkWidgetRepresentation.h:60
vtkParallelopipedWidget::CreateDefaultRepresentation
void CreateDefaultRepresentation() override
Create the default widget representation if one is not set.
vtkAbstractWidget::WidgetRep
vtkWidgetRepresentation * WidgetRep
Definition: vtkAbstractWidget.h:172
vtkParallelopipedWidget::WidgetEventIds
WidgetEventIds
Events invoked by this widget.
Definition: vtkParallelopipedWidget.h:143
vtkParallelopipedWidget::vtkParallelopipedWidget
vtkParallelopipedWidget()
vtkParallelopipedWidget::TranslateCallback
static void TranslateCallback(vtkAbstractWidget *)
vtkAbstractWidget
define the API for widget / widget representation
Definition: vtkAbstractWidget.h:63
vtkParallelopipedWidget
a widget to manipulate 3D parallelopipeds
Definition: vtkParallelopipedWidget.h:52
vtkParallelopipedWidget::RequestChairModeCallback
static void RequestChairModeCallback(vtkAbstractWidget *)
vtkWidgetSet
Synchronize a collection on vtkWidgets drawn on different renderwindows using the Callback - Dispatch...
Definition: vtkWidgetSet.h:114
vtkParallelopipedWidget::OnMouseMoveCallback
static void OnMouseMoveCallback(vtkAbstractWidget *)
vtkParallelopipedWidget::GetParallelopipedRepresentation
vtkParallelopipedRepresentation * GetParallelopipedRepresentation()
Return the representation as a vtkParallelopipedRepresentation.
Definition: vtkParallelopipedWidget.h:85
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:34
vtkParallelopipedWidget::EnableChairCreation
vtkTypeBool EnableChairCreation
Definition: vtkParallelopipedWidget.h:123
vtkGarbageCollector
Detect and break reference loops.
Definition: vtkGarbageCollector.h:95
vtkParallelopipedWidget::HandleWidgets
vtkHandleWidget ** HandleWidgets
Definition: vtkParallelopipedWidget.h:137
vtkParallelopipedWidget::SetRepresentation
void SetRepresentation(vtkParallelopipedRepresentation *r)
Specify an instance of vtkWidgetRepresentation used to represent this widget in the scene.
Definition: vtkParallelopipedWidget.h:77
vtkParallelopipedWidget::RequestResizeAlongAnAxisEvent
@ RequestResizeAlongAnAxisEvent
Definition: vtkParallelopipedWidget.h:145
vtkParallelopipedWidget::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkParallelopipedWidget::~vtkParallelopipedWidget
~vtkParallelopipedWidget() override
vtkParallelopipedWidget::TranslateAction
void TranslateAction(vtkParallelopipedWidget *dispatcher)
vtkParallelopipedRepresentation
Default representation for vtkParallelopipedWidget.
Definition: vtkParallelopipedRepresentation.h:51
vtkParallelopipedWidget::WidgetSet
vtkWidgetSet * WidgetSet
Definition: vtkParallelopipedWidget.h:149
vtkParallelopipedWidget::OnLeftButtonUpCallback
static void OnLeftButtonUpCallback(vtkAbstractWidget *)
vtkTypeBool
int vtkTypeBool
Definition: vtkABI.h:69