QTableView show scroll

197 Views Asked by At

I am working on Qt application. There I have QTableView which takes its data from QAbstractTableModel. I am using QList to represent each row in the table. My question is, I would like to start showing scroll instead of keep growing table view size when I have more than 5 entries. How can I do that?

Thanks in advance

1

There are 1 best solutions below

0
On BEST ANSWER

Does setting the Scrollbar Policy solve the problem?

tableView->setVerticalScrollBarPolicy(Qt::ScrollBarAsNeeded);