Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

GUI/Client/vtkPVOrientScaleWidget.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   ParaView
00004   Module:    $RCSfile: vtkPVOrientScaleWidget.h,v $
00005 
00006   Copyright (c) Kitware, Inc.
00007   All rights reserved.
00008   See Copyright.txt or http://www.paraview.org/HTML/Copyright.html 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 =========================================================================*/
00023 #ifndef __vtkPVOrientScaleWidget_h
00024 #define __vtkPVOrientScaleWidget_h
00025 
00026 #include "vtkPVWidget.h"
00027 
00028 class vtkKWEntry;
00029 class vtkKWLabel;
00030 class vtkKWFrameWithLabel;
00031 class vtkKWMenuButton;
00032 class vtkPVDataSetAttributesInformation;
00033 class vtkSMProperty;
00034 class vtkKWFrame;
00035 
00036 class VTK_EXPORT vtkPVOrientScaleWidget : public vtkPVWidget
00037 {
00038 public:
00039   static vtkPVOrientScaleWidget* New();
00040   vtkTypeRevisionMacro(vtkPVOrientScaleWidget, vtkPVWidget);
00041   void PrintSelf(ostream &os, vtkIndent indent);
00042   
00044   virtual void Create(vtkKWApplication *app);
00045 
00046   //BTX
00048 
00049   virtual void Accept();
00050   virtual void ResetInternal();
00051   virtual void Initialize();
00052   //ETX
00054 
00057   virtual void Trace(ofstream *file);
00058 
00061   void UpdateActiveState();
00062 
00064 
00065   void ScaleModeMenuCallback();
00066   void OrientModeMenuCallback();
00067   void ScalarsMenuEntryCallback();
00068   void VectorsMenuEntryCallback();
00070   
00072   virtual void Update();
00073  
00075 
00076   void SetOrientMode(char *mode);
00077   void SetScaleMode(char *mode);
00078   void SetScalars(char *scalars);
00079   void SetVectors(char *vectors);
00080   void SetScaleFactor(float factor);
00082   
00089   virtual void UpdateEnableState();
00090  
00092   virtual void SaveInBatchScript(ofstream *file);
00093 
00094 protected:
00095   vtkPVOrientScaleWidget();
00096   ~vtkPVOrientScaleWidget();
00097 
00098   vtkKWFrameWithLabel *LabeledFrame;
00099   vtkKWFrame *ScalarsFrame;
00100   vtkKWLabel *ScalarsLabel;
00101   vtkKWMenuButton *ScalarsMenu;
00102   vtkKWFrame *VectorsFrame;
00103   vtkKWLabel *VectorsLabel;
00104   vtkKWMenuButton *VectorsMenu;
00105   vtkKWFrame *OrientModeFrame;
00106   vtkKWLabel *OrientModeLabel;
00107   vtkKWMenuButton *OrientModeMenu;
00108   vtkKWFrame *ScaleModeFrame;
00109   vtkKWLabel *ScaleModeLabel;
00110   vtkKWMenuButton *ScaleModeMenu;
00111   vtkKWFrame *ScaleFactorFrame;
00112   vtkKWLabel *ScaleFactorLabel;
00113   vtkKWEntry *ScaleFactorEntry;
00114 
00115   char *ScalarArrayName;
00116   char *VectorArrayName;
00117   vtkSetStringMacro(ScalarArrayName);
00118   vtkSetStringMacro(VectorArrayName);
00119 
00120   char *SMScalarPropertyName;
00121   char *SMVectorPropertyName;
00122   char *SMOrientModePropertyName;
00123   char *SMScaleModePropertyName;
00124   char *SMScaleFactorPropertyName;
00125 
00126   void SetSMScalarProperty(vtkSMProperty *prop);
00127   vtkSMProperty* GetSMScalarProperty();
00128   void SetSMVectorProperty(vtkSMProperty *prop);
00129   vtkSMProperty* GetSMVectorProperty();
00130   void SetSMOrientModeProperty(vtkSMProperty *prop);
00131   vtkSMProperty* GetSMOrientModeProperty();
00132   void SetSMScaleModeProperty(vtkSMProperty *prop);
00133   vtkSMProperty* GetSMScaleModeProperty();
00134   void SetSMScaleFactorProperty(vtkSMProperty *prop);
00135   vtkSMProperty* GetSMScaleFactorProperty();
00136 
00137   vtkSetStringMacro(SMScalarPropertyName);
00138   vtkGetStringMacro(SMScalarPropertyName);
00139   vtkSetStringMacro(SMVectorPropertyName);
00140   vtkGetStringMacro(SMVectorPropertyName);
00141   vtkSetStringMacro(SMOrientModePropertyName);
00142   vtkGetStringMacro(SMOrientModePropertyName);
00143   vtkSetStringMacro(SMScaleModePropertyName);
00144   vtkGetStringMacro(SMScaleModePropertyName);
00145   vtkSetStringMacro(SMScaleFactorPropertyName);
00146   vtkGetStringMacro(SMScaleFactorPropertyName);
00147 
00148   char *CurrentScalars;
00149   char *CurrentVectors;
00150   char *CurrentOrientMode;
00151   char *CurrentScaleMode;
00152   vtkSetStringMacro(CurrentScalars);
00153   vtkSetStringMacro(CurrentVectors);
00154   vtkSetStringMacro(CurrentOrientMode);
00155   vtkSetStringMacro(CurrentScaleMode);
00156   
00157 //BTX
00158   virtual void CopyProperties(vtkPVWidget *clone, vtkPVSource *pvSource,
00159                               vtkArrayMap<vtkPVWidget*, vtkPVWidget*>* map);
00160 //ETX
00161   
00162   int ReadXMLAttributes(vtkPVXMLElement *element,
00163                         vtkPVXMLPackageParser *parser);
00164   
00165   void UpdateArrayMenus();
00166   void UpdateModeMenus();
00167   void UpdateScaleFactor();
00168   
00169 private:
00170   vtkPVOrientScaleWidget(const vtkPVOrientScaleWidget&); // Not implemented
00171   void operator=(const vtkPVOrientScaleWidget&); // Not implemented
00172   
00173   vtkSMProperty *SMScalarProperty;
00174   vtkSMProperty *SMVectorProperty;
00175   vtkSMProperty *SMOrientModeProperty;
00176   vtkSMProperty *SMScaleModeProperty;
00177   vtkSMProperty *SMScaleFactorProperty;
00178 };
00179 
00180 #endif

Generated on Tue May 30 12:31:40 2006 for ParaView by doxygen 1.3.5