I'd like to find out the item under the mouse pointer without having to left click the item first. There doesn't appear to be a function for this or am I missing something?
I'd like to find out the item under the mouse pointer without having to left click the item first. There doesn't appear to be a function for this or am I missing something?
Item of what? QGraphicsScene, QListView... You can useQt Code:
To copy to clipboard, switch view to plain text mode
Item of a QTreeView, as specified in the subject
I didn't think I could use itemAt as it only worked for Widget views such as ListWidget rather than model views such as QTreeView, QTableView, etc ?
That's a good point, and shows that I am definitely to tired...
For views it is QAbstractItemView::indexAt().I didn't think I could use itemAt as it only worked for Widget views such as ListWidget rather than model views such as QTreeView, QTableView, etc ?
Bookmarks