PDA

View Full Version : QTreeWidget Hide Highlighter



tvj4218
11th May 2017, 21:26
I've got a QTreeWidget that I use to display a few things. I do not need the blue highlighter that comes up when you mouse over the table.

I've tried setting the selectionMode to NoSelection, and that has not worked.

Thanks for any help.

t

Santosh Reddy
12th May 2017, 12:36
Set the flags for each QTreeWidgetItem


QTreeWidgetItem * item = new QTreeWidgetItem();

item->setFlags(item->flags() & ~Qt::ItemIsSelectable);

tvj4218
13th May 2017, 00:29
This did not work. what else can I try?