Setting icon to each items head
Unsolved
General and Desktop
-
-
@VRonin Thanks for an update!
Yes, I'm reading it right now!
I want to switch the icon from multiple icon list according to the contents.
SO,,,,, I need to program to switch the stylesheet (eg.QTreeView::branch:open/close), correct?
Not sure any alternative solution at the moment..Sat
-
Are you sure you can't work with just the
Qt::DecorationRole
? what you want to implement is not easy at all.Either you subclass a style and reimplement
drawPrimitive
forQStyle::PE_IndicatorBranch
or use the stylesheet to remove the indicators altogether and paint them over manually subclassingQTreeView
and reimplementingdrawBranches