KWin
Loading...
Searching...
No Matches
server_decoration.h
Go to the documentation of this file.
1/*
2 SPDX-FileCopyrightText: 2015 Martin Gräßlin <mgraesslin@kde.org>
3
4 SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL
5*/
6#pragma once
7
8#include "kwin_export.h"
9
10#include <QObject>
11#include <memory>
12
13struct wl_resource;
14
15namespace KWin
16{
17class Display;
18class ServerSideDecorationInterface;
19class SurfaceInterface;
20class ServerSideDecorationManagerInterfacePrivate;
21class ServerSideDecorationInterfacePrivate;
22
26class KWIN_EXPORT ServerSideDecorationManagerInterface : public QObject
27{
28 Q_OBJECT
29
30public:
31 explicit ServerSideDecorationManagerInterface(Display *display, QObject *parent = nullptr);
33
37 enum class Mode {
41 None,
45 Client,
49 Server,
50 };
51
57 void setDefaultMode(Mode mode);
62 Mode defaultMode() const;
63
64Q_SIGNALS:
69
70private:
71 std::unique_ptr<ServerSideDecorationManagerInterfacePrivate> d;
72};
73
79class KWIN_EXPORT ServerSideDecorationInterface : public QObject
80{
81 Q_OBJECT
82public:
84
101 ServerSideDecorationManagerInterface::Mode preferredMode() const;
102
106 SurfaceInterface *surface() const;
107
112
113Q_SIGNALS:
121
122private:
123 explicit ServerSideDecorationInterface(ServerSideDecorationManagerInterface *manager, SurfaceInterface *surface, wl_resource *resource);
125
126 std::unique_ptr<ServerSideDecorationInterfacePrivate> d;
127};
128
129}
130
The Client class encapsulates a window decoration frame.
Class holding the Wayland server display loop.
Definition display.h:34
Representing how a SurfaceInterface should be decorated.
Manager to create ServerSideDecorationInterface.
void decorationCreated(KWin::ServerSideDecorationInterface *)
Resource representing a wl_surface.
Definition surface.h:80
Q_DECLARE_METATYPE(KWin::SwitchEvent::State)
struct _XDisplay Display