Layout two labels
#include
#include
#include
int main(int argc, char *argv[])
{
QApplication a(argc, argv);
QWidget window;
QVBoxLayout* mainLayout = new QVBoxLayout(&window);
QLabel* label1 = new QLabel("One");
QLabel* label2 = new QLabel("Two");
mainLayout->addWidget(label1);
mainLayout->addWidget(label2);
window.show();
return a.exec();
}