finddialog.cpp:26:40: error: no matching function for call to ‘QVBoxLayout::addWidget(QHBoxLayout*&)’ finddialog.cpp:26:40: note: candidate is: /usr/include/qt4/QtGui/qboxlayout.h:85:10: note: void QBoxLayout::addWidget(QWidget*, int, Qt::Alignment) /usr/include/qt4/QtGui/qboxlayout.h:85:10: note: no known conversion for argument 1 from ‘QHBoxLayout*’ to ‘QWidget*’
QHBoxLayout *topLeftLayout = new QHBoxLayout; topLeftLayout->addWidget(label); topLeftLayout->addWidget(lineEdit); QVBoxLayout *leftLayout = new QVBoxLayout; leftLayout->addWidget(topLeftLayout); // this line have an error -> note: // no matching function for call to // ‘QVBoxLayout::addWidget(QHBoxLayout*&)’ // note: candidate is: // /usr/include/qt4/QtGui/qboxlayout.h:85:10: note: // void QBoxLayout::addWidget(QWidget*, int, Qt::Alignment)
QHBoxLayout *topLeftLayout = new QHBoxLayout; QVBoxLayout *leftLayout = new QVBoxLayout; topLeftLayout->addWidget(label); topLeftLayout->addWidget(lineEdit); //leftLayout->addWidget(topLeftLayout); leftLayout-> addLayout(topLeftLayout); </pre>
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)