You already have the name of the function, QTreeWidgetItem::setFlags(), its documentation, and the Qt::ItemFlag documentation it links to. You even have the the name of the specific flag, Qt::ItemIsUserCheckable. Is it really such a difficult thing to work out?
Qt Code:
// OR QTableWidgetItem *item = new QTableWidgetItem(); // OR QStandardItem *item = new QStandardItem(); item->setFlags(Qt::ItemIsEnabled | Qt::ItemIsEditable | Qt::ItemIsUserCheckable);To copy to clipboard, switch view to plain text mode
Bookmarks