Slicer  5.0
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
qMRMLTransformInfoWidget.h
Go to the documentation of this file.
1 /*==============================================================================
2 
3  Program: 3D Slicer
4 
5  Portions (c) Copyright Brigham and Women's Hospital (BWH) All Rights Reserved.
6 
7  See COPYRIGHT.txt
8  or http://www.slicer.org/copyright/copyright.txt for details.
9 
10  Unless required by applicable law or agreed to in writing, software
11  distributed under the License is distributed on an "AS IS" BASIS,
12  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  See the License for the specific language governing permissions and
14  limitations under the License.
15 
16  This file was originally developed by Andras Lasso and Franklin King at
17  PerkLab, Queen's University and was supported through the Applied Cancer
18  Research Unit program of Cancer Care Ontario with funds provided by the
19  Ontario Ministry of Health and Long-Term Care.
20 
21 ==============================================================================*/
22 
23 
24 #ifndef __qMRMLTransformInfoWidget_h
25 #define __qMRMLTransformInfoWidget_h
26 
27 // CTK includes
28 #include <ctkPimpl.h>
29 #include <ctkVTKObject.h>
30 
31 // Slicer includes
32 #include "qMRMLWidget.h"
33 
34 #include "qSlicerTransformsModuleWidgetsExport.h"
35 
36 class qMRMLTransformInfoWidgetPrivate;
38 class vtkMRMLNode;
39 
41 class Q_SLICER_MODULE_TRANSFORMS_WIDGETS_EXPORT
43  : public qMRMLWidget
44 {
45  Q_OBJECT
46  QVTK_OBJECT
47 
48 public:
50  qMRMLTransformInfoWidget(QWidget *parent=nullptr);
51  ~qMRMLTransformInfoWidget() override;
52 
53  vtkMRMLTransformNode* mrmlTransformNode()const;
54 
55  vtkMRMLScene* mrmlScene()const;
56 
57 public slots:
58 
61  void setMRMLTransformNode(vtkMRMLTransformNode* transformNode);
62 
63  void setMRMLScene(vtkMRMLScene* scene) override;
64 
67  void setMRMLTransformNode(vtkMRMLNode* node);
68 
70  void processEvent(vtkObject* sender, void* callData, unsigned long eventId, void* clientData);
71 
72 protected slots:
73  void updateWidgetFromMRML();
74  void updateTransformVectorDisplayFromMRML();
75 
76 protected:
77 
78  void showEvent(QShowEvent *) override;
79 
80  QScopedPointer<qMRMLTransformInfoWidgetPrivate> d_ptr;
81 
82 private:
83  Q_DECLARE_PRIVATE(qMRMLTransformInfoWidget);
84  Q_DISABLE_COPY(qMRMLTransformInfoWidget);
85 };
86 
87 #endif
MRML node for representing a transformation between this node space and a parent node space...
QScopedPointer< qMRMLTransformInfoWidgetPrivate > d_ptr
A set of MRML Nodes that supports serialization and undo/redo.
Definition: vtkMRMLScene.h:57
Q_INVOKABLE vtkMRMLScene * mrmlScene() const
Return a pointer on the current MRML scene.
Base class for any widget that requires a MRML Scene.
Definition: qMRMLWidget.h:35
virtual void setMRMLScene(vtkMRMLScene *newScene)
Set the MRML scene associated with the widget.
Abstract Superclass for all specific types of MRML nodes.
Definition: vtkMRMLNode.h:167