⚠️ Forum Maintenance: Feb 6th, 8am - 14pm (UTC+2)

QTreeView - Expanded and collapsed items

  • Hello,

    I need 2 options for my model:

    1. expand or collapse everything with one level
    2. Invert selection, but I don't want all items to be selected only the ones that can be seen (even by scrolling)

    For the first one, I can use expandtoDepth, but I miss the point where Tree won't expand anymore, since it doesn't return if something was expanded.

    For the second one, I know how to select items, but I want to select items that are not hidden because it's parent isn't expanded.

    How can I implement this?

Log in to reply