Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
berryContributionItem.h
Go to the documentation of this file.
1 /*===================================================================
2 
3 BlueBerry Platform
4 
5 Copyright (c) German Cancer Research Center,
6 Division of Medical and Biological Informatics.
7 All rights reserved.
8 
9 This software is distributed WITHOUT ANY WARRANTY; without
10 even the implied warranty of MERCHANTABILITY or FITNESS FOR
11 A PARTICULAR PURPOSE.
12 
13 See LICENSE.txt or http://www.mitk.org for details.
14 
15 ===================================================================*/
16 
17 
18 #ifndef BERRYCONTRIBUTIONITEM_H
19 #define BERRYCONTRIBUTIONITEM_H
20 
21 #include "berryIContributionItem.h"
22 
24 
25 namespace berry {
26 
31 {
32 
33 public:
34 
36 
37  enum Mode {
38  DEFAULT = 0x00,
39 
45  MODE_FORCE_TEXT = 0x01
46  };
47  Q_DECLARE_FLAGS(Modes, Mode)
48 
49  enum Style {
50 
54  STYLE_PUSH = 0x01,
55 
59  STYLE_CHECK = 0x02,
60 
64  STYLE_RADIO = 0x04,
65 
69  STYLE_PULLDOWN = 0x08
70  };
71 
76  void Fill(QStatusBar* parent) override;
77 
82  void Fill(QMenu* menu, QAction* before) override;
83 
88  void Fill(QMenuBar* menu, QAction* before) override;
89 
94  void Fill(QToolBar* parent, QAction* before) override;
95 
100  void SaveWidgetState() override;
101 
102  /*
103  * Method declared on IContributionItem.
104  */
105  QString GetId() const override;
106 
113  IContributionManager *GetParent() const;
114 
119  bool IsDirty() const override;
120 
125  bool IsEnabled() const override;
126 
131  bool IsDynamic() const override;
132 
137  bool IsGroupMarker() const override;
138 
143  bool IsSeparator() const override;
144 
151  bool IsVisible() const override;
152 
158  void SetVisible(bool visible) override;
159 
164  QString ToString() const override;
165 
170  void Update() override;
171 
172  /*
173  * Method declared on IContributionItem.
174  */
175  void SetParent(IContributionManager* parent) override;
176 
182  void Update(const QString& id) override;
183 
191  void SetId(const QString& itemId);
192 
193 protected:
194 
200 
208  ContributionItem(const QString& id);
209 
210 private:
211 
215  QString id;
216 
221  bool visible;
222 
226  IContributionManager* parent;
227 };
228 
229 }
230 
231 #endif // BERRYCONTRIBUTIONITEM_H
static void Update(vtkPolyData *)
Definition: mitkSurface.cpp:35
berryObjectMacro(ContributionItem) enum Mode
The custom viewer plugin implements simple viewer functionality presented in a customized look and feel It was developed to demonstrate extensibility and customizability of the blueberry application framework As an example for the GUI customization capabilities provided by the BlueBerry application the custom viewer plugin was developed It features simple viewer functionality presented in a customized look and feel The custom viewer consists of two i e a viewer perspective and a DICOM perspective As part of the viewer an instance of QmitkDataManagerView allows for data selection Visualization of the selected data is then performed by a simple render window view According data can either be directly loaded from file or be imported as DICOM data DICOM import functionality is accessible from the DICOM perspective incorporating the QmitkDicomExternalDataWidget The customization of Qt Stylesheets is used to give the application a non native look and feel This is further emphasized by a Tab Widget like unification of the perspectives with the according perspective bar In addition to an absence of menu
#define BERRY_UI_QT