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. QTreeView - How to increase the size of expand/collapse buttons and how to apply style upon that?
Forum Updated to NodeBB v4.3 + New Features

QTreeView - How to increase the size of expand/collapse buttons and how to apply style upon that?

Scheduled Pinned Locked Moved Solved General and Desktop
2 Posts 1 Posters 1.0k Views 1 Watching
  • 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.
  • K Offline
    K Offline
    kumararajas
    wrote on last edited by
    #1

    Hi,

    How to set the height and width of the expand and collapse buttons in the QTreeView?

    I have used setIndentation to set the width of the button. And in the stylesheet, I have used QTreeView::item to set height and width.

    It worked.

    But, now, when I have used QItemDelegate, to manage some of tree item data, the size is collapsed, the height is resized to the minimum. But, width remains same because of setIndentation I guess.

    Any thoughts?

    Thanks,
    Kumara

    --Kumar

    1 Reply Last reply
    0
    • K Offline
      K Offline
      kumararajas
      wrote on last edited by
      #2

      Alright! I have fixed this problem by myself.

      I have reimplemented sizeHint and I have set the size to the one I wanted.

      This solves the problem.

      --Kumar

      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