简体   繁体   中英

QT Dialog box when building is cutting off my UI content, how do I resize the dialog box so this does not happen?

在此处输入图像描述

Here is the example of what is happening. Above is the simple design of my UI, but below when I build my project, everything within is getting cut. What is the issue? I can't seem to find it despite trying to resize a bunch of my widgets.

在此处输入图像描述

This is what my QT dialog box structure looks like right now. Then in my main.cpp file I just had

w.setFixedSize(560,180);
w.setWindowTitle("Servo Control");

Update: I applied a grid layout to the outermost hierarchy and this fixed my problem. Strange though because the video I was following did not have any layout on it, but did not run into the same problem.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

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