Slicer  5.1
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
qSlicerAnnotationModuleReportDialog.h
Go to the documentation of this file.
1 #ifndef __qSlicerAnnotationModuleReportDialog_h
2 #define __qSlicerAnnotationModuleReportDialog_h
3 
4 #include "ui_qSlicerAnnotationModuleReportDialog.h"
6 #include "vtkCollection.h"
7 
9 class qSlicerAnnotationModuleReportDialog : public QDialog
10 {
11  Q_OBJECT
12 public:
15 
16  Ui::qSlicerAnnotationModuleReportDialog getReportDialogUi();
17 
20 
22  void setAnnotations(vtkCollection* collection);
23 
25  void updateReport();
26 
27 protected:
28 
29 
30 protected slots:
31  void onDialogRejected();
32  void onDialogAccepted();
33  void onTextEdited();
34  void onPrintButtonClicked();
35 
36 signals:
37  void dialogRejected();
38  void dialogAccepted();
39 
40 private:
41 
42  Ui::qSlicerAnnotationModuleReportDialog ui;
43  void createConnection();
44 
45  QString generateReport();
46  void generateReportRecursive(int level, vtkMRMLAnnotationHierarchyNode* currentHierarchy);
47 
48  // check if a mrmlId is part of the selected annotations
49  bool isSelected(const char* mrmlId);
50 
51  bool saveReport();
52 
54 
55  // the selected annotations
56  vtkCollection* m_Annotations;
57  // check if a mrmlId is part of the selected annotations
58  bool isAnnotationSelected(const char* mrmlId);
59 
60  QString m_Html;
61 
62 };
63 
64 #endif
Ui::qSlicerAnnotationModuleReportDialog getReportDialogUi()
void setAnnotations(vtkCollection *collection)
Set a collection of Annotations to be included in the report.
void updateReport()
Update the report.
void setLogic(vtkSlicerAnnotationModuleLogic *logic)
Set the Annotation module logic.