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. Making a custom UI resizable
Forum Updated to NodeBB v4.3 + New Features

Making a custom UI resizable

Scheduled Pinned Locked Moved Solved General and Desktop
3 Posts 2 Posters 227 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.
  • T Offline
    T Offline
    TimNorton
    wrote on last edited by
    #1

    I have a UI with manually placed controls that I would like to make resizable. From what I've looked up the way to do this is to use layouts, but when I try to create my setup using layouts I can't get the alignments and locations I want since it "snaps" the controls into places I don't want. Is there a way to create this UI setup I have and make it resizable so that all the controls scale with the window size?

    q1.JPG q2.JPG

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

      Hi,

      If you don't want to use layouts, then you have to reimplement the resizeEvent method of your main widget and do there the sizing and placing the way you want it.

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

      T 1 Reply Last reply
      1
      • SGaistS SGaist

        Hi,

        If you don't want to use layouts, then you have to reimplement the resizeEvent method of your main widget and do there the sizing and placing the way you want it.

        T Offline
        T Offline
        TimNorton
        wrote on last edited by
        #3

        @SGaist Ok, thanks. I'll give that a try.

        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