Participer au site avec un Tip
Rechercher
 

Améliorations / Corrections

Vous avez des améliorations (ou des corrections) à proposer pour ce document : je vous remerçie par avance de m'en faire part, cela m'aide à améliorer le site.

Emplacement :

Description des améliorations :

Module « PySide6.QtWidgets »

Classe « QMainWindow »

Informations générales

Héritage

builtins.object
    Object
        QPaintDevice
builtins.object
    Object
        QObject
            QWidget
                QMainWindow

Définition

class QMainWindow(QWidget):

Description [extrait de QMainWindow.__doc__]

QMainWindow(self, parent: Optional[PySide6.QtWidgets.QWidget] = None, flags: PySide6.QtCore.Qt.WindowFlags = Default(Qt.WindowFlags)) -> None

Constructeur(s)

Signature du constructeur Description
__new__(*args, **kwargs) Create and return a new object. See help(type) for accurate signature. [extrait de __new__.__doc__]
__init__(self, parent: Optional[PySide6.QtWidgets.QWidget] = None, flags: PySide6.QtCore.Qt.WindowFlags = Default(Qt.WindowFlags)) -> None __init__(self, parent: Optional[PySide6.QtWidgets.QWidget] = None, flags: PySide6.QtCore.Qt.WindowFlags = Default(Qt.WindowFlags)) -> None [extrait de __init__.__doc__]

Liste des attributs statiques

Nom de l'attribut Valeur
AllowNestedDocksPySide6.QtWidgets.QMainWindow.DockOption.AllowNestedDocks
AllowTabbedDocksPySide6.QtWidgets.QMainWindow.DockOption.AllowTabbedDocks
AnimatedDocksPySide6.QtWidgets.QMainWindow.DockOption.AnimatedDocks
DrawChildrenPySide6.QtWidgets.QWidget.RenderFlag.DrawChildren
DrawWindowBackgroundPySide6.QtWidgets.QWidget.RenderFlag.DrawWindowBackground
ForceTabbedDocksPySide6.QtWidgets.QMainWindow.DockOption.ForceTabbedDocks
GroupedDraggingPySide6.QtWidgets.QMainWindow.DockOption.GroupedDragging
IgnoreMaskPySide6.QtWidgets.QWidget.RenderFlag.IgnoreMask
PdmDepthPySide6.QtGui.QPaintDevice.PaintDeviceMetric.PdmDepth
PdmDevicePixelRatioPySide6.QtGui.QPaintDevice.PaintDeviceMetric.PdmDevicePixelRatio
PdmDevicePixelRatioScaledPySide6.QtGui.QPaintDevice.PaintDeviceMetric.PdmDevicePixelRatioScaled
PdmDpiXPySide6.QtGui.QPaintDevice.PaintDeviceMetric.PdmDpiX
PdmDpiYPySide6.QtGui.QPaintDevice.PaintDeviceMetric.PdmDpiY
PdmHeightPySide6.QtGui.QPaintDevice.PaintDeviceMetric.PdmHeight
PdmHeightMMPySide6.QtGui.QPaintDevice.PaintDeviceMetric.PdmHeightMM
PdmNumColorsPySide6.QtGui.QPaintDevice.PaintDeviceMetric.PdmNumColors
PdmPhysicalDpiXPySide6.QtGui.QPaintDevice.PaintDeviceMetric.PdmPhysicalDpiX
PdmPhysicalDpiYPySide6.QtGui.QPaintDevice.PaintDeviceMetric.PdmPhysicalDpiY
PdmWidthPySide6.QtGui.QPaintDevice.PaintDeviceMetric.PdmWidth
PdmWidthMMPySide6.QtGui.QPaintDevice.PaintDeviceMetric.PdmWidthMM
staticMetaObject<PySide6.QtCore.QMetaObject object at 0x7f40e25ce040>
VerticalTabsPySide6.QtWidgets.QMainWindow.DockOption.VerticalTabs

Attributs statiques hérités de la classe QPaintDevice

painters

Liste des opérateurs

Opérateurs hérités de la classe object

__eq__, __ge__, __gt__, __le__, __lt__, __ne__

Liste des méthodes

Toutes les méthodes Méthodes d'instance Méthodes statiques Méthodes dépréciées
Signature de la méthodeDescription
__delattr__(self, name) Implement delattr(self, name). [extrait de __delattr__.__doc__]
__setattr__(self, name, value) Implement setattr(self, name, value). [extrait de __setattr__.__doc__]
addDockWidget addDockWidget(self, area: PySide6.QtCore.Qt.DockWidgetArea, dockwidget: PySide6.QtWidgets.QDockWidget) -> None [extrait de addDockWidget.__doc__]
addToolBar addToolBar(self, area: PySide6.QtCore.Qt.ToolBarArea, toolbar: PySide6.QtWidgets.QToolBar) -> None [extrait de addToolBar.__doc__]
addToolBarBreak(self, area: PySide6.QtCore.Qt.ToolBarArea = PySide6.QtCore.Qt.ToolBarArea.TopToolBarArea) -> None addToolBarBreak(self, area: PySide6.QtCore.Qt.ToolBarArea = PySide6.QtCore.Qt.ToolBarArea.TopToolBarArea) -> None [extrait de addToolBarBreak.__doc__]
centralWidget(self) -> PySide6.QtWidgets.QWidget centralWidget(self) -> PySide6.QtWidgets.QWidget [extrait de centralWidget.__doc__]
contextMenuEvent(self, event: PySide6.QtGui.QContextMenuEvent) -> None contextMenuEvent(self, event: PySide6.QtGui.QContextMenuEvent) -> None [extrait de contextMenuEvent.__doc__]
corner(self, corner: PySide6.QtCore.Qt.Corner) -> PySide6.QtCore.Qt.DockWidgetArea corner(self, corner: PySide6.QtCore.Qt.Corner) -> PySide6.QtCore.Qt.DockWidgetArea [extrait de corner.__doc__]
createPopupMenu(self) -> PySide6.QtWidgets.QMenu createPopupMenu(self) -> PySide6.QtWidgets.QMenu [extrait de createPopupMenu.__doc__]
customContextMenuRequested
destroyed
DockOption
DockOptions
dockOptions(self) -> PySide6.QtWidgets.QMainWindow.DockOptions dockOptions(self) -> PySide6.QtWidgets.QMainWindow.DockOptions [extrait de dockOptions.__doc__]
dockWidgetArea(self, dockwidget: PySide6.QtWidgets.QDockWidget) -> PySide6.QtCore.Qt.DockWidgetArea dockWidgetArea(self, dockwidget: PySide6.QtWidgets.QDockWidget) -> PySide6.QtCore.Qt.DockWidgetArea [extrait de dockWidgetArea.__doc__]
documentMode(self) -> bool documentMode(self) -> bool [extrait de documentMode.__doc__]
event(self, event: PySide6.QtCore.QEvent) -> bool event(self, event: PySide6.QtCore.QEvent) -> bool [extrait de event.__doc__]
iconSize(self) -> PySide6.QtCore.QSize iconSize(self) -> PySide6.QtCore.QSize [extrait de iconSize.__doc__]
iconSizeChanged
insertToolBar(self, before: PySide6.QtWidgets.QToolBar, toolbar: PySide6.QtWidgets.QToolBar) -> None insertToolBar(self, before: PySide6.QtWidgets.QToolBar, toolbar: PySide6.QtWidgets.QToolBar) -> None [extrait de insertToolBar.__doc__]
insertToolBarBreak(self, before: PySide6.QtWidgets.QToolBar) -> None insertToolBarBreak(self, before: PySide6.QtWidgets.QToolBar) -> None [extrait de insertToolBarBreak.__doc__]
isAnimated(self) -> bool isAnimated(self) -> bool [extrait de isAnimated.__doc__]
isDockNestingEnabled(self) -> bool isDockNestingEnabled(self) -> bool [extrait de isDockNestingEnabled.__doc__]
isSeparator(self, pos: PySide6.QtCore.QPoint) -> bool isSeparator(self, pos: PySide6.QtCore.QPoint) -> bool [extrait de isSeparator.__doc__]
menuBar(self) -> PySide6.QtWidgets.QMenuBar menuBar(self) -> PySide6.QtWidgets.QMenuBar [extrait de menuBar.__doc__]
menuWidget(self) -> PySide6.QtWidgets.QWidget menuWidget(self) -> PySide6.QtWidgets.QWidget [extrait de menuWidget.__doc__]
objectNameChanged
removeDockWidget(self, dockwidget: PySide6.QtWidgets.QDockWidget) -> None removeDockWidget(self, dockwidget: PySide6.QtWidgets.QDockWidget) -> None [extrait de removeDockWidget.__doc__]
removeToolBar(self, toolbar: PySide6.QtWidgets.QToolBar) -> None removeToolBar(self, toolbar: PySide6.QtWidgets.QToolBar) -> None [extrait de removeToolBar.__doc__]
removeToolBarBreak(self, before: PySide6.QtWidgets.QToolBar) -> None removeToolBarBreak(self, before: PySide6.QtWidgets.QToolBar) -> None [extrait de removeToolBarBreak.__doc__]
resizeDocks(self, docks: Sequence[PySide6.QtWidgets.QDockWidget], sizes: Sequence[int], orientation: PySide6.QtCore.Qt.Orientation) -> None resizeDocks(self, docks: Sequence[PySide6.QtWidgets.QDockWidget], sizes: Sequence[int], orientation: PySide6.QtCore.Qt.Orientation) -> None [extrait de resizeDocks.__doc__]
restoreDockWidget(self, dockwidget: PySide6.QtWidgets.QDockWidget) -> bool restoreDockWidget(self, dockwidget: PySide6.QtWidgets.QDockWidget) -> bool [extrait de restoreDockWidget.__doc__]
restoreState(self, state: Union[PySide6.QtCore.QByteArray, bytes], version: int = 0) -> bool restoreState(self, state: Union[PySide6.QtCore.QByteArray, bytes], version: int = 0) -> bool [extrait de restoreState.__doc__]
saveState(self, version: int = 0) -> PySide6.QtCore.QByteArray saveState(self, version: int = 0) -> PySide6.QtCore.QByteArray [extrait de saveState.__doc__]
setAnimated(self, enabled: bool) -> None setAnimated(self, enabled: bool) -> None [extrait de setAnimated.__doc__]
setCentralWidget(self, widget: PySide6.QtWidgets.QWidget) -> None setCentralWidget(self, widget: PySide6.QtWidgets.QWidget) -> None [extrait de setCentralWidget.__doc__]
setCorner(self, corner: PySide6.QtCore.Qt.Corner, area: PySide6.QtCore.Qt.DockWidgetArea) -> None setCorner(self, corner: PySide6.QtCore.Qt.Corner, area: PySide6.QtCore.Qt.DockWidgetArea) -> None [extrait de setCorner.__doc__]
setDockNestingEnabled(self, enabled: bool) -> None setDockNestingEnabled(self, enabled: bool) -> None [extrait de setDockNestingEnabled.__doc__]
setDockOptions(self, options: PySide6.QtWidgets.QMainWindow.DockOptions) -> None setDockOptions(self, options: PySide6.QtWidgets.QMainWindow.DockOptions) -> None [extrait de setDockOptions.__doc__]
setDocumentMode(self, enabled: bool) -> None setDocumentMode(self, enabled: bool) -> None [extrait de setDocumentMode.__doc__]
setIconSize(self, iconSize: PySide6.QtCore.QSize) -> None setIconSize(self, iconSize: PySide6.QtCore.QSize) -> None [extrait de setIconSize.__doc__]
setMenuBar(self, menubar: PySide6.QtWidgets.QMenuBar) -> None setMenuBar(self, menubar: PySide6.QtWidgets.QMenuBar) -> None [extrait de setMenuBar.__doc__]
setMenuWidget(self, menubar: PySide6.QtWidgets.QWidget) -> None setMenuWidget(self, menubar: PySide6.QtWidgets.QWidget) -> None [extrait de setMenuWidget.__doc__]
setStatusBar(self, statusbar: PySide6.QtWidgets.QStatusBar) -> None setStatusBar(self, statusbar: PySide6.QtWidgets.QStatusBar) -> None [extrait de setStatusBar.__doc__]
setTabPosition(self, areas: PySide6.QtCore.Qt.DockWidgetAreas, tabPosition: PySide6.QtWidgets.QTabWidget.TabPosition) -> None setTabPosition(self, areas: PySide6.QtCore.Qt.DockWidgetAreas, tabPosition: PySide6.QtWidgets.QTabWidget.TabPosition) -> None [extrait de setTabPosition.__doc__]
setTabShape(self, tabShape: PySide6.QtWidgets.QTabWidget.TabShape) -> None setTabShape(self, tabShape: PySide6.QtWidgets.QTabWidget.TabShape) -> None [extrait de setTabShape.__doc__]
setToolButtonStyle(self, toolButtonStyle: PySide6.QtCore.Qt.ToolButtonStyle) -> None setToolButtonStyle(self, toolButtonStyle: PySide6.QtCore.Qt.ToolButtonStyle) -> None [extrait de setToolButtonStyle.__doc__]
setUnifiedTitleAndToolBarOnMac(self, set: bool) -> None setUnifiedTitleAndToolBarOnMac(self, set: bool) -> None [extrait de setUnifiedTitleAndToolBarOnMac.__doc__]
splitDockWidget(self, after: PySide6.QtWidgets.QDockWidget, dockwidget: PySide6.QtWidgets.QDockWidget, orientation: PySide6.QtCore.Qt.Orientation) -> None splitDockWidget(self, after: PySide6.QtWidgets.QDockWidget, dockwidget: PySide6.QtWidgets.QDockWidget, orientation: PySide6.QtCore.Qt.Orientation) -> None [extrait de splitDockWidget.__doc__]
statusBar(self) -> PySide6.QtWidgets.QStatusBar statusBar(self) -> PySide6.QtWidgets.QStatusBar [extrait de statusBar.__doc__]
tabifiedDockWidgetActivated
tabifiedDockWidgets(self, dockwidget: PySide6.QtWidgets.QDockWidget) -> List[PySide6.QtWidgets.QDockWidget] tabifiedDockWidgets(self, dockwidget: PySide6.QtWidgets.QDockWidget) -> List[PySide6.QtWidgets.QDockWidget] [extrait de tabifiedDockWidgets.__doc__]
tabifyDockWidget(self, first: PySide6.QtWidgets.QDockWidget, second: PySide6.QtWidgets.QDockWidget) -> None tabifyDockWidget(self, first: PySide6.QtWidgets.QDockWidget, second: PySide6.QtWidgets.QDockWidget) -> None [extrait de tabifyDockWidget.__doc__]
tabPosition(self, area: PySide6.QtCore.Qt.DockWidgetArea) -> PySide6.QtWidgets.QTabWidget.TabPosition tabPosition(self, area: PySide6.QtCore.Qt.DockWidgetArea) -> PySide6.QtWidgets.QTabWidget.TabPosition [extrait de tabPosition.__doc__]
tabShape(self) -> PySide6.QtWidgets.QTabWidget.TabShape tabShape(self) -> PySide6.QtWidgets.QTabWidget.TabShape [extrait de tabShape.__doc__]
takeCentralWidget(self) -> PySide6.QtWidgets.QWidget takeCentralWidget(self) -> PySide6.QtWidgets.QWidget [extrait de takeCentralWidget.__doc__]
toolBarArea(self, toolbar: PySide6.QtWidgets.QToolBar) -> PySide6.QtCore.Qt.ToolBarArea toolBarArea(self, toolbar: PySide6.QtWidgets.QToolBar) -> PySide6.QtCore.Qt.ToolBarArea [extrait de toolBarArea.__doc__]
toolBarBreak(self, toolbar: PySide6.QtWidgets.QToolBar) -> bool toolBarBreak(self, toolbar: PySide6.QtWidgets.QToolBar) -> bool [extrait de toolBarBreak.__doc__]
toolButtonStyle(self) -> PySide6.QtCore.Qt.ToolButtonStyle toolButtonStyle(self) -> PySide6.QtCore.Qt.ToolButtonStyle [extrait de toolButtonStyle.__doc__]
toolButtonStyleChanged
tr
unifiedTitleAndToolBarOnMac(self) -> bool unifiedTitleAndToolBarOnMac(self) -> bool [extrait de unifiedTitleAndToolBarOnMac.__doc__]
windowIconChanged
windowIconTextChanged
windowTitleChanged

Méthodes héritées de la classe QWidget

__init_subclass__, __repr__, __subclasshook__, acceptDrops, accessibleDescription, accessibleName, actionEvent, actions, activateWindow, addAction, addActions, adjustSize, autoFillBackground, backgroundRole, backingStore, baseSize, changeEvent, childAt, childrenRect, childrenRegion, clearFocus, clearMask, close, closeEvent, contentsMargins, contentsRect, contextMenuPolicy, create, createWindowContainer, createWinId, cursor, destroy, devType, dragEnterEvent, dragLeaveEvent, dragMoveEvent, dropEvent, effectiveWinId, ensurePolished, enterEvent, find, focusInEvent, focusNextChild, focusNextPrevChild, focusOutEvent, focusPolicy, focusPreviousChild, focusProxy, focusWidget, font, fontInfo, fontMetrics, foregroundRole, frameGeometry, frameSize, geometry, grab, grabGesture, grabKeyboard, grabMouse, grabShortcut, graphicsEffect, graphicsProxyWidget, hasFocus, hasHeightForWidth, hasMouseTracking, hasTabletTracking, height, heightForWidth, hide, hideEvent, initPainter, inputMethodEvent, inputMethodHints, inputMethodQuery, insertAction, insertActions, internalWinId, isActiveWindow, isAncestorOf, isEnabled, isEnabledTo, isFullScreen, isHidden, isLeftToRight, isMaximized, isMinimized, isModal, isRightToLeft, isTopLevel, isVisible, isVisibleTo, isWindow, isWindowModified, keyboardGrabber, keyPressEvent, keyReleaseEvent, layout, layoutDirection, leaveEvent, locale, lower, mapFrom, mapFromGlobal, mapFromParent, mapTo, mapToGlobal, mapToParent, mask, maximumHeight, maximumSize, maximumWidth, metric, minimumHeight, minimumSize, minimumSizeHint, minimumWidth, mouseDoubleClickEvent, mouseGrabber, mouseMoveEvent, mousePressEvent, mouseReleaseEvent, move, moveEvent, nativeEvent, nativeParentWidget, nextInFocusChain, normalGeometry, overrideWindowFlags, overrideWindowState, paintEngine, paintEvent, palette, parentWidget, pos, previousInFocusChain, raise_, rect, redirected, releaseKeyboard, releaseMouse, releaseShortcut, removeAction, render, RenderFlag, RenderFlags, repaint, resize, resizeEvent, restoreGeometry, saveGeometry, screen, scroll, setAcceptDrops, setAccessibleDescription, setAccessibleName, setAttribute, setAutoFillBackground, setBackgroundRole, setBaseSize, setContentsMargins, setContextMenuPolicy, setCursor, setDisabled, setEnabled, setFixedHeight, setFixedSize, setFixedWidth, setFocus, setFocusPolicy, setFocusProxy, setFont, setForegroundRole, setGeometry, setGraphicsEffect, setHidden, setInputMethodHints, setLayout, setLayoutDirection, setLocale, setMask, setMaximumHeight, setMaximumSize, setMaximumWidth, setMinimumHeight, setMinimumSize, setMinimumWidth, setMouseTracking, setPalette, setParent, setScreen, setShortcutAutoRepeat, setShortcutEnabled, setSizeIncrement, setSizePolicy, setStatusTip, setStyle, setStyleSheet, setTabletTracking, setTabOrder, setToolTip, setToolTipDuration, setUpdatesEnabled, setVisible, setWhatsThis, setWindowFilePath, setWindowFlag, setWindowFlags, setWindowIcon, setWindowIconText, setWindowModality, setWindowModified, setWindowOpacity, setWindowRole, setWindowState, setWindowTitle, sharedPainter, show, showEvent, showFullScreen, showMaximized, showMinimized, showNormal, size, sizeHint, sizeIncrement, sizePolicy, stackUnder, statusTip, style, styleSheet, tabletEvent, testAttribute, toolTip, toolTipDuration, topLevelWidget, underMouse, ungrabGesture, unsetCursor, unsetLayoutDirection, unsetLocale, update, updateGeometry, updateMicroFocus, updatesEnabled, visibleRegion, whatsThis, wheelEvent, width, window, windowFilePath, windowFlags, windowHandle, windowIcon, windowIconText, windowModality, windowOpacity, windowRole, windowState, windowTitle, windowType, winId, x, y

Méthodes héritées de la classe QPaintDevice

__init_subclass__, __subclasshook__, colorCount, depth, devicePixelRatio, devicePixelRatioF, devicePixelRatioFScale, devType, height, heightMM, initPainter, logicalDpiX, logicalDpiY, metric, PaintDeviceMetric, paintEngine, paintingActive, physicalDpiX, physicalDpiY, redirected, sharedPainter, width, widthMM

Méthodes héritées de la classe QObject

__getattribute__, __init_subclass__, __repr__, __subclasshook__, blockSignals, childEvent, children, connect, connectNotify, customEvent, deleteLater, disconnect, disconnectNotify, dumpObjectInfo, dumpObjectTree, dynamicPropertyNames, emit, eventFilter, findChild, findChildren, inherits, installEventFilter, isSignalConnected, isWidgetType, isWindowType, killTimer, metaObject, moveToThread, objectName, parent, property, receivers, removeEventFilter, sender, senderSignalIndex, setObjectName, setParent, setProperty, signalsBlocked, startTimer, thread, timerEvent

Méthodes héritées de la classe Object

__getattribute__, __init_subclass__, __subclasshook__

Méthodes héritées de la classe object

__dir__, __format__, __hash__, __reduce__, __reduce_ex__, __repr__, __sizeof__, __str__