Medical Imaging Interaction Toolkit
2018.4.99-389bf124
Medical Imaging Interaction Toolkit
|
Helper class to step through a list. More...
#include <mitkStepper.h>
Public Types | |
typedef Stepper | Self |
typedef itk::Object | Superclass |
typedef itk::SmartPointer< Self > | Pointer |
typedef itk::SmartPointer< const Self > | ConstPointer |
Public Member Functions | |
virtual std::vector< std::string > | GetClassHierarchy () const |
virtual const char * | GetClassName () const |
Pointer | Clone () const |
virtual unsigned int | GetPos () const |
virtual void | SetPos (unsigned int pos) |
virtual unsigned int | GetSteps () const |
virtual void | SetSteps (unsigned int _arg) |
virtual bool | GetAutoRepeat () const |
virtual void | SetAutoRepeat (bool _arg) |
virtual void | AutoRepeatOn () |
virtual void | AutoRepeatOff () |
virtual void | SetPingPong (bool _arg) |
virtual bool | GetPingPong () const |
virtual void | PingPongOn () |
virtual void | PingPongOff () |
virtual void | SetInverseDirection (bool _arg) |
virtual bool | GetInverseDirection () const |
virtual void | InverseDirectionOn () |
virtual void | InverseDirectionOff () |
void | SetRange (ScalarType min, ScalarType max) |
void | InvalidateRange () |
ScalarType | GetRangeMin () const |
ScalarType | GetRangeMax () const |
bool | HasValidRange () const |
void | RemoveRange () |
bool | HasRange () const |
void | SetUnitName (const char *unitName) |
const char * | GetUnitName () const |
void | RemoveUnitName () |
bool | HasUnitName () const |
virtual void | Next () |
virtual void | Previous () |
virtual void | MoveSlice (int sliceDelta) |
virtual void | First () |
virtual void | Last () |
Static Public Member Functions | |
static const char * | GetStaticNameOfClass () |
static Pointer | New () |
Protected Member Functions | |
Stepper () | |
~Stepper () override | |
void | Increase () |
void | Decrease () |
Protected Attributes | |
unsigned int | m_Pos |
unsigned int | m_Steps |
bool | m_AutoRepeat |
bool | m_PingPong |
bool | m_InverseDirection |
ScalarType | m_RangeMin |
ScalarType | m_RangeMax |
bool | m_RangeValid |
bool | m_HasRange |
std::string | m_UnitName |
bool | m_HasUnitName |
Helper class to step through a list.
A helper class to step through a list. Does not contain the list, just the position in the list (between 0 and GetSteps()). Provides methods like First (go to the first element), Next (go to the next one), etc.
Besides the actual number of steps, the stepper can also hold a stepping range, indicating the scalar values corresponding to the covered steps. For example, steppers are generally used to slice a dataset with a plane; Hereby, Steps indicates the total number of steps (positions) available for the plane, Pos indicates the current step, and Range indicates the physical minimum and maximum values for the plane, in this case a value in mm.
The range can also be supplied with a unit name (a string) which can be used by classes providing information about the stepping (e.g. graphical sliders).
Definition at line 47 of file mitkStepper.h.
typedef itk::SmartPointer<const Self> mitk::Stepper::ConstPointer |
Definition at line 50 of file mitkStepper.h.
typedef itk::SmartPointer<Self> mitk::Stepper::Pointer |
Definition at line 50 of file mitkStepper.h.
typedef Stepper mitk::Stepper::Self |
Definition at line 50 of file mitkStepper.h.
typedef itk::Object mitk::Stepper::Superclass |
Definition at line 50 of file mitkStepper.h.
|
protected |
Definition at line 15 of file mitkStepper.cpp.
|
overrideprotected |
Definition at line 29 of file mitkStepper.cpp.
|
virtual |
|
virtual |
Pointer mitk::Stepper::Clone | ( | ) | const |
|
protected |
Definition at line 121 of file mitkStepper.cpp.
References GetPos(), GetSteps(), m_AutoRepeat, m_InverseDirection, m_PingPong, and SetPos().
Referenced by Next(), and Previous().
|
virtual |
Definition at line 197 of file mitkStepper.cpp.
References SetPos().
|
virtual |
|
inlinevirtual |
Definition at line 50 of file mitkStepper.h.
|
virtual |
|
virtual |
|
virtual |
Referenced by mitk::MovieGenerator::WriteMovie().
|
virtual |
Referenced by QmitkSliceBasedInterpolatorWidget::AcceptAllInterpolations(), QmitkSlicesInterpolator::AcceptAllInterpolations(), mitk::SegTool2D::AddContourmarker(), Decrease(), mitk::WatershedTool::DoIt(), QmitkSliceBasedInterpolatorWidget::GetWorkingSlice(), Increase(), QmitkSlicesInterpolator::Initialize(), MoveSlice(), QmitkSlicesInterpolator::OnAccept3DInterpolationClicked(), QmitkSliceBasedInterpolatorWidget::OnAcceptInterpolationClicked(), QmitkSlicesInterpolator::OnAcceptInterpolationClicked(), QmitkSlicesInterpolator::OnTimeChanged(), mitk::OtsuTool3D::RunSegmentation(), QmitkSlicesInterpolator::SetCurrentContourListID(), QmitkSliceBasedInterpolatorWidget::SetSliceNavigationControllers(), and mitk::SliceNavigationController::Update().
mitk::ScalarType mitk::Stepper::GetRangeMax | ( | ) | const |
Definition at line 54 of file mitkStepper.cpp.
References m_RangeMax.
mitk::ScalarType mitk::Stepper::GetRangeMin | ( | ) | const |
Definition at line 49 of file mitkStepper.cpp.
References m_RangeMin.
|
inlinestatic |
Definition at line 50 of file mitkStepper.h.
|
virtual |
Referenced by Decrease(), Increase(), mitk::RenderingManager::InitializeView(), Last(), MoveSlice(), mitk::DisplayInteractor::ScrollOneDown(), mitk::DisplayInteractor::ScrollOneUp(), mitk::DisplayActionEventFunctions::ScrollSliceStepperAction(), mitk::DisplayActionEventFunctions::ScrollSliceStepperSynchronizedAction(), mitk::MultiStepper::SetPos(), QmitkSelectableGLWidget::wheelEvent(), and mitk::MovieGenerator::WriteMovie().
const char * mitk::Stepper::GetUnitName | ( | ) | const |
Definition at line 82 of file mitkStepper.cpp.
References m_UnitName.
bool mitk::Stepper::HasRange | ( | ) | const |
Definition at line 70 of file mitkStepper.cpp.
References m_HasRange.
bool mitk::Stepper::HasUnitName | ( | ) | const |
Definition at line 93 of file mitkStepper.cpp.
References m_HasUnitName.
bool mitk::Stepper::HasValidRange | ( | ) | const |
Definition at line 65 of file mitkStepper.cpp.
References m_HasRange, and m_RangeValid.
|
protected |
Definition at line 98 of file mitkStepper.cpp.
References GetPos(), GetSteps(), m_AutoRepeat, m_InverseDirection, m_PingPong, and SetPos().
Referenced by Next(), and Previous().
void mitk::Stepper::InvalidateRange | ( | ) |
Definition at line 42 of file mitkStepper.cpp.
References m_HasRange, and m_RangeValid.
|
virtual |
|
virtual |
|
virtual |
Definition at line 202 of file mitkStepper.cpp.
References GetSteps(), and SetPos().
|
virtual |
Definition at line 168 of file mitkStepper.cpp.
References GetPos(), GetSteps(), m_AutoRepeat, and SetPos().
Referenced by mitk::DisplayActionEventFunctions::ScrollSliceStepperAction(), and mitk::DisplayActionEventFunctions::ScrollSliceStepperSynchronizedAction().
|
static |
Referenced by mitk::BaseController::BaseController(), mitkMultiStepperTest(), and mitkStepperTest().
|
virtual |
Definition at line 144 of file mitkStepper.cpp.
References Decrease(), Increase(), and m_InverseDirection.
Referenced by mitk::DisplayInteractor::ScrollOneDown(), QmitkSelectableGLWidget::wheelEvent(), and mitk::MovieGenerator::WriteMovie().
|
virtual |
|
virtual |
|
virtual |
Definition at line 156 of file mitkStepper.cpp.
References Decrease(), Increase(), and m_InverseDirection.
Referenced by mitk::DisplayInteractor::ScrollOneUp(), and QmitkSelectableGLWidget::wheelEvent().
void mitk::Stepper::RemoveRange | ( | ) |
Definition at line 59 of file mitkStepper.cpp.
References m_HasRange.
void mitk::Stepper::RemoveUnitName | ( | ) |
Definition at line 87 of file mitkStepper.cpp.
References m_HasUnitName.
|
virtual |
|
virtual |
If set to true, the Next() decreases the stepper and Previous() decreases it
|
virtual |
Causes the stepper to shift direction when the boundary is reached
|
inlinevirtual |
Reimplemented in mitk::MultiStepper.
Definition at line 55 of file mitkStepper.h.
Referenced by Decrease(), mitk::SlicedGeometry3D::ExecuteOperation(), mitk::SliceNavigationController::ExecuteOperation(), First(), Increase(), mitk::RenderingManager::InitializeView(), Last(), MoveSlice(), mitk::SliceNavigationController::SelectSliceByPoint(), mitk::SliceNavigationController::SetGeometrySlice(), mitk::SliceNavigationController::SetGeometryTime(), mitk::MultiStepper::SetPos(), and mitk::InteractionTestHelper::SetTimeStep().
void mitk::Stepper::SetRange | ( | ScalarType | min, |
ScalarType | max | ||
) |
Definition at line 33 of file mitkStepper.cpp.
References m_HasRange, m_RangeMax, m_RangeMin, m_RangeValid, max(), and min().
|
virtual |
Reimplemented in mitk::MultiStepper.
Referenced by mitk::SlicedGeometry3D::ExecuteOperation(), and mitk::SlicedGeometry3D::ReinitializePlanes().
void mitk::Stepper::SetUnitName | ( | const char * | unitName | ) |
Definition at line 75 of file mitkStepper.cpp.
References m_HasUnitName, and m_UnitName.
|
protected |
Definition at line 128 of file mitkStepper.h.
Referenced by Decrease(), Increase(), and MoveSlice().
|
protected |
Definition at line 136 of file mitkStepper.h.
Referenced by HasRange(), HasValidRange(), InvalidateRange(), RemoveRange(), and SetRange().
|
protected |
Definition at line 139 of file mitkStepper.h.
Referenced by HasUnitName(), RemoveUnitName(), and SetUnitName().
|
protected |
Definition at line 131 of file mitkStepper.h.
Referenced by Decrease(), Increase(), Next(), and Previous().
|
protected |
Definition at line 130 of file mitkStepper.h.
Referenced by Decrease(), and Increase().
|
protected |
Definition at line 124 of file mitkStepper.h.
|
protected |
Definition at line 134 of file mitkStepper.h.
Referenced by GetRangeMax(), and SetRange().
|
protected |
Definition at line 133 of file mitkStepper.h.
Referenced by GetRangeMin(), and SetRange().
|
protected |
Definition at line 135 of file mitkStepper.h.
Referenced by HasValidRange(), InvalidateRange(), and SetRange().
|
protected |
Definition at line 126 of file mitkStepper.h.
Referenced by mitk::MultiStepper::UpdateStepCount().
|
protected |
Definition at line 138 of file mitkStepper.h.
Referenced by GetUnitName(), and SetUnitName().