Reference proper example.

Change-Id: Icda7e21f7e1eee8d4a6939ce3a50d1874ecda1e6
Reviewed-by: J-P Nurmi <j-p.nurmi@nokia.com>
bb10
Frederik Gladhorn 2012-08-15 16:01:46 +02:00 committed by Qt by Nokia
parent 575f6f5325
commit 3cc7eab39f
2 changed files with 8 additions and 1 deletions

View File

@ -161,5 +161,12 @@ int main(int argc, char *argv[])
//! [23]
}
{
//! [24]
QVBoxLayout *layout = new QVBoxLayout;
layout->addWidget(formWidget);
setLayout(layout);
//! [24]
}
return app.exec();
}

View File

@ -9096,7 +9096,7 @@ QLayout *QWidget::layout() const
Example:
\snippet uitools/textfinder/textfinder.cpp 3b
\snippet layouts/layouts.cpp 24
An alternative to calling this function is to pass this widget to
the layout's constructor.