OpenWalnut  1.5.0dev
Public Slots | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
WPropertyIntervalWidget Class Reference

Implements a property widget for WPropInterval. More...

#include <WPropertyIntervalWidget.h>

+ Inheritance diagram for WPropertyIntervalWidget:
+ Collaboration diagram for WPropertyIntervalWidget:

Public Slots

void minMaxUpdated ()
 Called whenever the interval edit changes. More...
 
void reset ()
 Reset to default. More...
 

Public Member Functions

 WPropertyIntervalWidget (WPropInterval property, QGridLayout *propertyGrid, QWidget *parent=0)
 Constructor. More...
 
virtual ~WPropertyIntervalWidget ()
 Destructor. More...
 
- Public Member Functions inherited from WPropertyWidget
 WPropertyWidget (std::shared_ptr< WPropertyBase > property, QGridLayout *propertyGrid, QWidget *parent=0)
 Constructor. More...
 
virtual ~WPropertyWidget ()
 Destructor. More...
 
std::shared_ptr< WPropertyBasegetProperty ()
 Returns the handled property. More...
 
virtual void invalidate (bool invalid=true)
 This method marks this widget as invalid. More...
 
virtual std::string getTooltip () const
 Gets the tooltip that should be used for this widget. More...
 
QWidget * getParameterWidgets ()
 Returns the parameter widget for this property. More...
 
QWidget * getInformationWidgets ()
 Returns the info widget for this property. More...
 
virtual void requestUpdate ()
 Request an update of the property widget. More...
 
void forceInformationMode (bool force=true)
 Force the widget to use the information widgets. More...
 

Protected Member Functions

virtual void update ()
 Called whenever the widget should update. More...
 
- Protected Member Functions inherited from WPropertyWidget
virtual bool event (QEvent *event)
 Custom event dispatcher. More...
 

Protected Attributes

WPropInterval m_intervalProperty
 The property represented by this widget. More...
 
QHBoxLayout m_layout
 Layout used to position the label and the checkbox. More...
 
QVBoxLayout m_vLayout
 Layout used to combine the property widgets with the WQtIntervalEdit. More...
 
WScaleLabel m_asText
 Used to show the property as text. More...
 
QHBoxLayout m_infoLayout
 The layout used for the pure output (information properties) More...
 
QLineEdit m_minEdit
 Minimum Value. More...
 
QLineEdit m_maxEdit
 Maximum Value. More...
 
QToolButton m_resetBtn
 Reset button. More...
 
- Protected Attributes inherited from WPropertyWidget
std::shared_ptr< WPropertyBasem_property
 The property handled by the widget. More...
 
QGridLayout * m_propertyGrid
 The grid used to layout label and widget. More...
 
WScaleLabel m_label
 The label used to name the property. More...
 
QWidget m_separator
 Separator after each property. More...
 
bool m_useLabel
 If set to true, the widgets uses the control layout to combine the widget with a label. More...
 
QWidget m_parameterWidgets
 The widget containing a layout and provides the edit widgets for the property. More...
 
QWidget m_informationWidgets
 The widget containing a layout and provides the widgets for showing information properties. More...
 
bool m_invalid
 Flag denoting whether the widget is set to an invalid value. More...
 
boost::signals2::connection m_connection
 The connection for propertyChangeNotifier(). More...
 
QColor m_sepCol
 The color to use for separators. More...
 
QColor m_labelCol
 The color to use for the property labels. More...
 
QColor m_propertyCol
 The color to use for property widgets. More...
 
QColor m_errorCol
 Color used for indicating errors. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from WPropertyWidget
static WPropertyWidgetconstruct (WPropertyBase::SPtr property, QGridLayout *propertyGrid=NULL, QWidget *parent=NULL)
 Constructs a proper widget for the specified property. More...
 

Detailed Description

Implements a property widget for WPropInterval.

Definition at line 43 of file WPropertyIntervalWidget.h.

Constructor & Destructor Documentation

◆ WPropertyIntervalWidget()

WPropertyIntervalWidget::WPropertyIntervalWidget ( WPropInterval  property,
QGridLayout *  propertyGrid,
QWidget *  parent = 0 
)

Constructor.

Creates a new widget appropriate for the specified property.

Parameters
propertythe property to handle
parentthe parent widget.
propertyGridthe grid used to layout the labels and property widgets

Definition at line 43 of file WPropertyIntervalWidget.cpp.

References WQtGui::getIconManager(), m_asText, m_infoLayout, WPropertyWidget::m_informationWidgets, m_layout, m_maxEdit, m_minEdit, WPropertyWidget::m_parameterWidgets, m_resetBtn, m_vLayout, minMaxUpdated(), reset(), and update().

+ Here is the call graph for this function:

◆ ~WPropertyIntervalWidget()

WPropertyIntervalWidget::~WPropertyIntervalWidget ( )
virtual

Destructor.

Definition at line 99 of file WPropertyIntervalWidget.cpp.

Member Function Documentation

◆ minMaxUpdated

void WPropertyIntervalWidget::minMaxUpdated ( )
slot

Called whenever the interval edit changes.

Definition at line 115 of file WPropertyIntervalWidget.cpp.

References WPropertyWidget::invalidate(), m_intervalProperty, m_maxEdit, and m_minEdit.

Referenced by WPropertyIntervalWidget().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ reset

void WPropertyIntervalWidget::reset ( )
slot

Reset to default.

Definition at line 133 of file WPropertyIntervalWidget.cpp.

Referenced by WPropertyIntervalWidget().

+ Here is the caller graph for this function:

◆ update()

void WPropertyIntervalWidget::update ( )
protectedvirtual

Called whenever the widget should update.

Implements WPropertyWidget.

Definition at line 104 of file WPropertyIntervalWidget.cpp.

References m_asText, m_intervalProperty, m_maxEdit, m_minEdit, and WScaleLabel::setText().

Referenced by WPropertyIntervalWidget().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Member Data Documentation

◆ m_asText

WScaleLabel WPropertyIntervalWidget::m_asText
protected

Used to show the property as text.

Definition at line 85 of file WPropertyIntervalWidget.h.

Referenced by update(), and WPropertyIntervalWidget().

◆ m_infoLayout

QHBoxLayout WPropertyIntervalWidget::m_infoLayout
protected

The layout used for the pure output (information properties)

Definition at line 90 of file WPropertyIntervalWidget.h.

Referenced by WPropertyIntervalWidget().

◆ m_intervalProperty

WPropInterval WPropertyIntervalWidget::m_intervalProperty
protected

The property represented by this widget.

Definition at line 70 of file WPropertyIntervalWidget.h.

Referenced by minMaxUpdated(), and update().

◆ m_layout

QHBoxLayout WPropertyIntervalWidget::m_layout
protected

Layout used to position the label and the checkbox.

Definition at line 75 of file WPropertyIntervalWidget.h.

Referenced by WPropertyIntervalWidget().

◆ m_maxEdit

QLineEdit WPropertyIntervalWidget::m_maxEdit
protected

Maximum Value.

Definition at line 100 of file WPropertyIntervalWidget.h.

Referenced by minMaxUpdated(), update(), and WPropertyIntervalWidget().

◆ m_minEdit

QLineEdit WPropertyIntervalWidget::m_minEdit
protected

Minimum Value.

Definition at line 95 of file WPropertyIntervalWidget.h.

Referenced by minMaxUpdated(), update(), and WPropertyIntervalWidget().

◆ m_resetBtn

QToolButton WPropertyIntervalWidget::m_resetBtn
protected

Reset button.

Definition at line 105 of file WPropertyIntervalWidget.h.

Referenced by WPropertyIntervalWidget().

◆ m_vLayout

QVBoxLayout WPropertyIntervalWidget::m_vLayout
protected

Layout used to combine the property widgets with the WQtIntervalEdit.

Definition at line 80 of file WPropertyIntervalWidget.h.

Referenced by WPropertyIntervalWidget().


The documentation for this class was generated from the following files: