[vtkusers] qtimageviewer example crashes with vtk 5.6.0
clinton at elemtech.com
Thu May 6 11:35:42 EDT 2010
> > For the infinite recursion, I've seen that happen if there was a
> > particluar QStyle used with a QVTKWidget that has no parent. Changing
> > QStyle or giving it a parent might solve your problem.
> > QWidget* parent_widget = new QWidget(NULL);
> > QVTKWidget* new_widget = new QVTKWidget(parent_widget);
> > QVBoxLayout* l = new QVBoxLayout(parent_widget);
> > l->setContentsMargins(0,0,0,0);
> > parent_widget->setLayout(l);
> > l->addWidget(new_widget);
> Indeed, I was using QVTKWidget as a top level widget with parent = 0.
> I now put it in a QMainWindow as central widget and it works :-)
A fix has been put into the repository so the workaround would no longer be
More information about the vtkusers