The DlgInputDialogImp dialog class does basically the same as Qt's QInputDialog unless that it provides no static function but the application programmer must create an instance and prepare it. More...
#include <DlgInputDialogImp.h>
Public Types | |
enum | Type { LineEdit, SpinBox, UIntBox, FloatSpinBox, ComboBox } |
Public Member Functions | |
DlgInputDialogImp (const QString &label, QWidget *parent=0, bool modal=TRUE, Type=LineEdit) | |
Constructs a Gui::Dialog::DlgInputDialogImp as a child of 'parent', with the name 'name' and widget flags set to 'f'. | |
QComboBox * | getComboBox () const |
QDoubleSpinBox * | getFloatSpinBox () const |
QLineEdit * | getLineEdit () const |
QSpinBox * | getSpinBox () const |
Gui::UIntSpinBox * | getUIntBox () const |
void | setType (Type t) |
Type | type () const |
~DlgInputDialogImp () | |
Destroys the object and frees any allocated resources. | |
Protected Slots | |
void | textChanged (const QString &s) |
void | tryAccept () |
Protected Attributes | |
Type | inputtype |
The DlgInputDialogImp dialog class does basically the same as Qt's QInputDialog unless that it provides no static function but the application programmer must create an instance and prepare it.
This requires a little more work but increases the flexibility.
Definition at line 39 of file DlgInputDialogImp.h.
Definition at line 44 of file DlgInputDialogImp.h.
DlgInputDialogImp::DlgInputDialogImp | ( | const QString & | labelTxt, | |
QWidget * | parent = 0 , |
|||
bool | modal = TRUE , |
|||
Type | type = LineEdit | |||
) |
Constructs a Gui::Dialog::DlgInputDialogImp as a child of 'parent', with the name 'name' and widget flags set to 'f'.
The dialog will by default be modeless, unless you set 'modal' to TRUE to construct a modal dialog.
Definition at line 41 of file DlgInputDialogImp.cpp.
References Gui::Dialog::Ui_DlgInputDialog::buttonCancel, Gui::Dialog::Ui_DlgInputDialog::buttonOk, draftlibs::fcgeo::connect(), Gui::Dialog::Ui_DlgInputDialog::label, Gui::Dialog::Ui_DlgInputDialog::lineEdit, setType(), Gui::Dialog::Ui_DlgInputDialog::setupUi(), textChanged(), and tryAccept().
DlgInputDialogImp::~DlgInputDialogImp | ( | ) |
Destroys the object and frees any allocated resources.
Definition at line 63 of file DlgInputDialogImp.cpp.
QComboBox * DlgInputDialogImp::getComboBox | ( | ) | const |
Definition at line 149 of file DlgInputDialogImp.cpp.
References Gui::Dialog::Ui_DlgInputDialog::comboBox.
QDoubleSpinBox * DlgInputDialogImp::getFloatSpinBox | ( | ) | const |
Definition at line 139 of file DlgInputDialogImp.cpp.
References Gui::Dialog::Ui_DlgInputDialog::floatSpinBox.
QLineEdit * DlgInputDialogImp::getLineEdit | ( | ) | const |
Definition at line 144 of file DlgInputDialogImp.cpp.
References Gui::Dialog::Ui_DlgInputDialog::lineEdit.
QSpinBox * DlgInputDialogImp::getSpinBox | ( | ) | const |
Definition at line 129 of file DlgInputDialogImp.cpp.
References Gui::Dialog::Ui_DlgInputDialog::spinBox.
Gui::UIntSpinBox * DlgInputDialogImp::getUIntBox | ( | ) | const |
Definition at line 134 of file DlgInputDialogImp.cpp.
References Gui::Dialog::Ui_DlgInputDialog::uIntSpinBox.
Referenced by Gui::Dialog::ParameterUInt::changeValue(), and Gui::Dialog::ParameterValue::onCreateUIntItem().
void DlgInputDialogImp::setType | ( | DlgInputDialogImp::Type | t | ) |
Definition at line 90 of file DlgInputDialogImp.cpp.
References Gui::Dialog::Ui_DlgInputDialog::comboBox, ComboBox, Gui::Dialog::Ui_DlgInputDialog::floatSpinBox, FloatSpinBox, inputtype, Gui::Dialog::Ui_DlgInputDialog::label, Gui::Dialog::Ui_DlgInputDialog::lineEdit, LineEdit, Gui::Dialog::Ui_DlgInputDialog::spinBox, SpinBox, Gui::Dialog::Ui_DlgInputDialog::stack, UIntBox, and Gui::Dialog::Ui_DlgInputDialog::uIntSpinBox.
Referenced by DlgInputDialogImp().
void DlgInputDialogImp::textChanged | ( | const QString & | s | ) | [protected, slot] |
Definition at line 68 of file DlgInputDialogImp.cpp.
References Gui::Dialog::Ui_DlgInputDialog::buttonOk, LineEdit, Gui::Dialog::Ui_DlgInputDialog::lineEdit, and type().
Referenced by DlgInputDialogImp().
void DlgInputDialogImp::tryAccept | ( | ) | [protected, slot] |
Definition at line 84 of file DlgInputDialogImp.cpp.
References Gui::Dialog::Ui_DlgInputDialog::lineEdit.
Referenced by DlgInputDialogImp().
DlgInputDialogImp::Type DlgInputDialogImp::type | ( | ) | const |
Definition at line 124 of file DlgInputDialogImp.cpp.
References inputtype.
Referenced by textChanged().
Type Gui::Dialog::DlgInputDialogImp::inputtype [protected] |
Definition at line 63 of file DlgInputDialogImp.h.