简体   繁体   English

如何使布局填充qt选项卡小部件内的所有内容?

[英]How to make layout fill everything inside qt tab widget?

I added a tab widget in my Qt application, and then added a vertical layout in the first tab, and added things inside the vertical layout.我在我的 Qt 应用程序中添加了一个选项卡小部件,然后在第一个选项卡中添加了垂直布局,并在垂直布局内添加了东西。 However, I cannot make the vertical layout fill the entire tab, I can only set the dimensions with the mouse.但是,我不能让垂直布局填满整个选项卡,我只能用鼠标设置尺寸。 There's no option to make it fill everything.没有选择让它填满所有东西。

在此处输入图片说明

How to make a vertical layout (or any widget) fill the entire widget tab?如何使垂直布局(或任何小部件)填充整个小部件选项卡?

You need to assign a layout to each tab.您需要为每个选项卡分配一个布局。 In Creator, look for the layout in the widget hierarchy!在 Creator 中,在小部件层次结构中查找布局!

在此处输入图片说明

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

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