Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
Olivier Ronat last edited by
How to use QTreeWidgetItemIterator::UserFlag flag. I want to know how we can definie the specific userflag in the QTreeWidgetItem.
It seems you can't with the current API. There's a private
bool QTreeWidgetItemIterator::matchesFlags(const QTreeWidgetItem *item) constmethod of the iterator that does the checking of flags, but the user defined ones are not checked in any way.
It would make sense to make that function virtual protected, so you could inherit and extend the iterator to match your needs, but it's not in there (yet?). You could probably make a suggestion for that on the bugreports.qt.io.