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 "vtkAbstractWidget.h"
70 
72 
73 
75 {
76 public:
78 
80  void PrintSelf(ostream& os, vtkIndent indent);
82 
84 
87  void SetRepresentation(vtkContinuousValueWidgetRepresentation *r)
88  {this->Superclass::SetWidgetRepresentation
89  (reinterpret_cast<vtkWidgetRepresentation*>(r));}
91 
93 
95  vtkContinuousValueWidgetRepresentation *GetContinuousValueWidgetRepresentation()
96  {return reinterpret_cast<vtkContinuousValueWidgetRepresentation*>(this->WidgetRep);}
98 
100 
101  double GetValue();
102  void SetValue(double v);
104 
105 protected:
108 
109  // These are the events that are handled
110  static void SelectAction(vtkAbstractWidget*);
111  static void EndSelectAction(vtkAbstractWidget*);
112  static void MoveAction(vtkAbstractWidget*);
113 
114 //BTX - manage the state of the widget
117  {
118  Start=0,
120  Adjusting
121  };
122 //ETX
123 
124  double Value;
125 
126 private:
127  vtkContinuousValueWidget(const vtkContinuousValueWidget&); //Not implemented
128  void operator=(const vtkContinuousValueWidget&); //Not implemented
129 };
130 
131 #endif