cranberries
10th June 2015, 16:37
Hi,
I add a widget, and an existing layout into the main layout as follows,
QHBoxLayout* l = new QHBoxLayout();
l->setMargin( 2 );
l->setSpacing( 5 ) );
l->addWidget( txtLabel ); // seen on the main layout in QT 4.8
l->addLayout( mLayout, 1 ); // not seen on the main layout in QT 4.8
layout()->insertLayout(0,l);
The above code block works OK with 4.1, but it does not work OK with QT4.8. Could you please help about this difference ?
I add a widget, and an existing layout into the main layout as follows,
QHBoxLayout* l = new QHBoxLayout();
l->setMargin( 2 );
l->setSpacing( 5 ) );
l->addWidget( txtLabel ); // seen on the main layout in QT 4.8
l->addLayout( mLayout, 1 ); // not seen on the main layout in QT 4.8
layout()->insertLayout(0,l);
The above code block works OK with 4.1, but it does not work OK with QT4.8. Could you please help about this difference ?