Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qplatformservices.h
Go to the documentation of this file.
1// Copyright (C) 2016 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3// Qt-Security score:significant reason:default
4
5#ifndef QPLATFORMSERVICES_H
6#define QPLATFORMSERVICES_H
7
8//
9// W A R N I N G
10// -------------
11//
12// This file is part of the QPA API and is not meant to be used
13// in applications. Usage of this API may make your code
14// source and binary incompatible with future versions of Qt.
15//
16
17#include <QtGui/qtguiglobal.h>
18#include <QtCore/qobject.h>
19#include <QtCore/qloggingcategory.h>
20
22
24
25class QUrl;
26class QWindow;
27
28class Q_GUI_EXPORT QPlatformServiceColorPicker : public QObject
29{
30 Q_OBJECT
31public:
32 using QObject::QObject;
33 virtual void pickColor() = 0;
34Q_SIGNALS:
35 void colorPicked(const QColor &color);
36};
37
38class Q_GUI_EXPORT QPlatformServices
39{
40public:
41 Q_DISABLE_COPY_MOVE(QPlatformServices)
42
43 enum Capability {
44 ColorPicking,
45 };
46
47 QPlatformServices();
48 virtual ~QPlatformServices() { }
49
50 virtual bool openUrl(const QUrl &url);
51 virtual bool openDocument(const QUrl &url);
52
53 virtual QByteArray desktopEnvironment() const;
54
55 virtual bool hasCapability(Capability capability) const;
56
57 virtual QPlatformServiceColorPicker *colorPicker(QWindow *parent = nullptr);
58};
59
60QT_END_NAMESPACE
61
62#endif // QPLATFORMSERVICES_H
The QPlatformServices provides the backend for desktop-related functionality.
Combined button and popup list for selecting options.
QT_BEGIN_NAMESPACE QT_DECLARE_EXPORTED_QT_LOGGING_CATEGORY(lcAotCompiler, Q_QMLCOMPILER_EXPORT)