Reference proper example.
authorFrederik Gladhorn <frederik.gladhorn@nokia.com>
Wed, 15 Aug 2012 14:01:46 +0000 (16:01 +0200)
committerQt by Nokia <qt-info@nokia.com>
Sat, 18 Aug 2012 04:15:53 +0000 (06:15 +0200)
Change-Id: Icda7e21f7e1eee8d4a6939ce3a50d1874ecda1e6
Reviewed-by: J-P Nurmi <j-p.nurmi@nokia.com>
src/widgets/doc/snippets/layouts/layouts.cpp
src/widgets/kernel/qwidget.cpp

index 49c341c..f6a11ad 100644 (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();
 }
index 09bbb95..9b4a4bd 100644 (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.