for the construct function
Qt Code:
  1. QGLWidget(QWidget * parent = 0, const QGLWidget * shareWidget = 0, Qt::WindowFlags f = 0)
To copy to clipboard, switch view to plain text mode 
when I use it likes this,(the class slicerCanvas and secCan all inherit QGLWidget)
Qt Code:
  1. slicerX_ = new slicerCanvas(centerWidget_);//which load data and gen texture object
  2. slicerX_->setPlaneModel('y');
  3. secWid_ = new secCan(centerWidget_,slicerX_);
To copy to clipboard, switch view to plain text mode 
the secWid_ can display correct. But if the code like this
Qt Code:
  1. secWid_ = new secCan(centerWidget_);
  2. slicerX_ = new slicerCanvas(centerWidget_,secWid_);//which load data and gen texture object
  3. slicerX_->setPlaneModel('y');
To copy to clipboard, switch view to plain text mode 
the secWid_ display correct(I use signal and slot to send and receive texture object,I don't konw whether this correct),I realy don't konw why.