QT set the layout of centralWidget

tags: qt  layout  Window zoom

QT set the layout of centralWidget

This is the case before the setting. At this time, even if the layout of the control is set, the size of the control will not change with this, because the centralWidget does not set the layout.

In a blank area without controls, right-click and select a layout in the layout:

After layout, the centralWidget has a layout, and then the control can zoom normally following the window.

Intelligent Recommendation

QT layout and designer of QT

Recently I am working on a mine project, and I used QT in the interface area, so now I will summarize what I have done. The first is the design interface, first look at the main interface: Let’s...

[Qt] QT layout manager

00.Cate Article catalog 00.Cate 01. Overview 02. Layout related classes 03. Layout 04. Adding controls for layout 05. Stretching factor 06. Define control in layout 07. Manual layout 08. Appendix 01. ...

[Qt] Qt grid layout

00.Cate Article catalog 00.Cate 01. Overview 02. Development environment 03. Detailed function 04. QT designer uses grid layout 05. Use the code to implement grid layout 06. Appendix 01. Overview QGri...

[Qt] Qt manual layout

00.Cate Article catalog 00.Cate 01. Overview 02. Development environment 03. Limited window size 04. Manually calculate the adjustment control distribution 05. Computing text display width 06. Appendi...

【QT】QT layout adjustment

The layout is based on XML You can use qtcreator to view the effect The layout code will be automatically generated, so you don't have to write it yourself. But this automatic generation has its own l...

More Recommendation

QT Qt savestate() appears when using saveState() to store dockwidget layout: ‘objectname’ not set for xxx

QT Qt appears when using saveState() to store dockwidget layout savestate(): ‘objectname’ not set for xxx Causes to use restoreState() to invalidate. After this error occurred, I went to B...

Qt: horizontal layout and vertical layout

QvboxLayout: Vertical layout QHBOXLAYOUT: horizontal layout Code: Layout use summary: 1. Add a Widget to the layout 2, add a layout to the layout 3, determine the layout of Widget forward from: Author...

[Qt programming] Qt layout management

01, catalog table of Contents 01, catalog 02, layout management system 03, layout manager 3.1, Basic Layout Manager (QBoxLayout) 3.2, Shed Layout Manager (QGridLayout) 3.3, Form Layout Manager (QformL...

[Qt] QT CREATOR in the layout detailed

00.Cate Article catalog 00.Cate 01. Overview 02. Development environment 03. Overview of the layout 04. Layout Properties Settings 05. Spring strip attributes and roles 06. Appendix 01. Overview About...

[Qt] QT window geometric layout

00.Cate Article catalog 00.Cate 01. Overview 02. Development environment 03. Window geometric layout 04. Example 05. Window component settings 06. Appendix 01. Overview The coordinate system in the qt...

Copyright  DMCA © 2018-2026 - All Rights Reserved - www.programmersought.com  User Notice

Top