This code correctly displays an image, and resizes it when the window is resized:
QLabel *imageLabel;
QTabWidget *imageTabWidget;
// new...
imageTabWidget->addTab(imageLabel, "Image");
I would like the same behaviour putting the image in a table (still inside the previous tab). However all I can get now is a fixed size image:
QTableWidget *innerTable = new QTableWidget;
innerTable->setRowCount(1);
innerTable->setColumnCount(1);
innerTable->setCellWidget(0, 0, imageLabel);
innerTable->resizeColumnsToContents();
innerTable->resizeRowsToContents();
imageTabWidget->addTab(innerTable, "Image");
Is it possible to have a resizeable table at all?
Thank you.