vtkMeasurementsGUI.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006 #ifndef __vtkMeasurementsGUI_h
00007 #define __vtkMeasurementsGUI_h
00008
00009 #include "vtkMeasurementsWin32Header.h"
00010 #include "vtkSlicerModuleGUI.h"
00011 #include "vtkMeasurementsLogic.h"
00012 #include "vtkSlicerModuleCollapsibleFrame.h"
00013 #include <string>
00014
00015 class vtkKWFrame;
00016 class vtkKWCheckButton;
00017 class vtkAffineWidget;
00018 class vtkAffineRepresentation2D;
00019 class vtkSlicerNodeSelectorWidget;
00020 class vtkMeasurementsRulerWidget;
00021 class vtkMeasurementsAngleWidget;
00022 class VTK_MEASUREMENTS_EXPORT vtkMeasurementsGUI : public vtkSlicerModuleGUI
00023 {
00024 public:
00025 static vtkMeasurementsGUI *New();
00026 vtkTypeRevisionMacro(vtkMeasurementsGUI,vtkSlicerModuleGUI);
00027 void PrintSelf(ostream& os, vtkIndent indent);
00028
00033 virtual void SetModuleLogic ( vtkSlicerLogic *logic )
00034 {
00035 this->SetLogic(reinterpret_cast<vtkMeasurementsLogic*> (logic));
00036 };
00037
00039 vtkGetObjectMacro (Logic, vtkMeasurementsLogic);
00040 vtkSetObjectMacro (Logic, vtkMeasurementsLogic);
00041
00044
00045 virtual void BuildGUI ( );
00046
00047 using vtkSlicerComponentGUI::BuildGUI;
00048
00049 virtual void TearDownGUI ( );
00050 vtkIntArray *NewObservableEvents();
00051
00054 virtual void AddGUIObservers ( );
00055
00058 virtual void RemoveGUIObservers ( );
00059
00062 virtual void ProcessGUIEvents ( vtkObject *caller, unsigned long event,
00063 void *callData );
00064
00067 virtual void ProcessMRMLEvents ( vtkObject *caller, unsigned long event, void *callData );
00068
00071 virtual void Enter ( );
00072
00073 using vtkSlicerComponentGUI::Enter;
00074
00075 virtual void Exit ( );
00076 virtual void Init ( );
00077
00080 vtkGetObjectMacro(RulerWidget, vtkMeasurementsRulerWidget);
00081 vtkGetObjectMacro(AngleWidget, vtkMeasurementsAngleWidget);
00082
00085 void UpdateTransformableNode();
00086
00090 void Update3DWidget(vtkMRMLTransformableNode *node);
00091
00094 void SetActiveViewer(vtkSlicerViewerWidget *activeViewer );
00095
00098 void RemoveMRMLObservers ( );
00099
00102 void ModifyAllLock(int lockFlag);
00103
00104 protected:
00105 vtkMeasurementsGUI();
00106 ~vtkMeasurementsGUI();
00107 vtkMeasurementsGUI(const vtkMeasurementsGUI&);
00108 void operator=(const vtkMeasurementsGUI&);
00109
00112 void SetStatusText( const char *txt);
00113 vtkMeasurementsLogic *Logic;
00114
00117 vtkAffineRepresentation2D *TransformRepresentation;
00118 vtkAffineWidget *TransformWidget;
00119
00120
00123 vtkKWCheckButton *TransformCheckButton;
00124 vtkSlicerNodeSelectorWidget* TransformableNodeSelectorWidget;
00125
00128 vtkMeasurementsRulerWidget *RulerWidget;
00129
00132 vtkMeasurementsAngleWidget *AngleWidget;
00133 };
00134
00135 #endif
00136