VTK
vtkContinuousValueWidget.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkContinuousValueWidget.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 =========================================================================*/
15 /*-------------------------------------------------------------------------
16  Copyright 2008 Sandia Corporation.
17  Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
18  the U.S. Government retains certain rights in this software.
19 -------------------------------------------------------------------------*/
20 
66 #ifndef vtkContinuousValueWidget_h
67 #define vtkContinuousValueWidget_h
68 
69 #include "vtkInteractionWidgetsModule.h" // For export macro
70 #include "vtkAbstractWidget.h"
71 
73 
74 
76 {
77 public:
79 
81  void PrintSelf(ostream& os, vtkIndent indent);
83 
85 
89  {this->Superclass::SetWidgetRepresentation
90  (reinterpret_cast<vtkWidgetRepresentation*>(r));}
92 
94 
97  {return reinterpret_cast<vtkContinuousValueWidgetRepresentation*>(this->WidgetRep);}
99 
101 
102  double GetValue();
103  void SetValue(double v);
105 
106 protected:
109 
110  // These are the events that are handled
111  static void SelectAction(vtkAbstractWidget*);
112  static void EndSelectAction(vtkAbstractWidget*);
113  static void MoveAction(vtkAbstractWidget*);
114 
115  // Manage the state of the widget
118  {
119  Start=0,
121  Adjusting
122  };
123 
124  double Value;
125 
126 private:
127  vtkContinuousValueWidget(const vtkContinuousValueWidget&); //Not implemented
128  void operator=(const vtkContinuousValueWidget&); //Not implemented
129 };
130 
131 #endif
void PrintSelf(ostream &os, vtkIndent indent)
void SetRepresentation(vtkContinuousValueWidgetRepresentation *r)
provide the representation for a continuous value
vtkWidgetRepresentation * WidgetRep
#define VTKINTERACTIONWIDGETS_EXPORT
a simple class to control print indentation
Definition: vtkIndent.h:38
define the API for widget / widget representation
set a value by manipulating something
vtkContinuousValueWidgetRepresentation * GetContinuousValueWidgetRepresentation()