I am trying to rename a QTreeView->header()-> setColumnText(0, "Rename");
This QTreeView has been initalized like this:
dirProxyModel->setSourceModel(dirModel);
treeView->setModel(treeProxyModel);
// I'd like to rename the column header for this, how?
treeView->header()->setColumnText(0, "Folders");
QTreeView *treeView = new QTreeView();
QDirModel *dirModel = new QDirModel();
QSortFilterProxyModel *dirProxyModel = new QSortFilterProxyModel();
dirProxyModel->setSourceModel(dirModel);
treeView->setModel(treeProxyModel);
// I'd like to rename the column header for this, how?
treeView->header()->setColumnText(0, "Folders");
To copy to clipboard, switch view to plain text mode
There doesn't seem to be a clear way to do this?
Bookmarks