Slicer  4.8
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
qMRMLPlotViewControllerWidget.h
Go to the documentation of this file.
1 /*==============================================================================
2 
3  Copyright (c) Kapteyn Astronomical Institute
4  University of Groningen, Groningen, Netherlands. All Rights Reserved.
5 
6  See COPYRIGHT.txt
7  or http://www.slicer.org/copyright/copyright.txt for details.
8 
9  Unless required by applicable law or agreed to in writing, software
10  distributed under the License is distributed on an "AS IS" BASIS,
11  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  See the License for the specific language governing permissions and
13  limitations under the License.
14 
15  This file was originally developed by Davide Punzo, Kapteyn Astronomical Institute,
16  and was supported through the European Research Council grant nr. 291531.
17 
18 ==============================================================================*/
19 
20 #ifndef __qMRMLPlotViewControllerWidget_h
21 #define __qMRMLPlotViewControllerWidget_h
22 
23 // CTK includes
24 #include <ctkVTKObject.h>
25 
26 // qMRMLWidget includes
27 #include "qMRMLViewControllerBar.h"
28 class qMRMLPlotViewControllerWidgetPrivate;
29 class qMRMLPlotView;
30 
31 // MRML includes
33 
39 class QMRML_WIDGETS_EXPORT qMRMLPlotViewControllerWidget
40  : public qMRMLViewControllerBar
41 {
42  Q_OBJECT
43  QVTK_OBJECT
44 
45 public:
48 
50  explicit qMRMLPlotViewControllerWidget(QWidget* parent = 0);
52 
54  void setViewLabel(const QString& newViewLabel);
55 
57  QString viewLabel()const;
58 
59 public slots:
61  virtual void setMRMLScene(vtkMRMLScene* newScene);
62 
64  void setPlotView(qMRMLPlotView* PlotView);
65 
68  void setMRMLPlotViewNode(vtkMRMLPlotViewNode* PlotViewNode);
69 
71  void showGrid(bool show);
72 
74  void showLegend(bool show);
75 
78  void showTitle(bool show);
79 
82  void fitPlotToAxes();
83 
86  void showXAxisLabel(bool show);
87 
90  void showYAxisLabel(bool show);
91 
94  void setTitle(const QString& str);
95 
98  void setXAxisLabel(const QString& str);
99 
102  void setYAxisLabel(const QString& str);
103 
105  void editTitle();
106 
108  void editXAxisLabel();
109 
111  void editYAxisLabel();
112 
113 protected slots:
114  void updateWidgetFromMRML();
115 
116 private:
117  Q_DECLARE_PRIVATE(qMRMLPlotViewControllerWidget);
118  Q_DISABLE_COPY(qMRMLPlotViewControllerWidget);
119 };
120 
121 #endif
MRML node to represent Plot view parameters.
qMRMLViewControllerBar Superclass
Superclass typedef.
A set of MRML Nodes that supports serialization and undo/redo.
Definition: vtkMRMLScene.h:54
qMRMLPlotView is the display canvas for a Plot.
Definition: qMRMLPlotView.h:46
virtual void setMRMLScene(vtkMRMLScene *newScene)
Set the MRML scene associated with the widget.