VTK
dox/Views/vtkInteractorStyleAreaSelectHover.h
Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    vtkInteractorStyleAreaSelectHover.h
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 =========================================================================*/
00015 /*-------------------------------------------------------------------------
00016   Copyright 2008 Sandia Corporation.
00017   Under the terms of Contract DE-AC04-94AL85000 with Sandia Corporation,
00018   the U.S. Government retains certain rights in this software.
00019 -------------------------------------------------------------------------*/
00036 #ifndef __vtkInteractorStyleAreaSelectHover_h
00037 #define __vtkInteractorStyleAreaSelectHover_h
00038 
00039 #include "vtkInteractorStyleRubberBand2D.h"
00040 
00041 class vtkAreaLayout;
00042 class vtkBalloonRepresentation;
00043 class vtkPoints;
00044 class vtkRenderer;
00045 class vtkTree;
00046 class vtkWorldPointPicker;
00047 class vtkPolyData;
00048 
00049 class VTK_VIEWS_EXPORT vtkInteractorStyleAreaSelectHover : public vtkInteractorStyleRubberBand2D
00050 {
00051 public:
00052   static vtkInteractorStyleAreaSelectHover* New();
00053   vtkTypeMacro(vtkInteractorStyleAreaSelectHover,vtkInteractorStyleRubberBand2D);
00054   void PrintSelf(ostream& os, vtkIndent indent);
00055 
00057 
00059   void SetLayout(vtkAreaLayout* layout);
00060   vtkGetObjectMacro(Layout, vtkAreaLayout);
00062 
00064 
00066   vtkSetStringMacro(LabelField);
00067   vtkGetStringMacro(LabelField);
00069 
00071 
00073   vtkSetMacro(UseRectangularCoordinates, bool);
00074   vtkGetMacro(UseRectangularCoordinates, bool);
00075   vtkBooleanMacro(UseRectangularCoordinates, bool);
00077 
00080   void OnMouseMove();
00081 
00083   virtual void SetInteractor(vtkRenderWindowInteractor *rwi);
00084 
00086   void SetHighLightColor(double r, double g, double b);
00087 
00089 
00090   void SetHighLightWidth(double lw);
00091   double GetHighLightWidth();
00093 
00095   vtkIdType GetIdAtPos(int x, int y);
00096 
00097 protected:
00098   vtkInteractorStyleAreaSelectHover();
00099   ~vtkInteractorStyleAreaSelectHover();
00100 
00101 private:
00102   vtkInteractorStyleAreaSelectHover(const vtkInteractorStyleAreaSelectHover&); // Not implemented
00103   void operator=(const vtkInteractorStyleAreaSelectHover&); // Not implemented
00104 
00105   // These methods are used internally
00106   void GetBoundingAreaForItem(vtkIdType id, float *sinfo);
00107 
00108   vtkWorldPointPicker* Picker;
00109   vtkBalloonRepresentation* Balloon;
00110   vtkPolyData *HighlightData;
00111   vtkActor *HighlightActor;
00112   vtkAreaLayout* Layout;
00113   char *LabelField;
00114   bool UseRectangularCoordinates;
00115 };
00116 
00117 #endif