问题
I am attempting to disable editing in my table view. I came across this thread which states that you could do the following
tableView.setEditTriggers(QAbstractView::NoEditTriggers);
My question is what is the QAbstractView here ?
回答1:
that seems to be a typo and should read QAbstractItemView, which is the baseclass of QTableView where the EditTriggers enum (which NoEdittriggers is an element of) is declared.
来源:https://stackoverflow.com/questions/20023435/what-is-qabstractview-in-qt-this-statement