Qt application not resizing properly
I am having a problem with resizing my gui's made from Qt.
In full screen basically they don't scale to the available 开发者_开发百科space.Here is what i did.
1. Created a gui from Qt Designer.
2. When i preview it and try to maximize it, it scales badly. The same thing happens when i use this generated code for my application(it scales badly when maximized)
Question: What am i doing wrong? Thanks.
You need to set a layout for your your main window and then add spacers in the main layout to keep things floating nicely.
http://doc.qt.nokia.com/4.7-snapshot/designer-manual.html
http://doc.qt.nokia.com/4.7-snapshot/designer-layouts.html
Give the whole widget a grid layout
so it knows how to resize.
精彩评论