NorMIT-nav  2023.01.05-dev+develop.0da12
An IGT application
cxVolumePropertiesWidget.cpp
Go to the documentation of this file.
1 /*=========================================================================
2 This file is part of CustusX, an Image Guided Therapy Application.
3 
4 Copyright (c) SINTEF Department of Medical Technology.
5 All rights reserved.
6 
7 CustusX is released under a BSD 3-Clause license.
8 
9 See Lisence.txt (https://github.com/SINTEFMedtek/CustusX/blob/master/License.txt) for details.
10 =========================================================================*/
11 
13 
14 #include <QComboBox>
15 #include <QTabWidget>
16 #include <QVBoxLayout>
17 #include <QPushButton>
20 #include "cxImage.h"
22 #include "cxCroppingWidget.h"
23 #include "cxClippingWidget.h"
24 #include "cxShadingWidget.h"
25 #include "cxDataInterface.h"
26 #include "cxDataSelectWidget.h"
28 #include "cxVolumeInfoWidget.h"
29 #include "cxVolumeHelpers.h"
30 #include "cxTypeConversions.h"
31 #include "cxPatientModelService.h"
32 #include "cxVisServices.h"
34 
35 namespace cx
36 {
37 
41 
42 ActiveVolumeWidget::ActiveVolumeWidget(PatientModelServicePtr patientModelService, ViewServicePtr viewService, QWidget* parent) :
43  BaseWidget(parent, "active_volume_widget", "Active Volume")
44 {
45  this->setToolTip("The currently selected active volume");
46  QVBoxLayout* layout = new QVBoxLayout(this);
47  layout->setMargin(0);
48  layout->addWidget(new DataSelectWidget(viewService, patientModelService, this, StringPropertyActiveImage::New(patientModelService)));
49 }
50 
54 
56  TabbedWidget(parent, "volume_properties_widget", "Volume Properties")
57 {
58  this->setToolTip("Volume properties");
59  this->insertWidgetAtTop(new ActiveVolumeWidget(services->patient(), services->view(), this));
60 
61  bool connectToActiveImage = true;
62 
63  this->addTab(new VolumeInfoWidget(services->patient(), this), "Info");
64  this->addTab(new TransferFunctionWidget(services->patient(), this, connectToActiveImage), QString("Transfer Functions"));
65  this->addTab(new ShadingWidget(services->patient()->getActiveData(), this, connectToActiveImage), "Properties");
66  this->addTab(new CroppingWidget(services->patient(), services->view(), this), "Crop");
67  this->addTab(new SelectClippersForImageWidget(services, this), "Clip");
68 }
69 
70 }//namespace
cxVolumeHelpers.h
cxTransferFunctionWidget.h
cxVolumePropertiesWidget.h
cx::TabbedWidget::addTab
void addTab(BaseWidget *newTab, QString newTabName)
Definition: cxTabbedWidget.cpp:37
cx
Namespace for all CustusX production code.
Definition: cx_dev_group_definitions.h:13
cx::BaseWidget
Interface for QWidget which handles widgets uniformly for the system.
Definition: cxBaseWidget.h:88
cxImage.h
cxVolumeInfoWidget.h
cxClippingWidget.h
cx::VisServicesPtr
boost::shared_ptr< class VisServices > VisServicesPtr
Definition: cxMainWindow.h:40
cxLabeledComboBoxWidget.h
cx::StringPropertyActiveImage::New
static StringPropertyActiveImagePtr New(PatientModelServicePtr patientModelService)
Definition: cxSelectDataStringProperty.h:52
cx::TransferFunctionWidget
Definition: cxTransferFunctionWidget.h:168
cx::TabbedWidget
Interface for making widgets with a hierarchy of tabs.
Definition: cxTabbedWidget.h:34
cx::SelectClippersForImageWidget
Definition: cxSelectClippersForDataWidget.h:58
cxDataInterface.h
cxCroppingWidget.h
cx::VolumePropertiesWidget::VolumePropertiesWidget
VolumePropertiesWidget(VisServicesPtr services, QWidget *parent)
Definition: cxVolumePropertiesWidget.cpp:55
cx::PatientModelServicePtr
boost::shared_ptr< class PatientModelService > PatientModelServicePtr
Definition: cxLogicManager.h:25
cx::ViewServicePtr
boost::shared_ptr< class ViewService > ViewServicePtr
Definition: cxLogicManager.h:28
cxTypeConversions.h
cxPatientModelService.h
cx::TabbedWidget::insertWidgetAtTop
void insertWidgetAtTop(QWidget *newWidget)
Definition: cxTabbedWidget.cpp:44
cx::ShadingWidget
Definition: cxShadingWidget.h:59
cxDataSelectWidget.h
cxSelectClippersForDataWidget.h
cxLabeledLineEditWidget.h
cx::VolumeInfoWidget
Widget for displaying various volume information.
Definition: cxVolumeInfoWidget.h:34
cxSelectDataStringProperty.h
cx::ActiveVolumeWidget::ActiveVolumeWidget
ActiveVolumeWidget(PatientModelServicePtr patientModelService, ViewServicePtr viewService, QWidget *parent)
Definition: cxVolumePropertiesWidget.cpp:42
cx::DataSelectWidget
Definition: cxDataSelectWidget.h:38
cxShadingWidget.h
cx::ActiveVolumeWidget
Widget that contains a select active image combobox.
Definition: cxVolumePropertiesWidget.h:30
cx::CroppingWidget
Definition: cxCroppingWidget.h:41
cxVisServices.h