Krita Source Code Documentation
Loading...
Searching...
No Matches
Window.h
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2016 Boudewijn Rempt <boud@valdyas.org>
3 *
4 * SPDX-License-Identifier: LGPL-2.0-or-later
5 */
6#ifndef LIBKIS_WINDOW_H
7#define LIBKIS_WINDOW_H
8
9#include <QObject>
10#include <QAction>
11#include <QMainWindow>
12
13#include "kritalibkis_export.h"
14#include "libkis.h"
15
16class KisMainWindow;
17
22class KRITALIBKIS_EXPORT Window : public QObject
23{
24 Q_OBJECT
25
26public:
27 explicit Window(KisMainWindow *window, QObject *parent = 0);
28 ~Window() override;
29
30 bool operator==(const Window &other) const;
31 bool operator!=(const Window &other) const;
32
33public Q_SLOTS:
34
39 QMainWindow *qwindow() const;
40
45 QList<QDockWidget *> dockers() const;
46
50 QList<View*> views() const;
51
55 View *addView(Document *document);
56
61 void showView(View *v);
62
63
67 View *activeView() const;
68
72 void activate();
73
79 void close();
80
92 QAction *createAction(const QString &id, const QString &text = QString(), const QString &menuLocation = QString("tools/scripts"));
93
94Q_SIGNALS:
97
100
103
104private:
105 struct Private;
106 Private *const d;
107
108};
109
110#endif // LIBKIS_WINDOW_H
qreal v
bool operator==(const KisRegion &lhs, const KisRegion &rhs)
bool operator!=(const KoID &v1, const KoID &v2)
Definition KoID.h:103
Main window for Krita.
Definition View.h:25
void themeChanged()
Emitted when we change the color theme.
void windowClosed()
Emitted when the window is closed.
Private *const d
Definition Window.h:106
void activeViewChanged()
Emitted when the active view changes.