QChildWindowEvent Class

Die Klasse QChildWindowEvent enthält Ereignisparameter für Kindfensterwechsel. Mehr...

Kopfzeile: #include <QChildWindowEvent>
CMake: find_package(Qt6 REQUIRED COMPONENTS Gui)
target_link_libraries(mytarget PRIVATE Qt6::Gui)
qmake: QT += gui
Seit: Qt 6.7
Vererbt: QEvent

Öffentliche Funktionen

QChildWindowEvent(QEvent::Type type, QWindow *childWindow)
QWindow *child() const

Detaillierte Beschreibung

Kindfenster-Ereignisse werden an Fenster gesendet, wenn Kinder hinzugefügt oder entfernt werden.

In beiden Fällen kann man sich nur darauf verlassen, dass das Kind eine QWindow ist - nicht irgendeine Unterklasse davon. Das liegt daran, dass im Fall von QEvent::ChildWindowAdded die Unterklasse noch nicht vollständig konstruiert ist, und im Fall von QEvent::ChildWindowRemoved könnte sie bereits zerstört worden sein.

Dokumentation der Mitgliedsfunktionen

[explicit] QChildWindowEvent::QChildWindowEvent(QEvent::Type type, QWindow *childWindow)

Konstruiert ein Kind-Fenster-Ereignisobjekt eines bestimmten type für die childWindow.

type kann QEvent::ChildWindowAdded oder QEvent::ChildWindowRemoved sein.

Siehe auch child().

QWindow *QChildWindowEvent::child() const

Gibt das hinzugefügte oder entfernte untergeordnete Fenster zurück.

© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.