Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Wiki Markup
{alias:qsetcentralwidget}

Name

qsetcentralwidget — set central widget in a QMainWindow

...

The qsetcentralwidget command assigns a widget to be the central widget in a QMainWindow qmainwindow. Occupying the main central area of the mainwindow, the central widget is usually placed below a menubar and toolbar, while also being surrounded by dock areas. There may be only one central widget.

The central widget is typically a QTextEdit qtextedit or a container widget like QTabWidget qtabwidget. No layout management should be performed for the central widget.

Arguments

None

Examples

See the qmainwindow command for examples on how to use the qsetcentralwidget command.