Reputation: 5695
Is it possible to set widget in center of dialog or windows in QDesigner, say I have a widget contain 3 line edits and labels and I want to set this widget in center of window.
Upvotes: 21
Views: 34203
Reputation: 70108
In latest Qt Designer, right-click a widget in the Object Inspector and choose your preference under Layout Alignment.
Upvotes: 36
Reputation: 2528
It should be quite simple:
Insert another horizontal spacer
Add Vertical spacer to Horizontal spacer (drag to widget tree)
Works in my QtCreator, should also in Your Designer :)
Good luck.
Upvotes: 6
Reputation: 14416
Add a layout to your windows and add the widgets in the layout. Then you can set the position policy in the properties panel of the layout.
Upvotes: 1