I am trying to display interactive hyperlinks in my QTreeView.
I was able to do this using QLabels and QTreeView.setIndexWidget in accordance with the recommendations on this.
Hyperlinks in QTreeView
Unfortunately, my QTreeView can be quite large (1000 items), and creating 1000 QLabels is slow.
The surface is that I can use a delegate in my QTreeView to draw text that looks like hyperlinks. It's very fast.
Now the problem is that I need them to react like hyperlinks (like mouse cursor, mouse pointer, etc.), but I'm not sure what the best way to do this.
I managed to fake it by simply connecting to the click () QTreeView signal, but this is not quite the same, because it responds to the entire cell, not just the text inside the cell.
user297250
source share