15 #include "qpushbutton.h" 18 #include "qlineedit.h" 19 #if (QT_VERSION > 0x039999) // Added by cholm@nbi.dk - for Qt 4 40 QVBox(wparent,wname, f | WType_Modal | WStyle_Dialog ),
47 setSizePolicy(QSizePolicy(QSizePolicy::Expanding,
48 QSizePolicy::Expanding));
49 fArgBox =
new QVBox(
this,
"args");
50 fArgBox->setSizePolicy(QSizePolicy(QSizePolicy::Expanding,
51 QSizePolicy::Expanding));
52 QHBox *hbox =
new QHBox(
this,
"buttons");
53 QPushButton *bOk =
new QPushButton(
"Apply",hbox,
"Apply");
54 QPushButton *bCancel =
new QPushButton(
"Cancel",hbox,
"Close");
55 connect(bCancel,SIGNAL (clicked()),
this, SLOT(
close()));
56 connect(bOk,SIGNAL( clicked() ),
this, SLOT( ExecuteMethod() ));
69 #if (QT_VERSION > 0x039999) // Added by cholm@nbi.dk - for Qt 4 70 typedef QList<QLineEdit*>::iterator iter;
71 for (iter st =
fList.begin(); st !=
fList.end(); ++st) {
72 QString
s = (*st)->text();
74 tobjlist.AddLast((
TObject*) t) ;
77 for ( QLineEdit* st =
fList.first(); st; st =
fList.next()) {
78 QString
s = st->text();
80 tobjlist.AddLast((
TObject*) t) ;
95 #if (QT_VERSION > 0x039999) // Added by cholm@nbi.dk - for Qt 4 96 for (iter st =
fList.begin(); st !=
fList.end(); ++st) {
97 QString
s = (*st)->text();
98 value[
l++] = atoi (
s );
101 for ( QLineEdit* st =
fList.first(); st; st =
fList.next()) {
102 QString
s = st->text();
103 value[
l++] = atoi (
s );
106 fParent->resize(value[0], value[1]);
115 gROOT->SetSelectedPad(psave);
116 gROOT->GetSelectedPad()->Modified();
117 gROOT->GetSelectedPad()->Update();
121 gROOT->GetSelectedPad()->Update();
132 #if (QT_VERSION > 0x039999) // Added by cholm@nbi.dk - for Qt 4 148 QLineEdit* lineEdit =
new QLineEdit(
fArgBox);
154 fList.append( lineEdit );
virtual const char * GetName() const
Returns name of object.
Collectable string class.
void Add(const char *argname, const char *value, const char *type)
Add widgets for arguments.
void closeEvent(QCloseEvent *ce)
Handle close event.
TQRootDialog(const TQRootDialog &)
TVirtualPad is an abstract base class for the Pad and Canvas classes.
virtual TList * GetListOfMethodArgs()
Returns methodarg list and additionally updates fDataMember in TMethod by calling FindDataMember();...
virtual void Execute(const char *method, const char *params, Int_t *error=0)
Execute method on this object with the given parameter string, e.g.
virtual ~TQRootDialog()
dtor
static constexpr double s
Mother of all ROOT objects.
Each ROOT class (see TClass) has a linked list of methods.
void Popup()
Show the dialog.
void ExecuteMethod()
Execute ROOT methods.