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. QScrollArea alignment

QScrollArea alignment

Scheduled Pinned Locked Moved Solved General and Desktop
11 Posts 3 Posters 1.1k 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.
  • D Offline
    D Offline
    DevM
    wrote on last edited by
    #1

    Hello,

    I'm having this problem where the QScrollArea isn't expandingfully on the layout only fixed size works:

    bc6ba8b5-3434-4a40-8937-f71944e6e171-image.png

    918fb5d5-2f76-4411-99de-163ed5098bea-image.png

    The grid layout has that label and QCombobox and then the scrollArea bellow them but it doesn't seem to want to occupy the rest of the layout, anyone has any ideias on this?

    1 Reply Last reply
    0
    • mrjjM Offline
      mrjjM Offline
      mrjj
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi
      I put grid layout on form, add label, combo and scroll area

      alt text

      It expands for me so i wonder what i did miss ?

      1 Reply Last reply
      1
      • D Offline
        D Offline
        DevM
        wrote on last edited by
        #3

        That's strange, doesn't seem to work for me :l

        JonBJ mrjjM 2 Replies Last reply
        0
        • D DevM

          That's strange, doesn't seem to work for me :l

          JonBJ Offline
          JonBJ Offline
          JonB
          wrote on last edited by JonB
          #4

          @DevM
          First place to check is what's in the .ui file, for anything unexpected/different from default @mrjj case.

          1 Reply Last reply
          1
          • D DevM

            That's strange, doesn't seem to work for me :l

            mrjjM Offline
            mrjjM Offline
            mrjj
            Lifetime Qt Champion
            wrote on last edited by
            #5

            @DevM
            Very odd,
            Even creating a fresh one just for test don't work ? `? (takes no time to drag and drop to form)

            I wonder if you tweak the label somehow or change properties ?

            and grid_7 is not part of something bigger layout or anything?

            1 Reply Last reply
            0
            • D Offline
              D Offline
              DevM
              wrote on last edited by DevM
              #6

              grid_7 is indeed part of another grid layout but don't see how it could affect in this case.

              Overall tree is like this:
              595ca79a-48a9-4744-9637-8a3ef6eac161-image.png

              grid 5 containing everything up the button up top:
              369a9713-edb4-4e22-bf23-4f7c8fcb87cb-image.png
              grid5 layout settings:
              4ea6d14e-825e-4448-a565-9f95bec8f103-image.png

              then grid 7 which is inside grid5 and contains that Qlabel and Qcombobox plus the scrollArea:
              6e33e0a6-eb55-4d97-920e-5ecd6469d16f-image.png

              and its settings:
              34fa81e8-2ac5-491a-993f-a54d2ecd308f-image.png

              then the scrollArea itself with this:
              ec862b20-7736-454d-913c-63278b0c6d11-image.png

              Also it seems that in a new form there's no problem , all works.
              code .ui if it helps in anything: https://pastebin.com/k8e1e4pe

              1 Reply Last reply
              0
              • mrjjM Offline
                mrjjM Offline
                mrjj
                Lifetime Qt Champion
                wrote on last edited by
                #7

                Hi
                Ui files always help :)
                I cant explain what up with it. it's like it has fixed size on it but it has not.

                And once i fix it, it does not go back. o.O

                alt text

                1 Reply Last reply
                0
                • D Offline
                  D Offline
                  DevM
                  wrote on last edited by
                  #8

                  Yea its behaving oddly, didn't want to have it as fixed size ugh

                  mrjjM 1 Reply Last reply
                  0
                  • D DevM

                    Yea its behaving oddly, didn't want to have it as fixed size ugh

                    mrjjM Offline
                    mrjjM Offline
                    mrjj
                    Lifetime Qt Champion
                    wrote on last edited by
                    #9

                    @DevM
                    Well it dont have to be luckly.
                    For some odd reason dragging it and release it back in, makes it work normally.
                    But I cant find any reason it refused to resize dragging the handle.
                    That i have not seen before.

                    1 Reply Last reply
                    0
                    • D Offline
                      D Offline
                      DevM
                      wrote on last edited by
                      #10

                      Oh you are right that works haha, better than what it was before anyways

                      mrjjM 1 Reply Last reply
                      0
                      • D DevM

                        Oh you are right that works haha, better than what it was before anyways

                        mrjjM Offline
                        mrjjM Offline
                        mrjj
                        Lifetime Qt Champion
                        wrote on last edited by
                        #11

                        @DevM
                        Yes it becomes normal again but i do wonder how it got sort of stuck like that.

                        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