KWin
|
#include <xdgshell.h>
Public Types | |
enum | State { MaximizedHorizontal = 0x1 , MaximizedVertical = 0x2 , FullScreen = 0x4 , Resizing = 0x8 , Activated = 0x10 , TiledLeft = 0x20 , TiledTop = 0x40 , TiledRight = 0x80 , TiledBottom = 0x100 , Suspended = 0x200 , Maximized = MaximizedHorizontal | MaximizedVertical } |
enum class | ResizeAnchor { None = 0 , Top = 1 , Bottom = 2 , Left = 4 , TopLeft = 5 , BottomLeft = 6 , Right = 8 , TopRight = 9 , BottomRight = 10 } |
enum class | Capability { WindowMenu = 0x1 , Maximize = 0x2 , FullScreen = 0x4 , Minimize = 0x8 } |
Signals | |
void | aboutToBeDestroyed () |
void | initializeRequested () |
void | resetOccurred () |
void | windowTitleChanged (const QString &windowTitle) |
void | windowClassChanged (const QString &windowClass) |
void | windowMenuRequested (KWin::SeatInterface *seat, const QPoint &pos, quint32 serial) |
void | minimumSizeChanged (const QSize &size) |
void | maximumSizeChanged (const QSize &size) |
void | moveRequested (KWin::SeatInterface *seat, quint32 serial) |
void | resizeRequested (KWin::SeatInterface *seat, KWin::XdgToplevelInterface::ResizeAnchor anchor, quint32 serial) |
void | maximizeRequested () |
void | unmaximizeRequested () |
void | fullscreenRequested (KWin::OutputInterface *output) |
void | unfullscreenRequested () |
void | minimizeRequested () |
void | parentXdgToplevelChanged () |
Public Member Functions | |
XdgToplevelInterface (XdgSurfaceInterface *surface, ::wl_resource *resource) | |
~XdgToplevelInterface () override | |
XdgShellInterface * | shell () const |
XdgSurfaceInterface * | xdgSurface () const |
SurfaceInterface * | surface () const |
XdgToplevelInterface * | parentXdgToplevel () const |
bool | isConfigured () const |
QString | windowTitle () const |
QString | windowClass () const |
QSize | minimumSize () const |
QSize | maximumSize () const |
quint32 | sendConfigure (const QSize &size, const States &states) |
void | sendClose () |
void | sendConfigureBounds (const QSize &size) |
void | sendWmCapabilities (Capabilities capabilities) |
Static Public Member Functions | |
static SurfaceRole * | role () |
static XdgToplevelInterface * | get (::wl_resource *resource) |
Friends | |
class | XdgToplevelInterfacePrivate |
The XdgToplevelInterface class represents a surface with window-like functionality such as maximize, fullscreen, resizing, minimizing, etc.
XdgToplevelInterface corresponds to the Wayland interface xdg_toplevel
.
Definition at line 208 of file xdgshell.h.
|
strong |
Enumerator | |
---|---|
WindowMenu | |
Maximize | |
FullScreen | |
Minimize |
Definition at line 241 of file xdgshell.h.
|
strong |
Enumerator | |
---|---|
None | |
Top | |
Bottom | |
Left | |
TopLeft | |
BottomLeft | |
Right | |
TopRight | |
BottomRight |
Definition at line 228 of file xdgshell.h.
Enumerator | |
---|---|
MaximizedHorizontal | |
MaximizedVertical | |
FullScreen | |
Resizing | |
Activated | |
TiledLeft | |
TiledTop | |
TiledRight | |
TiledBottom | |
Suspended | |
Maximized |
Definition at line 213 of file xdgshell.h.
KWin::XdgToplevelInterface::XdgToplevelInterface | ( | XdgSurfaceInterface * | surface, |
::wl_resource * | resource ) |
Constructs an XdgToplevelInterface for the given xdg-surface surface.
Definition at line 517 of file xdgshell.cpp.
|
override |
Destructs the XdgToplevelInterface object.
Definition at line 527 of file xdgshell.cpp.
|
signal |
This signal is emitted when the xdg-toplevel is about to be destroyed.
|
signal |
This signal is emitted when the toplevel wants to be shown in the full screen mode.
|
static |
Returns the XdgToplevelInterface for the specified wayland resource object resource.
Definition at line 678 of file xdgshell.cpp.
|
signal |
This signal is emitted when the xdg-toplevel has commited the initial state and wants to be configured. After initializing the toplevel, you must send a configure event.
bool KWin::XdgToplevelInterface::isConfigured | ( | ) | const |
Returns true
if the toplevel has been configured; otherwise returns false
.
Definition at line 557 of file xdgshell.cpp.
|
signal |
This signal is emitted when the toplevel surface wants to become maximized.
QSize KWin::XdgToplevelInterface::maximumSize | ( | ) | const |
Returns the maximum window geometry size of the toplevel surface.
Definition at line 582 of file xdgshell.cpp.
|
signal |
This signal is emitted when the toplevel's maximum size has been changed.
|
signal |
This signal is emitted when the toplevel wants to be iconified.
QSize KWin::XdgToplevelInterface::minimumSize | ( | ) | const |
Returns the minimum window geometry size of the toplevel surface.
Definition at line 577 of file xdgshell.cpp.
|
signal |
This signal is emitted when the toplevel's minimum size has been changed.
|
signal |
This signal is emitted when the toplevel wants to be interactively moved. The seat and the serial indicate the user action in response to which this request has been issued.
XdgToplevelInterface * KWin::XdgToplevelInterface::parentXdgToplevel | ( | ) | const |
Returns the parent XdgToplevelInterface above which this toplevel is stacked.
Definition at line 562 of file xdgshell.cpp.
|
signal |
This signal is emitted when the parent toplevel has changed.
|
signal |
This signal is emitted when the toplevel has been unmapped and its state has been reset.
|
signal |
This signal is emitted when the toplevel wants to be interactively resized by dragging the specified anchor. The seat and the serial indicate the user action in response to which this request has been issued.
|
static |
Definition at line 536 of file xdgshell.cpp.
void KWin::XdgToplevelInterface::sendClose | ( | ) |
Sends a close event to the client. The client may choose to ignore this request.
Definition at line 640 of file xdgshell.cpp.
quint32 KWin::XdgToplevelInterface::sendConfigure | ( | const QSize & | size, |
const States & | states ) |
Sends a configure event to the client. size specifies the new window geometry size. A size of zero means the client should decide its own window dimensions.
Definition at line 587 of file xdgshell.cpp.
void KWin::XdgToplevelInterface::sendConfigureBounds | ( | const QSize & | size | ) |
Sends an event to the client specifying the maximum bounds for the surface size. Must be called before sendConfigure().
Definition at line 645 of file xdgshell.cpp.
void KWin::XdgToplevelInterface::sendWmCapabilities | ( | Capabilities | capabilities | ) |
Sends an event to the client specifying allowed actions by the compositor.
Definition at line 652 of file xdgshell.cpp.
XdgShellInterface * KWin::XdgToplevelInterface::shell | ( | ) | const |
Returns the XdgShellInterface for this XdgToplevelInterface.
This is equivalent to xdgSurface()->shell().
Definition at line 542 of file xdgshell.cpp.
SurfaceInterface * KWin::XdgToplevelInterface::surface | ( | ) | const |
Returns the SurfaceInterface associated with the XdgToplevelInterface.
Definition at line 552 of file xdgshell.cpp.
|
signal |
This signal is emitted when the toplevel surface wants to leave the full screen mode.
|
signal |
This signal is emitted when the toplevel surface wants to become unmaximized.
QString KWin::XdgToplevelInterface::windowClass | ( | ) | const |
Returns the window class of the toplevel surface.
Definition at line 572 of file xdgshell.cpp.
|
signal |
This signal is emitted when the toplevel's application id has been changed.
|
signal |
This signal is emitted when the toplevel has requested the window menu to be shown at pos. The seat and the serial indicate the user action that triggerred the request.
QString KWin::XdgToplevelInterface::windowTitle | ( | ) | const |
Returns the window title of the toplevel surface.
Definition at line 567 of file xdgshell.cpp.
|
signal |
This signal is emitted when the toplevel's title has been changed.
XdgSurfaceInterface * KWin::XdgToplevelInterface::xdgSurface | ( | ) | const |
Returns the XdgSurfaceInterface associated with the XdgToplevelInterface.
Definition at line 547 of file xdgshell.cpp.
|
friend |
Definition at line 422 of file xdgshell.h.