Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
Adjusting Indenting for QTreeView items
Taytoo last edited by Taytoo
Currently items in QTreeView appear as follows - in terms of indentation: Note -> = space and + = Expand/Collapse icon
-> <icon><text> + Group Name -----><icon><text>
How can I decrease indenting? e.g.
<icon><text> + Parent Name --><icon><text>
Note that the Item without a Parent still is indented but not as much as previously
Bonnie last edited by
You can try
void QTreeView::setIndentation(int i)
Taytoo last edited by
@Bonnie Already tried it, but it sets identation for all items and end result isn't visually correct - or what I'm trying to achieve.
Did you try a Delegate to paint it the way you like ?