NifTK  16.4.1 - 0798f20
CMIC's Translational Medical Imaging Platform
Public Member Functions | Static Public Attributes | Protected Slots | Protected Member Functions | List of all members
niftk::ImageLookupTablesView Class Reference

Provides a simple GUI enabling the selection of window, level, min, max and a choice of lookup tables. More...

Inheritance diagram for niftk::ImageLookupTablesView:
Inheritance graph
[legend]
Collaboration diagram for niftk::ImageLookupTablesView:
Collaboration graph
[legend]

Public Member Functions

 ImageLookupTablesView ()
 
 ImageLookupTablesView (const ImageLookupTablesView &other)
 
virtual ~ImageLookupTablesView ()
 
virtual void CreateQtPartControl (QWidget *parent) override
 Called by framework, this method creates all the controls for this view. More...
 
virtual void OnSelectionChanged (berry::IWorkbenchPart::Pointer source, const QList< mitk::DataNode::Pointer > &nodes) override
 Called by framework when DataManager's selection has changed. More...
 
- Public Member Functions inherited from niftk::BaseView
 BaseView ()
 
virtual ~BaseView ()
 
virtual void onVisibilityChanged (const mitk::DataNode *node) override
 Called when the visibility of a node in the data storage changed. More...
 
virtual void OnFocusChanged ()
 Called when the window focus changes, and tracks the current mitk::BaseRenderer*. More...
 
virtual bool IsExclusiveFunctionality () const
 Returns whether this functionality should be exclusive, or in other words, the only active plugin. More...
 
virtual bool IsActivated ()
 Returns the activation status. More...
 
virtual bool IsVisible ()
 Returns the visible status. More...
 
mitk::DataStorage::Pointer GetDataStorage () const override
 Gets the currently active data storage. More...
 
virtual void SetCurrentSelection (mitk::DataNode::Pointer dataNode) override
 Selects the data node in this view and also in the data manager. It sets the "selected" property of the node. As a (positive) side effect of changing the data manager selection, the "selected" property of the previously selected nodes will be cleared. More...
 
virtual QmitkRenderWindow * GetRenderWindow (QString id)
 Retrieves a RenderWindow from the mitkRenderWindowPart. More...
 
virtual QmitkRenderWindow * GetSelectedRenderWindow () const override
 Retrieves the currently selected RenderWindow from the mitkRenderWindowPart. More...
 
virtual bool IsActiveEditorCursorVisible () const override
 Gets the visibility of the cursor (aka. crosshair) in the 2D render windows of the main display. More...
 
virtual void SetActiveEditorCursorVisible (bool visible) const override
 Sets the visibility of the cursor (aka. crosshair) in the 2D render windows of the main display. More...
 
virtual void RequestRenderWindowUpdate (mitk::RenderingManager::RequestType requestType=mitk::RenderingManager::REQUEST_UPDATE_ALL) override
 Request an update of all render windows of the currently active render window part. More...
 
QList< mitk::DataNode::Pointer > GetDataManagerSelection () const override
 Gets the list of nodes selected in the data manager. More...
 
virtual void FireNodeSelected (mitk::DataNode::Pointer node) override
 Informs other parts of the workbench that node is selected via the blueberry selection service. More...
 
virtual
mitk::SliceNavigationController * 
GetSliceNavigationController () override
 Retrieve the current slice navigation controller from the currently focused render window. More...
 
virtual void FocusOnCurrentWindow () const override
 Used to try and get the FocusManager to focus on the Current IRenderWindowPart. More...
 
virtual mitk::Point3D GetSelectedPosition () const override
 Gets the selected position in the active render window part. More...
 
virtual void SetSelectedPosition (const mitk::Point3D &selectedPosition) override
 Sets the selected position in the active render window part. More...
 
- Public Member Functions inherited from niftk::VisibilityChangeObserver
 VisibilityChangeObserver ()
 
virtual ~VisibilityChangeObserver ()
 

Static Public Attributes

static const QString VIEW_ID = "uk.ac.ucl.cmic.imagelookuptables"
 Each view for a plugin has its own globally unique ID. More...
 

Protected Slots

void OnRangeChanged ()
 Called when a different image is selected or the min/max intensity limits has changed, which affects the actual minimum and maximum values that the sliders can reach. More...
 
void OnWindowBoundsChanged ()
 Called when the min/max slider has changed. More...
 
void OnLevelWindowChanged ()
 Called when the window/level slider has changed. More...
 
void OnLookupTableComboBoxChanged (int comboBoxIndex)
 Called when the lookup table combo box value changes, trigger the lookup table to be swapped. More...
 
void OnResetButtonPressed ()
 Called when the reset button is pressed which will recalculate the minimum and maximum intensity values, and set the minimum and maximum value on the sliders. More...
 
void OnLoadButtonPressed ()
 Called when the load button is pressed which will display a dialog allowing the user to load a lookup table. More...
 
void OnSaveButtonPressed ()
 Called when the save button is pressed which will display a dialog allowing the user to save the current lookup table. More...
 
void OnNewButtonPressed ()
 Called when the create new lookup table is pressed which will create an unscaled lookup table that is empty. More...
 
void OnAddLabelButtonPressed ()
 Add a label to the current label map. More...
 
void OnRemoveLabelButtonPressed ()
 Remove the selected labels to the current label map. More...
 
void OnMoveLabelUpButtonPressed ()
 Move the selected labels up one place in the list. More...
 
void OnMoveLabelDownButtonPressed ()
 Move the selected labels down one place in the list. More...
 
void OnColorButtonPressed (int)
 Change color of pressed label color. More...
 
void OnLabelMapTableCellChanged (int, int)
 Change name or value of selected cell. More...
 

Protected Member Functions

virtual void Activated () override
 
virtual void SetFocus () override
 Called by framework, sets the focus on a specific widget. More...
 
virtual void OnPropertyChanged (const itk::EventObject &)
 We listen to the Level/Window property on the registered image, so this callback updates this GUI when the watched property changes. More...
 
virtual void OnLookupTablePropertyChanged (const itk::EventObject &)
 Called when the user toggles the opacity control properties. More...
 
virtual void OnPropertyChanged ()
 Actually updates the GUI when property changes. More...
 
- Protected Member Functions inherited from niftk::BaseView
virtual void Deactivated () override
 
virtual void Visible () override
 
virtual void Hidden () override
 
virtual QWidget * GetParent ()
 
virtual void SetParent (QWidget *)
 Normally called from within CreateQtPartControl, we store the parent widget. More...
 
void SetViewToCoordinate (const mitk::Point3D &coordinate)
 Gets the current render window, and sets it to the given coordinate, specified in millimetres. More...
 

Additional Inherited Members

- Public Types inherited from niftk::BaseView
typedef QmitkAbstractView SuperClass
 

Detailed Description

Provides a simple GUI enabling the selection of window, level, min, max and a choice of lookup tables.

Constructor & Destructor Documentation

niftk::ImageLookupTablesView::ImageLookupTablesView ( )
explicit
niftk::ImageLookupTablesView::ImageLookupTablesView ( const ImageLookupTablesView other)
niftk::ImageLookupTablesView::~ImageLookupTablesView ( )
virtual

Member Function Documentation

void niftk::ImageLookupTablesView::Activated ( )
overrideprotectedvirtual
See also
niftk::BaseView::Activated()

Reimplemented from niftk::BaseView.

void niftk::ImageLookupTablesView::CreateQtPartControl ( QWidget *  parent)
overridevirtual

Called by framework, this method creates all the controls for this view.

This is probably superfluous because the AbstractView::AfterCreateQtPartControl() calls OnPreferencesChanged that calls RetrievePreferenceValues. It would need testing.

void niftk::ImageLookupTablesView::OnAddLabelButtonPressed ( )
protectedslot

Add a label to the current label map.

void niftk::ImageLookupTablesView::OnColorButtonPressed ( int  index)
protectedslot

Change color of pressed label color.

void niftk::ImageLookupTablesView::OnLabelMapTableCellChanged ( int  row,
int  column 
)
protectedslot

Change name or value of selected cell.

void niftk::ImageLookupTablesView::OnLevelWindowChanged ( )
protectedslot

Called when the window/level slider has changed.

void niftk::ImageLookupTablesView::OnLoadButtonPressed ( )
protectedslot

Called when the load button is pressed which will display a dialog allowing the user to load a lookup table.

void niftk::ImageLookupTablesView::OnLookupTableComboBoxChanged ( int  comboBoxIndex)
protectedslot

Called when the lookup table combo box value changes, trigger the lookup table to be swapped.

void niftk::ImageLookupTablesView::OnLookupTablePropertyChanged ( const itk::EventObject &  )
protectedvirtual

Called when the user toggles the opacity control properties.

void niftk::ImageLookupTablesView::OnMoveLabelDownButtonPressed ( )
protectedslot

Move the selected labels down one place in the list.

void niftk::ImageLookupTablesView::OnMoveLabelUpButtonPressed ( )
protectedslot

Move the selected labels up one place in the list.

void niftk::ImageLookupTablesView::OnNewButtonPressed ( )
protectedslot

Called when the create new lookup table is pressed which will create an unscaled lookup table that is empty.

void niftk::ImageLookupTablesView::OnPropertyChanged ( const itk::EventObject &  )
protectedvirtual

We listen to the Level/Window property on the registered image, so this callback updates this GUI when the watched property changes.

void niftk::ImageLookupTablesView::OnPropertyChanged ( )
protectedvirtual

Actually updates the GUI when property changes.

void niftk::ImageLookupTablesView::OnRangeChanged ( )
protectedslot

Called when a different image is selected or the min/max intensity limits has changed, which affects the actual minimum and maximum values that the sliders can reach.

void niftk::ImageLookupTablesView::OnRemoveLabelButtonPressed ( )
protectedslot

Remove the selected labels to the current label map.

void niftk::ImageLookupTablesView::OnResetButtonPressed ( )
protectedslot

Called when the reset button is pressed which will recalculate the minimum and maximum intensity values, and set the minimum and maximum value on the sliders.

void niftk::ImageLookupTablesView::OnSaveButtonPressed ( )
protectedslot

Called when the save button is pressed which will display a dialog allowing the user to save the current lookup table.

void niftk::ImageLookupTablesView::OnSelectionChanged ( berry::IWorkbenchPart::Pointer  source,
const QList< mitk::DataNode::Pointer > &  nodes 
)
overridevirtual

Called by framework when DataManager's selection has changed.

Reimplemented from niftk::BaseView.

void niftk::ImageLookupTablesView::OnWindowBoundsChanged ( )
protectedslot

Called when the min/max slider has changed.

void niftk::ImageLookupTablesView::SetFocus ( )
overrideprotectedvirtual

Called by framework, sets the focus on a specific widget.

Member Data Documentation

const QString niftk::ImageLookupTablesView::VIEW_ID = "uk.ac.ucl.cmic.imagelookuptables"
static

Each view for a plugin has its own globally unique ID.


The documentation for this class was generated from the following files: