Qt
6.x
The Qt SDK
Loading...
Searching...
No Matches
qcomposeplatforminputcontextmain.cpp
Go to the documentation of this file.
1
// Copyright (C) 2019 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
4
#include <qpa/qplatforminputcontextplugin_p.h>
5
6
#include <QtCore/QStringList>
7
8
#include "
qcomposeplatforminputcontext.h
"
9
10
QT_BEGIN_NAMESPACE
11
12
using namespace
Qt::StringLiterals
;
13
14
class
QComposePlatformInputContextPlugin
:
public
QPlatformInputContextPlugin
15
{
16
Q_OBJECT
17
Q_PLUGIN_METADATA
(
IID
QPlatformInputContextFactoryInterface_iid
FILE
"compose.json"
)
18
19
public
:
20
QComposeInputContext
*
create
(
const
QString
&,
const
QStringList
&)
override
;
21
};
22
23
QComposeInputContext
*
QComposePlatformInputContextPlugin::create
(
const
QString
&system,
const
QStringList
¶mList)
24
{
25
Q_UNUSED
(paramList);
26
27
if
(system.
compare
(system,
"compose"
_L1,
Qt::CaseInsensitive
) == 0
28
|| system.
compare
(system,
"xim"
_L1,
Qt::CaseInsensitive
) == 0)
29
return
new
QComposeInputContext
;
30
return
nullptr
;
31
}
32
33
QT_END_NAMESPACE
34
35
#include "qcomposeplatforminputcontextmain.moc"
QComposeInputContext
Definition
qcomposeplatforminputcontext.h:20
QComposePlatformInputContextPlugin
Definition
qcomposeplatforminputcontextmain.cpp:15
QComposePlatformInputContextPlugin::create
QComposeInputContext * create(const QString &, const QStringList &) override
Definition
qcomposeplatforminputcontextmain.cpp:23
QPlatformInputContextPlugin
Definition
qplatforminputcontextplugin_p.h:30
QStringList
\inmodule QtCore
QString
\macro QT_RESTRICTED_CAST_FROM_ASCII
Definition
qstring.h:127
QString::compare
int compare(const QString &s, Qt::CaseSensitivity cs=Qt::CaseSensitive) const noexcept
Definition
qstring.cpp:6498
QT_BEGIN_NAMESPACE
Combined button and popup list for selecting options.
Definition
qstandardpaths_haiku.cpp:21
QT_END_NAMESPACE
Definition
qsharedpointer.cpp:1545
Qt::StringLiterals
Definition
qbytearray.h:716
Qt::CaseInsensitive
@ CaseInsensitive
Definition
qnamespace.h:1257
qcomposeplatforminputcontext.h
QPlatformInputContextFactoryInterface_iid
#define QPlatformInputContextFactoryInterface_iid
Definition
qplatforminputcontextplugin_p.h:27
QtPluginMetaDataKeys::IID
@ IID
Q_OBJECT
#define Q_OBJECT
Definition
qtmetamacros.h:117
Q_PLUGIN_METADATA
#define Q_PLUGIN_METADATA(x)
Definition
qtmetamacros.h:54
Q_UNUSED
#define Q_UNUSED(x)
Definition
qtpreprocessorsupport.h:20
create
view create()
qtbase
src
plugins
platforminputcontexts
compose
qcomposeplatforminputcontextmain.cpp
Generated by
1.9.7