I created a QTreeView and then select an item of the view to create a second view that contains a subset of the original tree showing only the ancesters and offsprings of the selected item using QSortFilterProxyModel.

In the second view (NOT in the original view), I want to make the ancestors of the selected item un-selectable (grayed out). Is that possible?
Thanks in advance.