Fraxinus  22.04
An IGT application
cxMeshInfoWidget.h
Go to the documentation of this file.
1 /*=========================================================================
2 This file is part of CustusX, an Image Guided Therapy Application.
3 
4 Copyright (c) SINTEF Department of Medical Technology.
5 All rights reserved.
6 
7 CustusX is released under a BSD 3-Clause license.
8 
9 See Lisence.txt (https://github.com/SINTEFMedtek/CustusX/blob/master/License.txt) for details.
10 =========================================================================*/
11 #ifndef CXMESHINFOWIDGET_H_
12 #define CXMESHINFOWIDGET_H_
13 
14 #include "cxGuiExport.h"
15 
16 #include <vector>
17 #include <QtWidgets>
18 
19 #include "cxMesh.h"
20 #include "cxDataInterface.h"
21 #include "cxInfoWidget.h"
22 #include "cxTabbedWidget.h"
23 #include "cxFileManagerService.h"
24 
25 
26 namespace cx
27 {
28 typedef boost::shared_ptr<class SelectDataStringPropertyBase> SelectDataStringPropertyBasePtr;
29 
30 class cxGui_EXPORT ActiveMeshPropertiesWidget : public BaseWidget
31 {
32  Q_OBJECT
33 public:
34  ActiveMeshPropertiesWidget(VisServicesPtr services, QWidget* parent);
36 };
37 
38 class cxGui_EXPORT AllMeshPropertiesWidget : public TabbedWidget
39 {
40  Q_OBJECT
41 public:
42  AllMeshPropertiesWidget(SelectDataStringPropertyBasePtr mesh, VisServicesPtr services, QWidget* parent);
44  SelectDataStringPropertyBasePtr getSelector() { return mMeshSelector; }
45 private:
46  SelectDataStringPropertyBasePtr mMeshSelector;
47 };
48 
50 
62 class cxGui_EXPORT MeshInfoWidget : public InfoWidget
63 {
64  Q_OBJECT
65 
66 public:
67  MeshInfoWidget(SelectDataStringPropertyBasePtr meshSelector,
68  PatientModelServicePtr patientModelService, ViewServicePtr viewService, FileManagerServicePtr fileManager,
69  QWidget* parent);
70  virtual ~MeshInfoWidget();
71 
72  SelectDataStringPropertyBasePtr getSelector() { return mMeshSelector; }
73 
74 protected slots:
75  void meshSelectedSlot();
76  void importTransformSlot();
77  void meshChangedSlot();
78  void generateNormalsSlot();
79 
80 protected:
81  virtual void showEvent(QShowEvent* event);
82  virtual void hideEvent(QCloseEvent* event);
83 
84 private:
85  void addWidgets();
86 
87  MeshPtr mMesh;
88  StringPropertyParentFramePtr mParentFrameAdapter;
91  SelectDataStringPropertyBasePtr mMeshSelector;
92 
93  PatientModelServicePtr mPatientModelService;
94  ViewServicePtr mViewService;
95  FileManagerServicePtr mFileManagerService;
96 
98 };
99 
100 }//end namespace cx
101 
102 #endif /* CXMESHINFOWIDGET_H_ */
boost::shared_ptr< class FileManagerService > FileManagerServicePtr
boost::shared_ptr< class StringPropertyDataUidEditable > StringPropertyDataUidEditablePtr
boost::shared_ptr< class StringPropertyParentFrame > StringPropertyParentFramePtr
boost::shared_ptr< class VisServices > VisServicesPtr
Definition: cxMainWindow.h:40
boost::shared_ptr< class StringPropertyDataNameEditable > StringPropertyDataNameEditablePtr
boost::shared_ptr< class ViewService > ViewServicePtr
boost::shared_ptr< class SelectDataStringPropertyBase > SelectDataStringPropertyBasePtr
Interface for making widgets with a hierarchy of tabs.
boost::shared_ptr< class PatientModelService > PatientModelServicePtr
Interface for QWidget which handles widgets uniformly for the system.
Definition: cxBaseWidget.h:88
SelectDataStringPropertyBasePtr getSelector()
SelectDataStringPropertyBasePtr getSelector()
boost::shared_ptr< class Mesh > MeshPtr
Namespace for all CustusX production code.