BALL  1.4.79
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
Signals | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
BALL::VIEW::PropEditorWidget Class Referenceabstract

#include <BALL/VIEW/WIDGETS/propertyEditor.h>

Inheritance diagram for BALL::VIEW::PropEditorWidget:
QWidget BALL::VIEW::BoolEditorWidget BALL::VIEW::DoubleEditorWidget BALL::VIEW::FloatEditorWidget BALL::VIEW::IntEditorWidget BALL::VIEW::PDBInfoEditorWidget BALL::VIEW::PropDeleteWidget BALL::VIEW::StringEditorWidget BALL::VIEW::UIntEditorWidget

Signals

void deleteProperty ()
 
void duplicateProperty ()
 
void valueChanged ()
 

Public Member Functions

 PropEditorWidget (const std::string &name, QWidget *parent)
 
virtual const QString & getName () const
 
void setEditable (bool mode)
 
bool isEditable () const
 
void apply (PropertyManager *man, bool create=false)
 
void reset (PropertyManager *man)
 
virtual PropEditorWidgetclone (const std::string &name, QWidget *parent)=0
 

Protected Member Functions

void setupUi_ ()
 
bool addWidget_ (int i, QWidget *w)
 
virtual void apply_ (PropertyManager *man)=0
 
virtual void reset_ (const NamedProperty &prop)=0
 

Protected Attributes

QString name_
 
Ui::PropEditorWidget ui_
 

Detailed Description

Abstract baseclass for widgets providing editor capability for a single NamedProperty If you wish to provide you own property editor you need to inherit from this class.

Definition at line 38 of file propertyEditor.h.

Constructor & Destructor Documentation

BALL::VIEW::PropEditorWidget::PropEditorWidget ( const std::string &  name,
QWidget parent 
)

Construct a PropEditorWidget for the property name with parent 'parent'

Member Function Documentation

bool BALL::VIEW::PropEditorWidget::addWidget_ ( int  i,
QWidget w 
)
protected

Utility function which adds the widget w to the internal layout

void BALL::VIEW::PropEditorWidget::apply ( PropertyManager man,
bool  create = false 
)

Apply the changes in the widget to man

Parameters
manthe Property manager the changes are applied to
createshould a new named property be created if the property this widget represents could not be found?
virtual void BALL::VIEW::PropEditorWidget::apply_ ( PropertyManager man)
protectedpure virtual
virtual PropEditorWidget* BALL::VIEW::PropEditorWidget::clone ( const std::string &  name,
QWidget parent 
)
pure virtual

Create a copy of the widget with a different name, but with the same property type. This method must be reimplemented by subclasses

Implemented in BALL::VIEW::PDBInfoEditorWidget, BALL::VIEW::PropDeleteWidget, BALL::VIEW::StringEditorWidget, BALL::VIEW::DoubleEditorWidget, BALL::VIEW::FloatEditorWidget, BALL::VIEW::UIntEditorWidget, BALL::VIEW::IntEditorWidget, and BALL::VIEW::BoolEditorWidget.

void BALL::VIEW::PropEditorWidget::deleteProperty ( )
signal

This signal is triggered when the user requested to delete this property

void BALL::VIEW::PropEditorWidget::duplicateProperty ( )
signal

This signal is triggered when the user requested to duplicate this property

virtual const QString& BALL::VIEW::PropEditorWidget::getName ( ) const
virtual

Return the name of the property

bool BALL::VIEW::PropEditorWidget::isEditable ( ) const

Returns wheter the widget is editable

void BALL::VIEW::PropEditorWidget::reset ( PropertyManager man)

Reread the properties values from man

virtual void BALL::VIEW::PropEditorWidget::reset_ ( const NamedProperty prop)
protectedpure virtual
void BALL::VIEW::PropEditorWidget::setEditable ( bool  mode)

Toggles the editablitiy of the widget

void BALL::VIEW::PropEditorWidget::setupUi_ ( )
protected
void BALL::VIEW::PropEditorWidget::valueChanged ( )
signal

This signal is triggered when the user changed the value of this widget

Member Data Documentation

QString BALL::VIEW::PropEditorWidget::name_
protected

Definition at line 119 of file propertyEditor.h.

Ui::PropEditorWidget BALL::VIEW::PropEditorWidget::ui_
protected

Definition at line 120 of file propertyEditor.h.