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. Right space is not the same as left space in ScrollArea

Right space is not the same as left space in ScrollArea

Scheduled Pinned Locked Moved Unsolved General and Desktop
2 Posts 2 Posters 197 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.
  • G Offline
    G Offline
    GrayNeel
    wrote on last edited by
    #1

    Hello guys,

    i'm experiencing some problems with the ScrollArea. In particular, while updating widgets in my scrollArea I am not able to set properly buttons in order to be spaced correctly while resizing the MainWindow.
    I'll try to explain better with some images.

    When the app runs, buttons are aligned to the left, as in this picture:
    c9212bf7-e5d8-469b-97af-f6b15f734bcd-immagine.png

    But when i reduce the size of the main window this is what I get:
    e940ce8f-f69f-4c4f-96ac-c0735f5ff4eb-immagine.png

    The right size stretches much more than what I expect to. How is it possible to fix it?

    Pl45m4P 1 Reply Last reply
    0
    • G GrayNeel

      Hello guys,

      i'm experiencing some problems with the ScrollArea. In particular, while updating widgets in my scrollArea I am not able to set properly buttons in order to be spaced correctly while resizing the MainWindow.
      I'll try to explain better with some images.

      When the app runs, buttons are aligned to the left, as in this picture:
      c9212bf7-e5d8-469b-97af-f6b15f734bcd-immagine.png

      But when i reduce the size of the main window this is what I get:
      e940ce8f-f69f-4c4f-96ac-c0735f5ff4eb-immagine.png

      The right size stretches much more than what I expect to. How is it possible to fix it?

      Pl45m4P Offline
      Pl45m4P Offline
      Pl45m4
      wrote on last edited by
      #2

      @GrayNeel

      Probably you are using QScrollArea wrong. It looks like you have set a layout to your scrollArea and placed your buttons inside. The scrollArea is supposed to take one widget with is scollable afterwards.


      If debugging is the process of removing software bugs, then programming must be the process of putting them in.

      ~E. W. Dijkstra

      1 Reply Last reply
      1

      • Login

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