Medical Imaging Interaction Toolkit  2024.06.00
Medical Imaging Interaction Toolkit
QmitkLevelWindowWidgetContextMenu.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 QmitkLevelWindowWidgetContextMenu_h
14 #define QmitkLevelWindowWidgetContextMenu_h
15 
16 #include <MitkQtWidgetsExports.h>
17 
18 #include <QMenu>
19 #include <mitkLevelWindowManager.h>
20 #include <mitkLevelWindowPreset.h>
21 
31 {
32  Q_OBJECT
33 
34 public:
36  QmitkLevelWindowWidgetContextMenu(QWidget *parent, Qt::WindowFlags f = {});
38 
43 
49 
52 
55 
59 
62  std::map<QAction *, mitk::LevelWindowProperty::Pointer> m_Images;
63 
69  void GetContextMenu(QMenu *contextMenu);
70 
72  void GetContextMenu();
73 
75  void SetLevelWindowManager(mitk::LevelWindowManager *levelWindowManager);
76 
77 protected:
78 
79  QAction *m_PresetAction;
82 
83 protected Q_SLOTS:
84 
86  void OnSetPreset(const QAction *presetAction);
87 
90  void OnUseOptimizedLevelWindow();
91 
93  void OnUseAllGreyvaluesFromImage();
94 
96  void OnSetFixed();
97 
99  void OnAddPreset();
100 
102  void OnSetDefaultLevelWindow();
103 
105  void OnSetDefaultScaleRange();
106 
108  void OnChangeScaleRange();
109 
111  void OnSetImage(QAction *imageAction);
112 
114  void OnSetMaximumWindow();
115 };
116 
117 #endif
QmitkLevelWindowWidgetContextMenu::m_LevelWindow
mitk::LevelWindow m_LevelWindow
Definition: QmitkLevelWindowWidgetContextMenu.h:48
QmitkLevelWindowWidgetContextMenu::m_PresetSubmenu
QMenu * m_PresetSubmenu
submenu with all presets for contextmenu
Definition: QmitkLevelWindowWidgetContextMenu.h:51
MITKQTWIDGETS_EXPORT
#define MITKQTWIDGETS_EXPORT
Definition: MitkQtWidgetsExports.h:15
QmitkLevelWindowWidgetContextMenu::m_AutoTopmostAction
QAction * m_AutoTopmostAction
Definition: QmitkLevelWindowWidgetContextMenu.h:80
QmitkLevelWindowWidgetContextMenu::m_SelectedImagesAction
QAction * m_SelectedImagesAction
Definition: QmitkLevelWindowWidgetContextMenu.h:81
mitk::LevelWindowPreset
Definition: mitkLevelWindowPreset.h:23
QmitkLevelWindowWidgetContextMenu::m_ImageSubmenu
QMenu * m_ImageSubmenu
submenu with all images for contextmenu
Definition: QmitkLevelWindowWidgetContextMenu.h:54
mitk::LevelWindowManager
Provides access to the LevelWindowProperty object and LevelWindow of the "current" image.
Definition: mitkLevelWindowManager.h:51
mitk::LevelWindow
The LevelWindow class Class to store level/window values.
Definition: mitkLevelWindow.h:45
QmitkLevelWindowWidgetContextMenu
Provides a contextmenu for Level/Window functionality.
Definition: QmitkLevelWindowWidgetContextMenu.h:30
MitkQtWidgetsExports.h
QmitkLevelWindowWidgetContextMenu::m_PresetAction
QAction * m_PresetAction
Definition: QmitkLevelWindowWidgetContextMenu.h:79
QmitkLevelWindowWidgetContextMenu::m_Manager
mitk::LevelWindowManager * m_Manager
Definition: QmitkLevelWindowWidgetContextMenu.h:58
QmitkLevelWindowWidgetContextMenu::m_Images
std::map< QAction *, mitk::LevelWindowProperty::Pointer > m_Images
Definition: QmitkLevelWindowWidgetContextMenu.h:62
mitkLevelWindowPreset.h
mitkLevelWindowManager.h
QmitkLevelWindowWidgetContextMenu::m_LevelWindowPreset
mitk::LevelWindowPreset * m_LevelWindowPreset
Definition: QmitkLevelWindowWidgetContextMenu.h:42