简体   繁体   English

在Qt中调整窗口大小而不使用标准布局

[英]resizing window in qt without using standard layouts

I'm using QT Creator and I'm having difficulty figuring out how to enable resizing when running the widget. 我正在使用QT Creator,并且在弄清楚如何在运行小部件时启用大小调整方面遇到困难。 I know when you apply a layout (horizontal, vertical, and grid) it enables resizing, but when I use these standard layouts they reconfigure all of the widgets I have put in the window. 我知道当您应用布局(水平,垂直和网格)时,它可以调整大小,但是当我使用这些标准布局时,它们将重新配置我放置在窗口中的所有小部件。 I'm trying to enable resizing but have all of the widgets I put in the window where I want them to be. 我正在尝试启用调整大小,但是将所有小部件都放置在希望它们放置的窗口中。

Check the different layout behaviours. 检查不同的布局行为。 Use the horizontal and vertical 'spring' widget to make the other widgets to stay where they are. 使用水平和垂直“ spring”小部件使其他小部件保持原样。 Use nested layouts when you want to combine the view of the widgets. 要合并小部件的视图时,请使用嵌套布局。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM