How to set the width of a column on QTableWidget
-
Hi guys,
I'd like to set a specific width for a column of the QTableWidget I'm using on my GUI. How can I do that?
-
@void QTableWidget::setColumnWidth ( int column, int width ) @
isn't help? -
I solved my trouble with this code:
@
//configure the rows and the columns on the table
ui->stepsViewer->setColumnCount(5);
ui->stepsViewer->setColumnWidth(0, 80);
ui->stepsViewer->setColumnWidth(1, 80);
ui->stepsViewer->setColumnWidth(2, 150);
ui->stepsViewer->setColumnWidth(3, 150);
//ui->stepsViewer->setColumnWidth(4, 250);
ui->stepsViewer->horizontalHeader()->setStretchLastSection(true);
@ -
thanks for your interest in this matter @qxoz.