• Main Page
  • Related Pages
  • Namespaces
  • Classes
  • Files
  • File List
  • File Members

dox/Widgets/vtkLineWidget2.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    $RCSfile: vtkLineWidget2.h,v $
00005 
00006   Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
00007   All rights reserved.
00008   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
00009 
00010      This software is distributed WITHOUT ANY WARRANTY; without even
00011      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00012      PURPOSE.  See the above copyright notice for more information.
00013 
00014 =========================================================================*/
00090 #ifndef __vtkLineWidget2_h
00091 #define __vtkLineWidget2_h
00092 
00093 #include "vtkAbstractWidget.h"
00094 
00095 class vtkLineRepresentation;
00096 class vtkHandleWidget;
00097 
00098 
00099 class VTK_WIDGETS_EXPORT vtkLineWidget2 : public vtkAbstractWidget
00100 {
00101 public:
00103   static vtkLineWidget2 *New();
00104 
00106 
00107   vtkTypeRevisionMacro(vtkLineWidget2,vtkAbstractWidget);
00108   void PrintSelf(ostream& os, vtkIndent indent);
00110 
00113   virtual void SetEnabled(int enabling);
00114 
00116 
00119   void SetRepresentation(vtkLineRepresentation *r)
00120     {this->Superclass::SetWidgetRepresentation(reinterpret_cast<vtkWidgetRepresentation*>(r));}
00122   
00124   void CreateDefaultRepresentation();
00125 
00128   virtual void SetProcessEvents(int);
00129 
00130 protected:
00131   vtkLineWidget2();
00132   ~vtkLineWidget2();
00133 
00134 //BTX - manage the state of the widget
00135   int WidgetState;
00136   enum _WidgetState {Start=0,Active};
00137 //ETX
00138   int CurrentHandle;
00139     
00140   // These methods handle events
00141   static void SelectAction(vtkAbstractWidget*);
00142   static void TranslateAction(vtkAbstractWidget*);
00143   static void ScaleAction(vtkAbstractWidget*);
00144   static void EndSelectAction(vtkAbstractWidget*);
00145   static void MoveAction(vtkAbstractWidget*);
00146 
00147   // The positioning handle widgets
00148   vtkHandleWidget *Point1Widget; //first end point
00149   vtkHandleWidget *Point2Widget; //second end point
00150   vtkHandleWidget *LineHandle; //used when selecting the line
00151 
00152 private:
00153   vtkLineWidget2(const vtkLineWidget2&);  //Not implemented
00154   void operator=(const vtkLineWidget2&);  //Not implemented
00155 };
00156 
00157 #endif

Generated by  doxygen 1.7.1