Medical Imaging Interaction Toolkit
2025.12.02
Medical Imaging Interaction Toolkit
QmitkSliceNavigationWidget.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
13
#ifndef QmitkSliceNavigationWidget_h
14
#define QmitkSliceNavigationWidget_h
15
16
#include "
MitkQtWidgetsExports.h
"
17
#include "ui_QmitkSliceNavigationWidget.h"
18
19
#include <
mitkStepper.h
>
20
21
#include <QString>
22
#include <QWidget>
23
24
class
MITKQTWIDGETS_EXPORT
QmitkSliceNavigationWidget
:
public
QWidget,
public
Ui::QmitkSliceNavigationWidget
25
{
26
Q_OBJECT
27
28
public
:
29
30
QmitkSliceNavigationWidget
(QWidget* parent =
nullptr
, Qt::WindowFlags f = {});
31
38
QString
ClippedValueToString
(
float
value);
39
40
QString
GetLabelUnit
();
41
42
QString
GetMinValueLabel
();
43
44
QString
GetMaxValueLabel
();
45
46
int
GetPos
();
47
48
bool
GetInverseDirection
()
const
;
49
50
bool
GetInvertedControls
()
const
;
51
52
public
slots:
53
60
void
Refetch
();
61
66
void
SetStepper
(
mitk::Stepper
* stepper);
67
71
void
ShowLabels
(
bool
show);
72
77
void
ShowLabelUnit
(
bool
show);
78
79
void
SetPos
(
int
val);
80
81
void
SetInverseDirection
(
bool
inverseDirection);
82
83
void
SetInvertedControls
(
bool
invertedControls);
84
85
protected
slots:
86
94
void
SliderChanged
(
double
);
95
103
void
SpinBoxChanged
(
double
);
104
110
void
SetLabelValues
(
float
min,
float
max);
111
117
void
SetLabelValuesValid
(
bool
minValid,
bool
maxValid);
118
124
void
SetLabelUnit
(
const
char
* unit);
125
129
void
SetLabels
();
130
131
protected
:
132
133
mitk::Stepper::Pointer
m_Stepper
;
134
bool
m_InRefetch
;
135
136
QString
m_LabelUnit
;
137
138
bool
m_HasLabelUnit
;
139
bool
m_MaxValueValid
;
140
bool
m_MinValueValid
;
141
142
bool
m_HasLabels
;
143
float
m_MinValue
;
144
float
m_MaxValue
;
145
146
bool
m_InverseDirection
;
147
bool
m_InvertedControls
;
148
149
};
150
151
#endif
MitkQtWidgetsExports.h
MITKQTWIDGETS_EXPORT
#define MITKQTWIDGETS_EXPORT
Definition:
MitkQtWidgetsExports.h:15
QmitkSliceNavigationWidget
Definition:
QmitkSliceNavigationWidget.h:25
QmitkSliceNavigationWidget::m_MinValue
float m_MinValue
Definition:
QmitkSliceNavigationWidget.h:143
QmitkSliceNavigationWidget::SetLabelValuesValid
void SetLabelValuesValid(bool minValid, bool maxValid)
Enable / disable labels for the range minimum or maximum.
QmitkSliceNavigationWidget::ShowLabelUnit
void ShowLabelUnit(bool show)
Enable / disable displaying of the unit label (range will be displayed without unit if enabled).
QmitkSliceNavigationWidget::m_LabelUnit
QString m_LabelUnit
Definition:
QmitkSliceNavigationWidget.h:136
QmitkSliceNavigationWidget::m_Stepper
mitk::Stepper::Pointer m_Stepper
Definition:
QmitkSliceNavigationWidget.h:133
QmitkSliceNavigationWidget::m_MinValueValid
bool m_MinValueValid
Definition:
QmitkSliceNavigationWidget.h:140
QmitkSliceNavigationWidget::SetInverseDirection
void SetInverseDirection(bool inverseDirection)
QmitkSliceNavigationWidget::SetInvertedControls
void SetInvertedControls(bool invertedControls)
QmitkSliceNavigationWidget::GetLabelUnit
QString GetLabelUnit()
QmitkSliceNavigationWidget::m_MaxValueValid
bool m_MaxValueValid
Definition:
QmitkSliceNavigationWidget.h:139
QmitkSliceNavigationWidget::m_InverseDirection
bool m_InverseDirection
Definition:
QmitkSliceNavigationWidget.h:146
QmitkSliceNavigationWidget::GetMaxValueLabel
QString GetMaxValueLabel()
QmitkSliceNavigationWidget::QmitkSliceNavigationWidget
QmitkSliceNavigationWidget(QWidget *parent=nullptr, Qt::WindowFlags f={})
QmitkSliceNavigationWidget::SetLabelValues
void SetLabelValues(float min, float max)
Set label values for the range minimum and maximum.
QmitkSliceNavigationWidget::m_InRefetch
bool m_InRefetch
Definition:
QmitkSliceNavigationWidget.h:134
QmitkSliceNavigationWidget::Refetch
void Refetch()
Update the slider with the recent changes applied to the navigation widget.
QmitkSliceNavigationWidget::ShowLabels
void ShowLabels(bool show)
Enable / disable displaying of the minimum and maximum labels.
QmitkSliceNavigationWidget::ClippedValueToString
QString ClippedValueToString(float value)
Convert the passed value to a QString representation.
QmitkSliceNavigationWidget::SpinBoxChanged
void SpinBoxChanged(double)
React on changes of the spinbox.
QmitkSliceNavigationWidget::GetMinValueLabel
QString GetMinValueLabel()
QmitkSliceNavigationWidget::SetStepper
void SetStepper(mitk::Stepper *stepper)
Set the stepper that should be represented and modified.
QmitkSliceNavigationWidget::GetInverseDirection
bool GetInverseDirection() const
QmitkSliceNavigationWidget::m_HasLabelUnit
bool m_HasLabelUnit
Definition:
QmitkSliceNavigationWidget.h:138
QmitkSliceNavigationWidget::SetLabelUnit
void SetLabelUnit(const char *unit)
Set the range unit (e.g. mm or ms).
QmitkSliceNavigationWidget::SetPos
void SetPos(int val)
QmitkSliceNavigationWidget::m_InvertedControls
bool m_InvertedControls
Definition:
QmitkSliceNavigationWidget.h:147
QmitkSliceNavigationWidget::GetInvertedControls
bool GetInvertedControls() const
QmitkSliceNavigationWidget::m_HasLabels
bool m_HasLabels
Definition:
QmitkSliceNavigationWidget.h:142
QmitkSliceNavigationWidget::SetLabels
void SetLabels()
Configure slider with labels according to range and unit settings.
QmitkSliceNavigationWidget::GetPos
int GetPos()
QmitkSliceNavigationWidget::m_MaxValue
float m_MaxValue
Definition:
QmitkSliceNavigationWidget.h:144
QmitkSliceNavigationWidget::SliderChanged
void SliderChanged(double)
React on changes of the slider.
mitk::Stepper
Helper class to step through a list.
Definition:
mitkStepper.h:48
mitkStepper.h
src
MITK
Modules
QtWidgets
include
QmitkSliceNavigationWidget.h
Generated on Mon Feb 23 2026 23:28:13 for Medical Imaging Interaction Toolkit by
1.9.1