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 « QMessageBox »

Informations générales

Héritage

builtins.object
    Object
        QPaintDevice
builtins.object
    Object
        QObject
            QWidget
                QDialog
                    QMessageBox

Définition

class QMessageBox(QDialog):

Description [extrait de QMessageBox.__doc__]

QMessageBox(self, icon: PySide6.QtWidgets.QMessageBox.Icon, title: str, text: str, buttons: PySide6.QtWidgets.QMessageBox.StandardButtons = PySide6.QtWidgets.QMessageBox.StandardButton.NoButton, parent: Optional[PySide6.QtWidgets.QWidget] = None, flags: PySide6.QtCore.Qt.WindowFlags = Instance(Qt.Dialog | Qt.MSWindowsFixedSizeDialogHint)) -> None
QMessageBox(self, parent: Optional[PySide6.QtWidgets.QWidget] = None) -> 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__]

Liste des attributs statiques

Nom de l'attribut Valeur
AbortPySide6.QtWidgets.QMessageBox.StandardButton.Abort
AcceptedPySide6.QtWidgets.QDialog.DialogCode.Accepted
AcceptRolePySide6.QtWidgets.QMessageBox.ButtonRole.AcceptRole
ActionRolePySide6.QtWidgets.QMessageBox.ButtonRole.ActionRole
ApplyPySide6.QtWidgets.QMessageBox.StandardButton.Apply
ApplyRolePySide6.QtWidgets.QMessageBox.ButtonRole.ApplyRole
ButtonMaskPySide6.QtWidgets.QMessageBox.StandardButton.ButtonMask
CancelPySide6.QtWidgets.QMessageBox.StandardButton.Cancel
ClosePySide6.QtWidgets.QMessageBox.StandardButton.Close
CriticalPySide6.QtWidgets.QMessageBox.Icon.Critical
DefaultPySide6.QtWidgets.QMessageBox.StandardButton.Default
DestructiveRolePySide6.QtWidgets.QMessageBox.ButtonRole.DestructiveRole
DiscardPySide6.QtWidgets.QMessageBox.StandardButton.Discard
DrawChildrenPySide6.QtWidgets.QWidget.RenderFlag.DrawChildren
DrawWindowBackgroundPySide6.QtWidgets.QWidget.RenderFlag.DrawWindowBackground
EscapePySide6.QtWidgets.QMessageBox.StandardButton.Escape
FirstButtonPySide6.QtWidgets.QMessageBox.StandardButton.FirstButton
FlagMaskPySide6.QtWidgets.QMessageBox.StandardButton.FlagMask
HelpPySide6.QtWidgets.QMessageBox.StandardButton.Help
HelpRolePySide6.QtWidgets.QMessageBox.ButtonRole.HelpRole
IgnorePySide6.QtWidgets.QMessageBox.StandardButton.Ignore
IgnoreMaskPySide6.QtWidgets.QWidget.RenderFlag.IgnoreMask
InformationPySide6.QtWidgets.QMessageBox.Icon.Information
InvalidRolePySide6.QtWidgets.QMessageBox.ButtonRole.InvalidRole
LastButtonPySide6.QtWidgets.QMessageBox.StandardButton.LastButton
NoPySide6.QtWidgets.QMessageBox.StandardButton.No
NoAllPySide6.QtWidgets.QMessageBox.StandardButton.NoAll
NoButtonPySide6.QtWidgets.QMessageBox.StandardButton.NoButton
NoIconPySide6.QtWidgets.QMessageBox.Icon.NoIcon
NoRolePySide6.QtWidgets.QMessageBox.ButtonRole.NoRole
NoToAllPySide6.QtWidgets.QMessageBox.StandardButton.NoToAll
NRolesPySide6.QtWidgets.QMessageBox.ButtonRole.NRoles
OkPySide6.QtWidgets.QMessageBox.StandardButton.Ok
OpenPySide6.QtWidgets.QMessageBox.StandardButton.Open
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
QuestionPySide6.QtWidgets.QMessageBox.Icon.Question
RejectedPySide6.QtWidgets.QDialog.DialogCode.Rejected
RejectRolePySide6.QtWidgets.QMessageBox.ButtonRole.RejectRole
ResetPySide6.QtWidgets.QMessageBox.StandardButton.Reset
ResetRolePySide6.QtWidgets.QMessageBox.ButtonRole.ResetRole
RestoreDefaultsPySide6.QtWidgets.QMessageBox.StandardButton.RestoreDefaults
RetryPySide6.QtWidgets.QMessageBox.StandardButton.Retry
SavePySide6.QtWidgets.QMessageBox.StandardButton.Save
SaveAllPySide6.QtWidgets.QMessageBox.StandardButton.SaveAll
staticMetaObject<PySide6.QtCore.QMetaObject object at 0x7f40dfe0ae40>
WarningPySide6.QtWidgets.QMessageBox.Icon.Warning
YesPySide6.QtWidgets.QMessageBox.StandardButton.Yes
YesAllPySide6.QtWidgets.QMessageBox.StandardButton.YesAll
YesRolePySide6.QtWidgets.QMessageBox.ButtonRole.YesRole
YesToAllPySide6.QtWidgets.QMessageBox.StandardButton.YesToAll

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__]
about(parent: PySide6.QtWidgets.QWidget, title: str, text: str) -> None about(parent: PySide6.QtWidgets.QWidget, title: str, text: str) -> None [extrait de about.__doc__]
aboutQt(parent: PySide6.QtWidgets.QWidget, title: str = '') -> None aboutQt(parent: PySide6.QtWidgets.QWidget, title: str = '') -> None [extrait de aboutQt.__doc__]
accepted
addButton addButton(self, button: PySide6.QtWidgets.QAbstractButton, role: PySide6.QtWidgets.QMessageBox.ButtonRole) -> None [extrait de addButton.__doc__]
button(self, which: PySide6.QtWidgets.QMessageBox.StandardButton) -> PySide6.QtWidgets.QAbstractButton button(self, which: PySide6.QtWidgets.QMessageBox.StandardButton) -> PySide6.QtWidgets.QAbstractButton [extrait de button.__doc__]
buttonClicked
ButtonRole
buttonRole(self, button: PySide6.QtWidgets.QAbstractButton) -> PySide6.QtWidgets.QMessageBox.ButtonRole buttonRole(self, button: PySide6.QtWidgets.QAbstractButton) -> PySide6.QtWidgets.QMessageBox.ButtonRole [extrait de buttonRole.__doc__]
buttons(self) -> List[PySide6.QtWidgets.QAbstractButton] buttons(self) -> List[PySide6.QtWidgets.QAbstractButton] [extrait de buttons.__doc__]
buttonText(self, button: int) -> str buttonText(self, button: int) -> str [extrait de buttonText.__doc__]
changeEvent(self, event: PySide6.QtCore.QEvent) -> None changeEvent(self, event: PySide6.QtCore.QEvent) -> None [extrait de changeEvent.__doc__]
checkBox(self) -> PySide6.QtWidgets.QCheckBox checkBox(self) -> PySide6.QtWidgets.QCheckBox [extrait de checkBox.__doc__]
clickedButton(self) -> PySide6.QtWidgets.QAbstractButton clickedButton(self) -> PySide6.QtWidgets.QAbstractButton [extrait de clickedButton.__doc__]
closeEvent(self, event: PySide6.QtGui.QCloseEvent) -> None closeEvent(self, event: PySide6.QtGui.QCloseEvent) -> None [extrait de closeEvent.__doc__]
critical critical(parent: PySide6.QtWidgets.QWidget, title: str, text: str, button0: PySide6.QtWidgets.QMessageBox.StandardButton, button1: PySide6.QtWidgets.QMessageBox.StandardButton) -> int [extrait de critical.__doc__]
customContextMenuRequested
defaultButton(self) -> PySide6.QtWidgets.QPushButton defaultButton(self) -> PySide6.QtWidgets.QPushButton [extrait de defaultButton.__doc__]
destroyed
detailedText(self) -> str detailedText(self) -> str [extrait de detailedText.__doc__]
escapeButton(self) -> PySide6.QtWidgets.QAbstractButton escapeButton(self) -> PySide6.QtWidgets.QAbstractButton [extrait de escapeButton.__doc__]
event(self, e: PySide6.QtCore.QEvent) -> bool event(self, e: PySide6.QtCore.QEvent) -> bool [extrait de event.__doc__]
finished
Icon
icon(self) -> PySide6.QtWidgets.QMessageBox.Icon icon(self) -> PySide6.QtWidgets.QMessageBox.Icon [extrait de icon.__doc__]
iconPixmap(self) -> PySide6.QtGui.QPixmap iconPixmap(self) -> PySide6.QtGui.QPixmap [extrait de iconPixmap.__doc__]
information information(parent: PySide6.QtWidgets.QWidget, title: str, text: str, button0: PySide6.QtWidgets.QMessageBox.StandardButton, button1: PySide6.QtWidgets.QMessageBox.StandardButton = PySide6.QtWidgets.QMessageBox.StandardButton.NoButton) -> PySide6.QtWidgets.QMessageBox.StandardButton [extrait de information.__doc__]
informativeText(self) -> str informativeText(self) -> str [extrait de informativeText.__doc__]
keyPressEvent(self, event: PySide6.QtGui.QKeyEvent) -> None keyPressEvent(self, event: PySide6.QtGui.QKeyEvent) -> None [extrait de keyPressEvent.__doc__]
objectNameChanged
open open(self) -> None [extrait de open.__doc__]
question question(parent: PySide6.QtWidgets.QWidget, title: str, text: str, button0: PySide6.QtWidgets.QMessageBox.StandardButton, button1: PySide6.QtWidgets.QMessageBox.StandardButton) -> int [extrait de question.__doc__]
rejected
removeButton(self, button: PySide6.QtWidgets.QAbstractButton) -> None removeButton(self, button: PySide6.QtWidgets.QAbstractButton) -> None [extrait de removeButton.__doc__]
resizeEvent(self, event: PySide6.QtGui.QResizeEvent) -> None resizeEvent(self, event: PySide6.QtGui.QResizeEvent) -> None [extrait de resizeEvent.__doc__]
setButtonText(self, button: int, text: str) -> None setButtonText(self, button: int, text: str) -> None [extrait de setButtonText.__doc__]
setCheckBox(self, cb: PySide6.QtWidgets.QCheckBox) -> None setCheckBox(self, cb: PySide6.QtWidgets.QCheckBox) -> None [extrait de setCheckBox.__doc__]
setDefaultButton setDefaultButton(self, button: PySide6.QtWidgets.QMessageBox.StandardButton) -> None [extrait de setDefaultButton.__doc__]
setDetailedText(self, text: str) -> None setDetailedText(self, text: str) -> None [extrait de setDetailedText.__doc__]
setEscapeButton setEscapeButton(self, button: PySide6.QtWidgets.QAbstractButton) -> None [extrait de setEscapeButton.__doc__]
setIcon(self, arg__1: PySide6.QtWidgets.QMessageBox.Icon) -> None setIcon(self, arg__1: PySide6.QtWidgets.QMessageBox.Icon) -> None [extrait de setIcon.__doc__]
setIconPixmap(self, pixmap: Union[PySide6.QtGui.QPixmap, PySide6.QtGui.QImage, str]) -> None setIconPixmap(self, pixmap: Union[PySide6.QtGui.QPixmap, PySide6.QtGui.QImage, str]) -> None [extrait de setIconPixmap.__doc__]
setInformativeText(self, text: str) -> None setInformativeText(self, text: str) -> None [extrait de setInformativeText.__doc__]
setStandardButtons(self, buttons: PySide6.QtWidgets.QMessageBox.StandardButtons) -> None setStandardButtons(self, buttons: PySide6.QtWidgets.QMessageBox.StandardButtons) -> None [extrait de setStandardButtons.__doc__]
setText(self, text: str) -> None setText(self, text: str) -> None [extrait de setText.__doc__]
setTextFormat(self, format: PySide6.QtCore.Qt.TextFormat) -> None setTextFormat(self, format: PySide6.QtCore.Qt.TextFormat) -> None [extrait de setTextFormat.__doc__]
setTextInteractionFlags(self, flags: PySide6.QtCore.Qt.TextInteractionFlags) -> None setTextInteractionFlags(self, flags: PySide6.QtCore.Qt.TextInteractionFlags) -> None [extrait de setTextInteractionFlags.__doc__]
setWindowModality(self, windowModality: PySide6.QtCore.Qt.WindowModality) -> None setWindowModality(self, windowModality: PySide6.QtCore.Qt.WindowModality) -> None [extrait de setWindowModality.__doc__]
setWindowTitle(self, title: str) -> None setWindowTitle(self, title: str) -> None [extrait de setWindowTitle.__doc__]
showEvent(self, event: PySide6.QtGui.QShowEvent) -> None showEvent(self, event: PySide6.QtGui.QShowEvent) -> None [extrait de showEvent.__doc__]
StandardButton
standardButton(self, button: PySide6.QtWidgets.QAbstractButton) -> PySide6.QtWidgets.QMessageBox.StandardButton standardButton(self, button: PySide6.QtWidgets.QAbstractButton) -> PySide6.QtWidgets.QMessageBox.StandardButton [extrait de standardButton.__doc__]
StandardButtons
standardButtons(self) -> PySide6.QtWidgets.QMessageBox.StandardButtons standardButtons(self) -> PySide6.QtWidgets.QMessageBox.StandardButtons [extrait de standardButtons.__doc__]
standardIcon(icon: PySide6.QtWidgets.QMessageBox.Icon) -> PySide6.QtGui.QPixmap standardIcon(icon: PySide6.QtWidgets.QMessageBox.Icon) -> PySide6.QtGui.QPixmap [extrait de standardIcon.__doc__]
text(self) -> str text(self) -> str [extrait de text.__doc__]
textFormat(self) -> PySide6.QtCore.Qt.TextFormat textFormat(self) -> PySide6.QtCore.Qt.TextFormat [extrait de textFormat.__doc__]
textInteractionFlags(self) -> PySide6.QtCore.Qt.TextInteractionFlags textInteractionFlags(self) -> PySide6.QtCore.Qt.TextInteractionFlags [extrait de textInteractionFlags.__doc__]
tr
warning warning(parent: PySide6.QtWidgets.QWidget, title: str, text: str, button0: PySide6.QtWidgets.QMessageBox.StandardButton, button1: PySide6.QtWidgets.QMessageBox.StandardButton) -> int [extrait de warning.__doc__]
windowIconChanged
windowIconTextChanged
windowTitleChanged

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

__init_subclass__, __subclasshook__, accept, adjustPosition, contextMenuEvent, DialogCode, done, eventFilter, exec, exec_, isSizeGripEnabled, minimumSizeHint, reject, result, setModal, setResult, setSizeGripEnabled, setVisible, sizeHint

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, childAt, childrenRect, childrenRegion, clearFocus, clearMask, close, contentsMargins, contentsRect, contextMenuEvent, 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, 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, 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, setWindowModified, setWindowOpacity, setWindowRole, setWindowState, sharedPainter, show, 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__