PDA

View Full Version : Display multiple Images in a widget



jeetu_happy
7th March 2007, 12:09
Hi

I want to display some images ( i am using QLabel to display image) in a Widget, something like pictures application`s main view. How to arrange/position different QLabel in same widget...all label are starting from top left...
How to proceed further..

thanks in advance...

jpn
7th March 2007, 12:14
Take a look at Qt's Layout Classes (http://doc.trolltech.com/4.2/layout).

patrik08
7th March 2007, 12:24
Hi

I want to display some images ( i am using QLabel to display image) in a Widget, something like pictures application`s main view. How to arrange/position different QLabel in same widget...all label are starting from top left...
How to proceed further..

thanks in advance...


http://doc.trolltech.com/4.2/layouts-flowlayout-flowlayout-cpp.html

on a QScrollArea ....



void Image_Base::Load_Connector()
{
scroll = new QScrollArea(this);
scroll->setBackgroundRole(QPalette::Dark);
scroll->setMinimumWidth(500);
wrapper = new QWidget(this);
flow = new FlowLayout(wrapper);
comio = new Comandi();
comio->SetName(nomefilmopersona);
connect(comio , SIGNAL(NewIImage(QString,QString)), this, SLOT(AppendImage(QString,QString) ) );
connect(comio , SIGNAL(SaveFakes()), this, SLOT(ReSaveOnDb() ) );
flow ->addWidget(comio);
wrapper->setLayout(flow);
scroll->setWidget(wrapper);
connect(curl , SIGNAL(OneFilePutEnd(bool) ), this, SLOT(SenderOnePutBack(bool) ) );
connect(curl , SIGNAL(ErrorCurl(QString) ), this, SLOT(CurlMistake(QString) ) );
connect(curl, SIGNAL(NextGrabList(int)), this, SLOT(ImageLoadPosition(int)));
////////////connect(curl, SIGNAL(ErrorCurl(QString)), this, SLOT(SegnalaErrore(QString)));
}




or search this forum the link of Munich dev day 2006 and on Cute page dev day download all 3-4 source code ... inside you find a dinamic image display wo rotate image onMousover