Hello I'm a Newbie in using Qwt. I have the task to write a program which plots a simple curve after inputting some data!

I have wrote a simple Programm which plot a curve. I don't know how to input PushButtons and other Stuff for the Input of the parameters the function. How to include QwtPlot, QPushButton, QLinedit etc. in one Window and connect each other?

Here is the simple Program: Please help me to manage this?

class Plot : public QwtPlot
{
Q_Object
public:
Plot();
}

Plot::Plot()
{
// How I can manage the input?
// with LineEdit or PushButtons in one Window?

QwtPlotCurve *curve1 = new QwtPlotCurve("Curve 1");

int n=100;

double x[n], y[n];

for (int i=0; i< n; i++)
{

x[i] = i;
y[i]= i*i;
}

curve1->setData(x,y,100);
curve1->attach(this);

}

// main program

int main(int argc, argv)
{
QApplication a(argc, argv);

Plot plot;

a.setMainWidget(&plot);

plot.resize(600,400);
plot.show();
return a.exec();

}