Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
|
\qmltype XdgToplevel \nativetype QWaylandXdgToplevel \inqmlmodule QtWayland.Compositor.XdgShell More...
#include <qwaylandxdgshell.h>
Public Types | |
enum | State : uint { MaximizedState = 1 , FullscreenState = 2 , ResizingState = 3 , ActivatedState = 4 } |
enum | DecorationMode { ClientSideDecoration = 1 , ServerSideDecoration = 2 } |
This enum type is used to specify the window decoration mode for toplevel windows. More... | |
Signals | |
void | parentToplevelChanged () |
void | titleChanged () |
void | appIdChanged () |
void | maxSizeChanged () |
void | minSizeChanged () |
void | startMove (QWaylandSeat *seat) |
void | startResize (QWaylandSeat *seat, Qt::Edges edges) |
void | statesChanged () |
void | maximizedChanged () |
void | fullscreenChanged () |
void | resizingChanged () |
void | activatedChanged () |
void | showWindowMenu (QWaylandSeat *seat, const QPoint &localSurfacePosition) |
void | setMaximized () |
void | unsetMaximized () |
void | setFullscreen (QWaylandOutput *output) |
void | unsetFullscreen () |
void | setMinimized () |
void | decorationModeChanged () |
Q_REVISION (6, 8) void modalChanged() | |
Signals inherited from QObject | |
void | destroyed (QObject *=nullptr) |
This signal is emitted immediately before the object obj is destroyed, after any instances of QPointer have been notified, and cannot be blocked. | |
void | objectNameChanged (const QString &objectName, QPrivateSignal) |
This signal is emitted after the object's name has been changed. | |
Public Member Functions | |
QWaylandXdgToplevel (QWaylandXdgSurface *xdgSurface, QWaylandResource &resource) | |
Constructs a QWaylandXdgToplevel for the given xdgSurface and resource. | |
~QWaylandXdgToplevel () override | |
QWaylandXdgSurface * | xdgSurface () const |
QWaylandXdgToplevel * | parentToplevel () const |
QString | title () const |
QString | appId () const |
QSize | maxSize () const |
QSize | minSize () const |
QList< QWaylandXdgToplevel::State > | states () const |
bool | maximized () const |
bool | fullscreen () const |
bool | resizing () const |
bool | activated () const |
DecorationMode | decorationMode () const |
Q_INVOKABLE QSize | sizeForResize (const QSizeF &size, const QPointF &delta, Qt::Edges edges) const |
\qmlmethod size XdgToplevel::sizeForResize(size size, point delta, uint edges) | |
uint | sendConfigure (const QSize &size, const QList< State > &states) |
Q_INVOKABLE uint | sendConfigure (const QSize &size, const QList< int > &states) |
\qmlmethod int XdgToplevel::sendConfigure(size size, list<int> states) | |
Q_INVOKABLE void | sendClose () |
\qmlmethod void XdgToplevel::sendClose() | |
Q_INVOKABLE uint | sendMaximized (const QSize &size) |
\qmlmethod void XdgToplevel::sendMaximized(size size) | |
Q_INVOKABLE uint | sendUnmaximized (const QSize &size=QSize(0, 0)) |
\qmlmethod void XdgToplevel::sendUnmaximized(size size) | |
Q_INVOKABLE uint | sendFullscreen (const QSize &size) |
\qmlmethod void XdgToplevel::sendFullscreen(size size) | |
Q_INVOKABLE uint | sendResizing (const QSize &maxSize) |
\qmlmethod void XdgToplevel::sendResizing(size maxSize) | |
bool | isModal () const |
Public Member Functions inherited from QObject | |
Q_INVOKABLE | QObject (QObject *parent=nullptr) |
Constructs an object with parent object parent. | |
virtual | ~QObject () |
Destroys the object, deleting all its child objects. | |
virtual bool | event (QEvent *event) |
This virtual function receives events to an object and should return true if the event e was recognized and processed. | |
virtual bool | eventFilter (QObject *watched, QEvent *event) |
Filters events if this object has been installed as an event filter for the watched object. | |
QString | objectName () const |
Q_WEAK_OVERLOAD void | setObjectName (const QString &name) |
Sets the object's name to name. | |
void | setObjectName (QAnyStringView name) |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. | |
QBindable< QString > | bindableObjectName () |
bool | isWidgetType () const |
Returns true if the object is a widget; otherwise returns false . | |
bool | isWindowType () const |
Returns true if the object is a window; otherwise returns false . | |
bool | isQuickItemType () const |
Returns true if the object is a QQuickItem; otherwise returns false . | |
bool | signalsBlocked () const noexcept |
Returns true if signals are blocked; otherwise returns false . | |
bool | blockSignals (bool b) noexcept |
If block is true, signals emitted by this object are blocked (i.e., emitting a signal will not invoke anything connected to it). | |
QThread * | thread () const |
Returns the thread in which the object lives. | |
bool | moveToThread (QThread *thread QT6_DECL_NEW_OVERLOAD_TAIL) |
Changes the thread affinity for this object and its children and returns true on success. | |
int | startTimer (int interval, Qt::TimerType timerType=Qt::CoarseTimer) |
This is an overloaded function that will start a timer of type timerType and a timeout of interval milliseconds. | |
int | startTimer (std::chrono::nanoseconds time, Qt::TimerType timerType=Qt::CoarseTimer) |
void | killTimer (int id) |
Kills the timer with timer identifier, id. | |
void | killTimer (Qt::TimerId id) |
template<typename T > | |
T | findChild (QAnyStringView aName, Qt::FindChildOptions options=Qt::FindChildrenRecursively) const |
Returns the child of this object that can be cast into type T and that is called name, or \nullptr if there is no such object. | |
template<typename T > | |
QList< T > | findChildren (QAnyStringView aName, Qt::FindChildOptions options=Qt::FindChildrenRecursively) const |
Returns all children of this object with the given name that can be cast to type T, or an empty list if there are no such objects. | |
template<typename T > | |
T | findChild (Qt::FindChildOptions options=Qt::FindChildrenRecursively) const |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. | |
template<typename T > | |
QList< T > | findChildren (Qt::FindChildOptions options=Qt::FindChildrenRecursively) const |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. | |
const QObjectList & | children () const |
Returns a list of child objects. | |
void | setParent (QObject *parent) |
Makes the object a child of parent. | |
void | installEventFilter (QObject *filterObj) |
Installs an event filter filterObj on this object. | |
void | removeEventFilter (QObject *obj) |
Removes an event filter object obj from this object. | |
QMetaObject::Connection | connect (const QObject *sender, const char *signal, const char *member, Qt::ConnectionType type=Qt::AutoConnection) const |
bool | disconnect (const char *signal=nullptr, const QObject *receiver=nullptr, const char *member=nullptr) const |
bool | disconnect (const QObject *receiver, const char *member=nullptr) const |
void | dumpObjectTree () const |
Dumps a tree of children to the debug output. | |
void | dumpObjectInfo () const |
Dumps information about signal connections, etc. | |
bool | setProperty (const char *name, const QVariant &value) |
Sets the value of the object's name property to value. | |
bool | setProperty (const char *name, QVariant &&value) |
QVariant | property (const char *name) const |
Returns the value of the object's name property. | |
QList< QByteArray > | dynamicPropertyNames () const |
QBindingStorage * | bindingStorage () |
const QBindingStorage * | bindingStorage () const |
QObject * | parent () const |
Returns a pointer to the parent object. | |
bool | inherits (const char *classname) const |
Returns true if this object is an instance of a class that inherits className or a QObject subclass that inherits className; otherwise returns false . | |
Static Public Member Functions | |
static QWaylandSurfaceRole * | role () |
Returns the surface role for the QWaylandToplevel. | |
static QWaylandXdgToplevel * | fromResource (::wl_resource *resource) |
Returns the QWaylandXdgToplevel corresponding to the resource. | |
Static Public Member Functions inherited from QObject | |
static QMetaObject::Connection | connect (const QObject *sender, const char *signal, const QObject *receiver, const char *member, Qt::ConnectionType=Qt::AutoConnection) |
\threadsafe | |
static QMetaObject::Connection | connect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method, Qt::ConnectionType type=Qt::AutoConnection) |
template<typename Func1 , typename Func2 > | |
static QMetaObject::Connection | connect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const typename QtPrivate::ContextTypeForFunctor< Func2 >::ContextType *context, Func2 &&slot, Qt::ConnectionType type=Qt::AutoConnection) |
template<typename Func1 , typename Func2 > | |
static QMetaObject::Connection | connect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, Func2 &&slot) |
static bool | disconnect (const QObject *sender, const char *signal, const QObject *receiver, const char *member) |
\threadsafe | |
static bool | disconnect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &member) |
static bool | disconnect (const QMetaObject::Connection &) |
Disconnect a connection. | |
template<typename Func1 , typename Func2 > | |
static bool | disconnect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const typename QtPrivate::FunctionPointer< Func2 >::Object *receiver, Func2 slot) |
template<typename Func1 > | |
static bool | disconnect (const typename QtPrivate::FunctionPointer< Func1 >::Object *sender, Func1 signal, const QObject *receiver, void **zero) |
Properties | |
QWaylandXdgSurface * | xdgSurface |
\qmlproperty XdgSurface XdgToplevel::xdgSurface | |
QWaylandXdgToplevel * | parentToplevel |
\qmlproperty XdgToplevel XdgToplevel::parentToplevel | |
QString | title |
\qmlproperty string XdgToplevel::title | |
QString | appId |
\qmlproperty string XdgToplevel::appId | |
QSize | maxSize |
\qmlproperty size XdgToplevel::maxSize | |
QSize | minSize |
\qmlproperty size XdgToplevel::minSize | |
QList< int > | states |
This property holds the last states the client acknowledged for this QWaylandToplevel. | |
bool | maximized |
\qmlproperty bool XdgToplevel::maximized | |
bool | fullscreen |
\qmlproperty bool XdgToplevel::fullscreen | |
bool | resizing |
\qmlproperty bool XdgToplevel::resizing | |
bool | activated |
\qmlproperty bool XdgToplevel::activated | |
bool | modal |
\qmlproperty bool XdgToplevel::modal | |
enum DecorationMode | decorationMode |
\qmlproperty enumeration XdgToplevel::decorationMode | |
Properties inherited from QObject | |
QString | objectName |
the name of this object | |
Friends | |
class | QWaylandXdgDialogV1 |
Additional Inherited Members | |
Public Slots inherited from QObject | |
void | deleteLater () |
\threadsafe | |
Protected Member Functions inherited from QObject | |
QObject * | sender () const |
Returns a pointer to the object that sent the signal, if called in a slot activated by a signal; otherwise it returns \nullptr. | |
int | senderSignalIndex () const |
int | receivers (const char *signal) const |
Returns the number of receivers connected to the signal. | |
bool | isSignalConnected (const QMetaMethod &signal) const |
virtual void | timerEvent (QTimerEvent *event) |
This event handler can be reimplemented in a subclass to receive timer events for the object. | |
virtual void | childEvent (QChildEvent *event) |
This event handler can be reimplemented in a subclass to receive child events. | |
virtual void | customEvent (QEvent *event) |
This event handler can be reimplemented in a subclass to receive custom events. | |
virtual void | connectNotify (const QMetaMethod &signal) |
virtual void | disconnectNotify (const QMetaMethod &signal) |
QObject (QObjectPrivate &dd, QObject *parent=nullptr) | |
Protected Attributes inherited from QObject | |
QScopedPointer< QObjectData > | d_ptr |
Related Symbols inherited from QObject | |
template< class T > T | qobject_cast (const QObject *object) |
Returns the given object cast to type T if the object is of type T (or of a subclass); otherwise returns \nullptr. | |
template< typename T > T | qFindChildqFindChildren (const QObject *obj, const QString &name)() |
template< typename T > QList< T > | qFindChildrenqFindChildren (const QObject *obj, const QString &name)() |
QObjectList | |
\macro Q_CLASSINFO(Name, Value) | |
\qmltype XdgToplevel \nativetype QWaylandXdgToplevel \inqmlmodule QtWayland.Compositor.XdgShell
XdgToplevel represents the toplevel window specific parts of an xdg surface.
This type is part of the \l{XdgShell} extension and provides a way to extend the functionality of an XdgSurface with features specific to desktop-style windows.
It corresponds to the Wayland interface xdg_toplevel
.
\inmodule QtWaylandCompositor
The QWaylandXdgToplevel class represents the toplevel window specific parts of an xdg surface.
This class is part of the QWaylandXdgShell extension and provides a way to extend the functionality of an QWaylandXdgSurface with features specific to desktop-style windows.
It corresponds to the Wayland interface xdg_toplevel
.
Definition at line 114 of file qwaylandxdgshell.h.
This enum type is used to specify the window decoration mode for toplevel windows.
\value ServerSideDecoration The compositor should draw window decorations. \value ClientSideDecoration The client should draw window decorations.
Enumerator | |
---|---|
ClientSideDecoration | |
ServerSideDecoration |
Definition at line 141 of file qwaylandxdgshell.h.
enum QWaylandXdgToplevel::State : uint |
Enumerator | |
---|---|
MaximizedState | |
FullscreenState | |
ResizingState | |
ActivatedState |
Definition at line 133 of file qwaylandxdgshell.h.
|
explicit |
Constructs a QWaylandXdgToplevel for the given xdgSurface and resource.
Definition at line 711 of file qwaylandxdgshell.cpp.
|
override |
Definition at line 718 of file qwaylandxdgshell.cpp.
bool QWaylandXdgToplevel::activated | ( | ) | const |
Definition at line 912 of file qwaylandxdgshell.cpp.
|
signal |
QString QWaylandXdgToplevel::appId | ( | ) | const |
Definition at line 791 of file qwaylandxdgshell.cpp.
|
signal |
QWaylandXdgToplevel::DecorationMode QWaylandXdgToplevel::decorationMode | ( | ) | const |
Definition at line 974 of file qwaylandxdgshell.cpp.
|
signal |
|
static |
Returns the QWaylandXdgToplevel corresponding to the resource.
Definition at line 1195 of file qwaylandxdgshell.cpp.
bool QWaylandXdgToplevel::fullscreen | ( | ) | const |
Definition at line 878 of file qwaylandxdgshell.cpp.
|
signal |
bool QWaylandXdgToplevel::isModal | ( | ) | const |
Definition at line 931 of file qwaylandxdgshell.cpp.
bool QWaylandXdgToplevel::maximized | ( | ) | const |
Definition at line 861 of file qwaylandxdgshell.cpp.
|
signal |
QSize QWaylandXdgToplevel::maxSize | ( | ) | const |
Definition at line 812 of file qwaylandxdgshell.cpp.
|
signal |
QSize QWaylandXdgToplevel::minSize | ( | ) | const |
Definition at line 833 of file qwaylandxdgshell.cpp.
|
signal |
QWaylandXdgToplevel * QWaylandXdgToplevel::parentToplevel | ( | ) | const |
Definition at line 757 of file qwaylandxdgshell.cpp.
|
signal |
|
signal |
bool QWaylandXdgToplevel::resizing | ( | ) | const |
Definition at line 895 of file qwaylandxdgshell.cpp.
|
signal |
|
static |
Returns the surface role for the QWaylandToplevel.
Definition at line 1187 of file qwaylandxdgshell.cpp.
void QWaylandXdgToplevel::sendClose | ( | ) |
\qmlmethod void XdgToplevel::sendClose()
Sends a close event to the client. The client may choose to ignore the event.
Sends a close event to the client. The client may choose to ignore the event.
Definition at line 1060 of file qwaylandxdgshell.cpp.
\qmlmethod int XdgToplevel::sendConfigure(size size, list<int> states)
Sends a configure event to the client. size contains the pixel size of the surface. A size of zero means the client is free to decide the size. Known states are enumerated in XdgToplevel::State.
Definition at line 1043 of file qwaylandxdgshell.cpp.
\qmlmethod void XdgToplevel::sendFullscreen(size size)
Convenience for sending a configure event with the fullscreen state set, and maximized and resizing removed. The activated state is left in its current state.
size is the new size of the window.
Convenience for sending a configure event with the fullscreen state set, and maximized and resizing removed. The activated state is left in its current state.
size is the new size of the window.
Definition at line 1143 of file qwaylandxdgshell.cpp.
\qmlmethod void XdgToplevel::sendMaximized(size size)
Convenience for sending a configure event with the maximized state set, and fullscreen and resizing removed. The activated state is left in its current state.
size is the new size of the window.
Convenience for sending a configure event with the maximized state set, and fullscreen and resizing removed. The activated state is left in its current state.
size is the new size of the window.
Definition at line 1081 of file qwaylandxdgshell.cpp.
\qmlmethod void XdgToplevel::sendResizing(size maxSize)
Convenience for sending a configure event with the resizing state set, and maximized and fullscreen removed. The activated state is left in its current state.
maxSize is the new size of the window.
Convenience for sending a configure event with the resizing state set, and maximized and fullscreen removed. The activated state is left in its current state.
maxSize is the new size of the window.
Definition at line 1171 of file qwaylandxdgshell.cpp.
\qmlmethod void XdgToplevel::sendUnmaximized(size size)
Convenience for sending a configure event with the maximized, fullscreen and resizing states removed, and fullscreen and resizing removed. The activated state is left in its current state.
size is the new size of the window. If size is zero, the client decides the size.
Convenience for sending a configure event with the maximized, fullscreen and resizing states removed, and fullscreen and resizing removed. The activated state is left in its current state.
size is the new size of the window. If size is zero, the client decides the size.
Definition at line 1111 of file qwaylandxdgshell.cpp.
|
signal |
|
signal |
|
signal |
|
signal |
QSize QWaylandXdgToplevel::sizeForResize | ( | const QSizeF & | size, |
const QPointF & | delta, | ||
Qt::Edges | edges ) const |
\qmlmethod size XdgToplevel::sizeForResize(size size, point delta, uint edges)
Convenience for computing the new size given the current size, a delta, and the edges active in the drag.
Convenience for computing the new size given the current size, a delta, and the edges active in the drag.
Definition at line 991 of file qwaylandxdgshell.cpp.
|
signal |
|
signal |
QList< QWaylandXdgToplevel::State > QWaylandXdgToplevel::states | ( | ) | const |
Definition at line 844 of file qwaylandxdgshell.cpp.
|
signal |
QString QWaylandXdgToplevel::title | ( | ) | const |
Definition at line 774 of file qwaylandxdgshell.cpp.
|
signal |
|
signal |
|
signal |
QWaylandXdgSurface * QWaylandXdgToplevel::xdgSurface | ( | ) | const |
Definition at line 739 of file qwaylandxdgshell.cpp.
|
friend |
Definition at line 206 of file qwaylandxdgshell.h.
|
read |
\qmlproperty bool XdgToplevel::activated
This property holds whether toplevel is drawing itself as having input focus.
This property holds whether toplevel is drawing itself as having input focus.
Definition at line 128 of file qwaylandxdgshell.h.
|
read |
\qmlproperty string XdgToplevel::appId
This property holds the app id of the XdgToplevel.
This property holds the app id of the QWaylandXdgToplevel.
Definition at line 121 of file qwaylandxdgshell.h.
|
read |
\qmlproperty enumeration XdgToplevel::decorationMode
This property holds the current window decoration mode for this toplevel.
The possible values are: \value XdgToplevel.ServerSideDecoration The compositor should draw window decorations. \value XdgToplevel.ClientSideDecoration The client should draw window decorations.
This property holds the current window decoration mode for this toplevel.
Definition at line 130 of file qwaylandxdgshell.h.
|
read |
\qmlproperty bool XdgToplevel::fullscreen
This property holds whether the client has acknowledged that it should be fullscreen.
This property holds whether the client has acknowledged that it should be fullscreen.
Definition at line 126 of file qwaylandxdgshell.h.
|
read |
\qmlproperty bool XdgToplevel::maximized
This property holds whether the client has acknowledged that it should be maximized.
This property holds whether the client has acknowledged that it should be maximized.
Definition at line 125 of file qwaylandxdgshell.h.
|
read |
\qmlproperty size XdgToplevel::maxSize
This property holds the maximum size of the XdgToplevel as requested by the client.
The compositor is free to ignore this value and request a larger size.
This property holds the maximum size of the QWaylandXdgToplevel.
The compositor is free to ignore this value and request a larger size.
Definition at line 122 of file qwaylandxdgshell.h.
|
read |
\qmlproperty size XdgToplevel::minSize
This property holds the minimum size of the XdgToplevel as requested by the client.
The compositor is free to ignore this value and request a smaller size.
This property holds the minimum size of the QWaylandXdgToplevel.
The compositor is free to ignore this value and request a smaller size.
Definition at line 123 of file qwaylandxdgshell.h.
|
read |
\qmlproperty bool XdgToplevel::modal
This property holds whether toplevel blocks other windows from receiving input.
This property holds whether toplevel blocks other windows from receiving input.
Definition at line 129 of file qwaylandxdgshell.h.
|
read |
\qmlproperty XdgToplevel XdgToplevel::parentToplevel
This property holds the XdgToplevel parent of this XdgToplevel.
This property holds the XdgToplevel parent of this XdgToplevel.
Definition at line 119 of file qwaylandxdgshell.h.
|
read |
\qmlproperty bool XdgToplevel::resizing
This property holds whether the client has acknowledged that it is being resized.
This property holds whether the client has acknowledged that it is being resized.
Definition at line 127 of file qwaylandxdgshell.h.
|
read |
This property holds the last states the client acknowledged for this QWaylandToplevel.
Definition at line 124 of file qwaylandxdgshell.h.
|
read |
\qmlproperty string XdgToplevel::title
This property holds the title of the XdgToplevel.
This property holds the title of the QWaylandXdgToplevel.
Definition at line 120 of file qwaylandxdgshell.h.
|
read |
\qmlproperty XdgSurface XdgToplevel::xdgSurface
This property holds the XdgSurface for this XdgToplevel.
This property holds the QWaylandXdgSurface for this QWaylandXdgToplevel.
Definition at line 118 of file qwaylandxdgshell.h.