MITK-IGT
IGT Extension of MITK
Loading...
Searching...
No Matches
QmitkUSNavigationZoneDistancesWidget.h
Go to the documentation of this file.
1/*============================================================================
2
3The Medical Imaging Interaction Toolkit (MITK)
4
5Copyright (c) German Cancer Research Center (DKFZ)
6All rights reserved.
7
8Use of this source code is governed by a 3-clause BSD license that can be
9found in the LICENSE file.
10
11============================================================================*/
12
13#ifndef QmitkUSNavigationZoneDistancesWidget_h
14#define QmitkUSNavigationZoneDistancesWidget_h
15
16#include <QWidget>
17
18#include "mitkNumericTypes.h"
19
20namespace itk {
21 template<class T> class SmartPointer;
22}
23
24namespace mitk {
25 class NavigationData;
26 class DataNode;
27}
28
30
38{
39 Q_OBJECT
40
41signals:
43 void SignalZoneViolated(const mitk::DataNode*, mitk::Point3D);
44
45public:
46 explicit QmitkUSNavigationZoneDistancesWidget(QWidget *parent = nullptr);
48
53 void SetSizePropertyKey(const std::string& sizePropertyKey);
54
56 const std::string& GetSizePropertyKey() const;
57
60
62 void ClearZones();
63
66
67protected:
68 std::string m_SizePropertyKey;
69 QVector<itk::SmartPointer<mitk::DataNode> > m_ZoneNodes;
70 QVector<QmitkZoneProgressBar*> m_ZoneProgressBars;
71};
72
73#endif
Widget for showing distances to given zones using instances of QmitkZoneProgressBar....
void AddZone(itk::SmartPointer< mitk::DataNode > zoneNode)
Adds a zone to the widget.
void UpdateDistancesToNeedlePosition(itk::SmartPointer< mitk::NavigationData > needle)
Updates color and label of each zone distance bar according to the given needle position.
void SetSizePropertyKey(const std::string &sizePropertyKey)
Set the key for the data node float property holding the radius of a zone. The default value of this ...
QVector< itk::SmartPointer< mitk::DataNode > > m_ZoneNodes
void SignalZoneViolated(const mitk::DataNode *, mitk::Point3D)
Emitted whenever a the distance to a zone falls below zero.
const std::string & GetSizePropertyKey() const
Get the key for the data node float property holding the radius of a zone.
void ClearZones()
Removes all zones from the widget.
QProgressBar for displaying distances to zones. Colors are changed according to the distance to the z...
IGT Exceptions.