qse  0.5.4
Public Member Functions | Protected Attributes | List of all members
QseStringParameterEditor Class Reference

#include <qsestringparametereditor.h>

Inheritance diagram for QseStringParameterEditor:
Inheritance graph

Public Member Functions

 QseStringParameterEditor (QseOperatorEditor *ed, QseStringParameter *param, QObject *parent=0)
 
void setEditors (QLineEdit *value, QPushButton *apply, QPushButton *cancel)
 
virtual bool editorValidate ()
 
virtual void editorApply ()
 
virtual void editorCancel ()
 
- Public Member Functions inherited from QseParameterEditor
 QseParameterEditor (QseOperatorEditor *ed, QseParameter *param, QObject *parent=0)
 
void setEditors (QPushButton *apply, QPushButton *cancel)
 

Protected Attributes

QseStringParameterm_StringParameter
 
QLineEdit * m_LineEdit
 
- Protected Attributes inherited from QseParameterEditor
QseOperatorEditorm_OperatorEditor
 
QseParameterm_Parameter
 
QPushButton * m_ApplyButton
 
QPushButton * m_CancelButton
 

Additional Inherited Members

- Protected Slots inherited from QseParameterEditor
void editorChanged ()
 

Detailed Description

Definition at line 9 of file qsestringparametereditor.h.

Constructor & Destructor Documentation

QseStringParameterEditor::QseStringParameterEditor ( QseOperatorEditor ed,
QseStringParameter param,
QObject *  parent = 0 
)

Definition at line 9 of file qsestringparametereditor.cpp.

10  : QseParameterEditor(ed, param, parent),
11  m_StringParameter(param),
12  m_LineEdit(NULL)
13 {
14 }
QseStringParameter * m_StringParameter
QseParameterEditor(QseOperatorEditor *ed, QseParameter *param, QObject *parent=0)

Member Function Documentation

void QseStringParameterEditor::editorApply ( )
virtual

Implements QseParameterEditor.

Definition at line 33 of file qsestringparametereditor.cpp.

References m_LineEdit, QseParameterEditor::m_Parameter, and QseParameter::setValue().

34 {
35  QString s = m_LineEdit -> text();
36 
38 
39 // printf("QseStringParameterEditor::editorApply: %s = %s\n",
40 // qPrintable(m_Parameter->name()),
41 // qPrintable(m_Parameter->value().toString()));
42 }
QseParameter * m_Parameter
void setValue(const QVariant &value)
void QseStringParameterEditor::editorCancel ( )
virtual

Implements QseParameterEditor.

Definition at line 44 of file qsestringparametereditor.cpp.

References m_LineEdit, QseParameterEditor::m_Parameter, and QseParameter::value().

45 {
46  m_LineEdit->setText(m_Parameter->value().toString());
47 }
QVariant value() const
QseParameter * m_Parameter
bool QseStringParameterEditor::editorValidate ( )
virtual

Implements QseParameterEditor.

Definition at line 28 of file qsestringparametereditor.cpp.

29 {
30  return true;
31 }
void QseStringParameterEditor::setEditors ( QLineEdit *  value,
QPushButton *  apply,
QPushButton *  cancel 
)

Definition at line 17 of file qsestringparametereditor.cpp.

References QseParameterEditor::setEditors().

18 {
19  QseParameterEditor::setEditors(apply, cancel);
20  m_LineEdit = value;
21 
22  connect(m_LineEdit, SIGNAL(textChanged(const QString&)),
23  this, SLOT(editorChanged()));
24 
25  editorCancel();
26 }
void setEditors(QPushButton *apply, QPushButton *cancel)

Member Data Documentation

QLineEdit* QseStringParameterEditor::m_LineEdit
protected

Definition at line 27 of file qsestringparametereditor.h.

Referenced by editorApply(), and editorCancel().

QseStringParameter* QseStringParameterEditor::m_StringParameter
protected

Definition at line 26 of file qsestringparametereditor.h.


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