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. QStackedLayout and QStackedWidget always taking all available space
Forum Updated to NodeBB v4.3 + New Features

QStackedLayout and QStackedWidget always taking all available space

Scheduled Pinned Locked Moved General and Desktop
qstackedlayoutsizepolicystretch
1 Posts 1 Posters 1.1k Views 2 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.
  • E Offline
    E Offline
    eduardomezencio
    wrote on 17 Jun 2015, 17:56 last edited by
    #1

    I'm adding permanent widgets to my QMainWindow's status bar. When I add a label or some widget that I create deriving from QWidget, they only take the space needed, and that's exactly how I wanted it.
    When I tried a QStackedWidget, it would always take the entire space available. Then I tried to change it's SizePolicy to no avail. Then I tried to create a QWidget with a QStackedLayout and got the same result. I tried even to derive QStackedLayout and change some stuff and nothing..
    What do I need to do for the QStackedLayout/QStackedWidget to take only the space it needs?
    Thanks

    1 Reply Last reply
    1

    1/1

    17 Jun 2015, 17:56

    • Login

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