I have created a table using QTableView and a QStandardItem widget. How to remove the vertical header from QStandardItemModel?

有帮助吗?

解决方案

If I got you right, and you want to hide the header, then you should use the header's hide() method:

QTableView * view = new QTableView();
view->verticalHeader()->hide();

Don't forget to #include <QHeaderView>

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top