Medical Imaging Interaction Toolkit  2026.06.00
Medical Imaging Interaction Toolkit
QmitkPointListWidget.h
Go to the documentation of this file.
1 /*============================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 #ifndef QmitkPointListWidget_h
13 #define QmitkPointListWidget_h
14 
16 
17 #include <QmitkPointListModel.h>
18 #include <QmitkPointListView.h>
19 
20 #include <mitkDataInteractor.h>
21 #include <mitkDataNode.h>
22 #include <mitkPointSet.h>
23 
24 #include <QPushButton>
25 #include <QToolButton>
26 
28 
52 {
53  Q_OBJECT
54 
55 public:
61  QmitkPointListWidget(QWidget *parent = nullptr, int orientation = 0);
62 
65 
68 
74 
80 
86 
92 
98 
104 
110 
115  void OnNodeDeleted(const itk::EventObject &e);
116 
119 
120 public slots:
125  void DeactivateInteractor(bool deactivate);
126 
131  void EnableEditButton(bool enabled);
132 
133 signals:
138  void EditPointSets(bool active);
139 
142 
145 
146 protected slots:
152  void OnBtnAddPoint(bool checked);
154  void OnTimeStepChanged(int timeStep);
155 
160 
162 
163 protected:
164  void SetupUi();
166 
168 
169  mitk::DataNode::Pointer m_PointSetNode;
170 
172 
173  QPushButton *m_MovePointUpBtn;
174  QPushButton *m_MovePointDownBtn;
175  QPushButton *m_RemovePointBtn;
176  QPushButton *m_SavePointsBtn;
177  QPushButton *m_LoadPointsBtn;
178  QPushButton *m_ToggleAddPoint;
179  QPushButton *m_AddPoint;
182 
183  mitk::DataInteractor::Pointer m_DataInteractor;
186  unsigned long m_NodeObserverTag;
187 
189 };
190 
191 #endif
#define MITKQTWIDGETSEXT_EXPORT
Abstract base widget for displaying multiple render windows at once.
Qt list model providing access to points in a mitk::PointSet.
GUI widget for displaying and interacting with a mitk::PointSet.
Widget for regular operations on point sets.
void ObserveNewNode(mitk::DataNode *node)
mitk::PointSet * GetPointSet()
Get the currently managed point set.
mitk::DataInteractor::Pointer m_DataInteractor
void SetPointSetNode(mitk::DataNode *newNode)
Set the data node containing the point set.
QmitkPointListWidget(QWidget *parent=nullptr, int orientation=0)
Construct the point list widget.
void EditPointSets(bool active)
Emitted when the point editing interactor is activated or deactivated.
void OnNodeDeleted(const itk::EventObject &e)
ITK observer callback for data node deletion events.
void SetupConnections()
Connect internal widget signals and slots. Called during construction.
QPushButton * m_MovePointDownBtn
void DeactivateInteractor(bool deactivate)
Deactivate the point set interactor.
void OnPointSelectionChanged()
pass through signal from PointListView that point selection has changed
mitk::DataNode * GetPointSetNode()
Get the current point set data node.
void PointSelectionChanged()
Emitted when the point selection changes in the point set.
void OnBtnAddPoint(bool checked)
~QmitkPointListWidget() override
Destructor.
void OnTimeStepChanged(int timeStep)
mitk::DataNode::Pointer m_PointSetNode
QmitkPointListModel * m_PointListModel
void EnableEditButton(bool enabled)
Enable or disable the "add point" toggle button.
void SetMultiWidget(QmitkAbstractMultiWidget *multiWidget)
Set a multi widget for automatic crosshair navigation to selected points.
void UnselectEditButton()
Programmatically uncheck the "add point" toggle button.
void SetPointSet(mitk::PointSet *newPs)
Set the point set data on the existing data node.
void RemoveSliceNavigationController(mitk::SliceNavigationController *snc)
Remove a mitk::SliceNavigationController.
void AddSliceNavigationController(mitk::SliceNavigationController *snc)
Add a mitk::SliceNavigationController for point-based crosshair navigation.
void PointListChanged()
Emitted when points are loaded, cleared, added, or removed.
QmitkPointListView * m_PointListView
Central node class of the MITK data tree, associating a data object with properties and mappers.
Definition: mitkDataNode.h:72
Data structure which stores a set of points.
Definition: mitkPointSet.h:71
Controls the selection of the slice the associated BaseRenderer will display.