Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4073460
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T17:01:31+00:00 2026-05-20T17:01:31+00:00

I made a "widget" in Qt Designer with about a dozen controls organized into

  • 0

I made a "widget" in Qt Designer with about a dozen controls organized into horizontal and vertical layouts.

Oddly, every horizontal layout wants to be some large size, about 400 px wide, when the whole form is set to be 275px wide. Buttons, etc, contained within, are too wide for the form.

When I resize the widget form vertically or horizontally (sometimes with the max width turned off), the various layouts won’t resize. Manually setting widths (or min widths, or max widths) may affect the sizes of the controls, but not their spacing within the layout. Spacers, inserted to keep some controls at the top and some others at the bottom with a flexible space between, just don’t work at all.

What (probably) obvious thing am I overlooking?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-20T17:01:32+00:00Added an answer on May 20, 2026 at 5:01 pm

    If I understood well what you are saying, the contents of the form are not "connected", i.e., not resizing and not restricted by the form size, right?
    I think you have missed setting a "centralWidget layout".
    Try the following:

    1. Open your form by double-clicking it in Qt Creator (I don’t use the Qt Designer frequently, but I think the editor layout is almost the same on both tools).

    2. Go to the top-right window (the one having 2 columns "Object-Class") and Right-Click with your mouse at the root object (e.g., MainWindow).

    3. A context menu will appear. Click on "Lay out" (last menu item) and select "Layout Vertically" or "Layout Horizontally".

    enter image description here

    These actions will create a layout on the centralWidget object. If you select the "centralWidget" in the "Object-Class" window you can then view & change the layout properties in the (bottom-right) Property-Value window; they are the last properties in list.

    More important, after you add a layout in your centralWidget, the contents of your form should be resizing along & limited by your form’s size.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

The "joke" question Joel asked during podcast #58 made me all nostalgic for Logo,
I have made custom .xml layout for ListView. Now it looks: But it isn't
Made this custom alert box: <script type="text/javascript"> $(function () { var $alert = $('#alert');
I've made a small little "application" utilizing Django as a framework. This is an
I have a doc made of: { "_id": "00001.74365CF0449457AA5FB52822DBE1F22A", "_rev": "1-1b976f3adb75c220aff28b4c69f41e18", "game": "UT411", "guid":
I just stumbled upon this question Are "while(true)" loops so bad? They made me
I made online drawing for electronics layout editing and used html form select tag
I have heard about things like "C Runtime", "Visual C++ 2008 Runtime", ".NET Common
Made solution change: I am trying to display a html table of data.. In
Made this nice little loop for hiding and showing div's, works as a charm

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.