Slicer  4.8
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
qSlicerTerminologySelectorButton.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Library: CTK
4 
5  Copyright (c) Kitware Inc.
6 
7  Licensed under the Apache License, Version 2.0 (the "License");
8  you may not use this file except in compliance with the License.
9  You may obtain a copy of the License at
10 
11  http://www.apache.org/licenses/LICENSE-2.0.txt
12 
13  Unless required by applicable law or agreed to in writing, software
14  distributed under the License is distributed on an "AS IS" BASIS,
15  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  See the License for the specific language governing permissions and
17  limitations under the License.
18 
19 =========================================================================*/
20 
21 #ifndef __qSlicerTerminologySelectorButton_h
22 #define __qSlicerTerminologySelectorButton_h
23 
24 // Qt includes
25 #include <QPushButton>
26 
27 // Terminologies includes
28 #include "qSlicerTerminologiesModuleWidgetsExport.h"
29 
32 
33 class qSlicerTerminologySelectorButtonPrivate;
34 
37 class Q_SLICER_MODULE_TERMINOLOGIES_WIDGETS_EXPORT qSlicerTerminologySelectorButton : public QPushButton
38 {
39  Q_OBJECT
40 
41 public:
42  explicit qSlicerTerminologySelectorButton(QWidget* parent=NULL);
44 
46  void terminologyInfo(qSlicerTerminologyNavigatorWidget::TerminologyInfoBundle &terminologyInfo);
47 
48 public slots:
50  void setTerminologyInfo(qSlicerTerminologyNavigatorWidget::TerminologyInfoBundle &terminologyInfo);
51 
53  void changeTerminology();
54 
55 signals:
56  void terminologyChanged();
57  void canceled();
58 
59 protected slots:
60  void onToggled(bool toggled=true);
61 
62 protected:
63  virtual void paintEvent(QPaintEvent* event);
64 
65  QScopedPointer<qSlicerTerminologySelectorButtonPrivate> d_ptr;
66 private :
67  Q_DECLARE_PRIVATE(qSlicerTerminologySelectorButton);
68  Q_DISABLE_COPY(qSlicerTerminologySelectorButton);
69 };
70 
71 #endif
QScopedPointer< qSlicerTerminologySelectorButtonPrivate > d_ptr
Button that opens terminology selector dialog.