Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
QmitkStringPropertyView.cpp
Go to the documentation of this file.
1 /*===================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
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 ===================================================================*/
17 
19  : QLabel(parent), PropertyView(property), m_StringProperty(property)
20 {
22 }
23 
25 {
26 }
27 
29 {
30  if (m_Property)
31  setText(m_StringProperty->GetValue());
32 }
33 
35 {
36  m_Property = nullptr;
37  m_StringProperty = nullptr;
38  setText("n/a");
39 }
virtual const char * GetValue() const
virtual void PropertyChanged() override
const mitk::BaseProperty * m_Property
QmitkStringPropertyView(const mitk::StringProperty *, QWidget *parent)
virtual void PropertyRemoved() override
const mitk::StringProperty * m_StringProperty
Property for strings.