Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Create an expendable/collapsible list?
QtWS25 Last Chance

Create an expendable/collapsible list?

Scheduled Pinned Locked Moved General and Desktop
3 Posts 2 Posters 4.5k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    Adelost
    wrote on last edited by
    #1

    I would like to create an expendable/collapsible list similar to the one from the picture, taken from the 3D program Maya that uses Qt.

    !http://i.imgur.com/n3XtrpE.png?1(Expandeble list)!

    1 Reply Last reply
    0
    • C Offline
      C Offline
      ChrisW67
      wrote on last edited by
      #2

      There's some similarity to QToolBox but I expect you want to allow several open sections at the same time. You should be able to achieve this with a vertical layout with setSizeConstraint(QLayout::SetFixedSize) containing alternating toggle buttons and widgets.
      See the Extension Example in Assistant and think of the More...button as one of the bars in your dialog.

      1 Reply Last reply
      0
      • A Offline
        A Offline
        Adelost
        wrote on last edited by
        #3

        Thanks, looks quite doable. However, I noticed the list bears some resemblance to a QTreeWidget, so I was wondering if you could perhaps do something like putting putting a QWidget inside a QTreeWidget? Would that idea hold some merit, or do you think this approach would be more flexible in the long run?

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved