Hi all,
How to add a column in QTreeView, and how to name that column ?
Thanks,
Hi all,
How to add a column in QTreeView, and how to name that column ?
Thanks,
The headers (i.e. columns) are a part of the model.
npc (24th January 2007)
You need to use a model. Just look up QStandardItemModel in your documentation.
Qt Code:
p->setHeaderData(0, Qt::Horizontal, "First Column"); p->setHeaderData(1, Qt::Horizontal, "Second Column"); myView->setModel(p);To copy to clipboard, switch view to plain text mode
npc (24th January 2007)
Bookmarks