Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Breakable Layout for Buttons-bar
Forum Updated to NodeBB v4.3 + New Features

Breakable Layout for Buttons-bar

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
5 Posts 3 Posters 1.2k 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.
  • P Offline
    P Offline
    peter-70
    wrote on last edited by peter-70
    #1

    I'm Qt newbe. Now I'm trying to implement a UI with a buttons-bar. These UI breaks into new line, when the device shows the content vertically, or it shows the buttons in one or two lines, when the device shows the content horizontally.
    How can I do this? Grateful for your help!

    edit: So if the orientation is vertically, I have f.e. 2 buttons side by side and in the next line again 2 buttons side by side, in the next line again, and so on...
    Or I have 1 button, in the next line 1 button again, and so on...
    If the orientation is horizontally I have 4 buttons side by side, in the next line f.e. 3 buttons or what ever...

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

      Hi,

      Aren't you looking for QMainWindow ?

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • P Offline
        P Offline
        peter-70
        wrote on last edited by
        #3

        No, do you know f.e. Opera Browser? When you open a new tab, you have there some quick-link buttons. These buttons are in some kind of control, that allows to arrange the buttons automatically.
        When the place is wide enough, you have f.e. 3 or 4 button-columns and 2 button-rows.
        Otherwise you have f.e. 2 button-columns, and 4 button-rows.
        Do you read me?

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          Then maybe the Flow Layout Example will be of interest.

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          0
          • I Offline
            I Offline
            ifreedom2018
            wrote on last edited by
            #5

            edit: So if the orientation is vertically, I have f.e. 2 buttons side by side and in the next line again 2 buttons side by side, in the next line again, and so on...
            Or I have 1 button, in the next line 1 button again, and so on...
            If the orientation is horizontally I have 4 buttons side by side, in the next line f.e. 3 buttons or what ever...

            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