Computer Assited Medical Intervention Tool Kit  version 3.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
MonitoringDialog.h
Go to the documentation of this file.
1 /*****************************************************************************
2  * $CAMITK_LICENCE_BEGIN$
3  *
4  * CamiTK - Computer Assisted Medical Intervention ToolKit
5  * (c) 2001-2014 UJF-Grenoble 1, CNRS, TIMC-IMAG UMR 5525 (GMCAO)
6  *
7  * Visit http://camitk.imag.fr for more information
8  *
9  * This file is part of CamiTK.
10  *
11  * CamiTK is free software: you can redistribute it and/or modify
12  * it under the terms of the GNU Lesser General Public License version 3
13  * only, as published by the Free Software Foundation.
14  *
15  * CamiTK is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18  * GNU Lesser General Public License version 3 for more details.
19  *
20  * You should have received a copy of the GNU Lesser General Public License
21  * version 3 along with CamiTK. If not, see <http://www.gnu.org/licenses/>.
22  *
23  * $CAMITK_LICENCE_END$
24  ****************************************************************************/
25 
26 #ifndef MONITORINGDIALOG_H
27 #define MONITORINGDIALOG_H
28 
29 #include "MMLMonitoringGUIAPI.h"
30 
31 #include <QDialog>
32 
33 #include "ui_MonitoringDialog.h"
34 
36 
37 class StoppingCriterion;
38 
46 class /* needed if you monitoringgui is compiled as shared: MML_MONITORING_GUI_API*/ MonitoringDialog : public QDialog {
47  Q_OBJECT
48 
49 public:
51  MonitoringDialog(MonitoringGuiManager* guiManager, QWidget* parent = 0);
53  virtual ~MonitoringDialog();
54 
56  void init();
57 
59  void updateAll();
61  void updateMonitors();
65  void updateSimulation();
67  void updateSimulatorWidget();
69  QString getMmlInFileName();
71  QTableWidget * getMonitorsTableWidget();
72 
73 
74 
75 public slots:
76 
78  void browseMmlIn();
80  void saveMmlOut();
82  void saveCsv();
84  void saveMmlIn();
86  void browsePml();
88  void browseLml();
90  void dtModified();
92  void refreshModified();
93 
97  void pause();
100  void simulate();
102  void simulateOneStep();
104  void rewind();
105 
106 signals:
108  void monitorsChanged();
109 
110 
111 private:
113  Ui::MonitoringDialog ui;
114 
117 
119  QColor bgColor;
120 
122  void enableButtons(bool enable);
123 
125  QTreeWidgetItem* createItem(StoppingCriterion* sc,QTreeWidgetItem* parent);
126 };
127 
128 #endif // MONITORINGDIALOG_H
void updateSimulation()
update simulation tab
Definition: MonitoringDialog.cpp:271
void pause()
do one step of simulation
Definition: MonitoringDialog.cpp:189
QColor bgColor
the initial bg color
Definition: MonitoringDialog.h:119
MonitoringDialog(MonitoringGuiManager *guiManager, QWidget *parent=0)
Default Constructor.
Definition: MonitoringDialog.cpp:39
void browsePml()
Slot called when Browse Pml file is clicked.
Definition: MonitoringDialog.cpp:171
void dtModified()
Slot called after dt editing.
Definition: MonitoringDialog.cpp:338
void updateAll()
update all tabs
Definition: MonitoringDialog.cpp:209
void refreshModified()
Slot called after refresh editing.
Definition: MonitoringDialog.cpp:343
void saveMmlIn()
Slot called when save MmlIn file is clicked.
Definition: MonitoringDialog.cpp:149
Ui::MonitoringDialog ui
the ui dialog designed in qtdesigner
Definition: MonitoringDialog.h:113
A GUI to manipulate mml documents.
Definition: MonitoringGuiManager.h:45
QString getMmlInFileName()
get MmlIn file name
Definition: MonitoringDialog.cpp:333
void updateMonitors()
update monitors tab
Definition: MonitoringDialog.cpp:240
QTreeWidgetItem * createItem(StoppingCriterion *sc, QTreeWidgetItem *parent)
Definition: MonitoringDialog.cpp:316
void saveMmlOut()
Slot called when save MmlOut file is clicked.
Definition: MonitoringDialog.cpp:133
virtual ~MonitoringDialog()
Destructor.
Definition: MonitoringDialog.cpp:78
void monitorsChanged()
emitted
void simulateOneStep()
Slot called when the next step is clicked.
Definition: MonitoringDialog.cpp:184
void rewind()
Slot called when the button Rewind is clicked.
Definition: MonitoringDialog.cpp:194
void browseMmlIn()
Slot called when Browse MmlIn file is clicked.
Definition: MonitoringDialog.cpp:124
void browseLml()
Slot called when Browse Lml file is clicked.
Definition: MonitoringDialog.cpp:158
void init()
initialize dialog
Definition: MonitoringDialog.cpp:86
TODO Comment class here.
Definition: MonitoringDialog.h:46
void saveCsv()
Slot called when save as csv file is clicked.
Definition: MonitoringDialog.cpp:141
MonitoringGuiManager * guiManager
the monitoring manager
Definition: MonitoringDialog.h:116
class which represent the stopping criterion to check to stop simulation a StoppingCriterion is eithe...
Definition: StoppingCriterion.h:48
void updateSimulatorWidget()
update simulator specific widget
Definition: MonitoringDialog.cpp:297
void simulate()
Slot called when the button Play is clicked.
Definition: MonitoringDialog.cpp:202
void updateStoppingCriteria()
update stopping criteria tab
Definition: MonitoringDialog.cpp:284
QTableWidget * getMonitorsTableWidget()
get the monitors table
Definition: MonitoringDialog.cpp:347
void enableButtons(bool enable)
set the rew,play,pause,step buttons enable or not
Definition: MonitoringDialog.cpp:91