1// Copyright (C) 2016 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
3
4#include "qtquickvirtualkeyboardstylesplugin.h"
5#include "svgimageprovider.h"
6
7#include <QtQml/qqml.h>
8#include <QtCore/QLibraryInfo>
9
10QT_BEGIN_NAMESPACE
11
12extern void qml_register_types_QtQuick_VirtualKeyboard_Styles();
13Q_GHS_KEEP_REFERENCE(qml_register_types_QtQuick_VirtualKeyboard_Styles);
14
15/*!
16 \qmlmodule QtQuick.VirtualKeyboard.Styles
17 \title Qt Quick Virtual Keyboard Styles QML Types
18 \ingroup qmlmodules
19
20 \brief Provides styling for Qt Virtual Keyboard.
21
22 The QML types can be imported into your application using the following
23 import statements in your .qml file:
24
25 \qml
26 import QtQuick.VirtualKeyboard.Styles
27 \endqml
28*/
29
30QtQuickVirtualKeyboardStylesPlugin::QtQuickVirtualKeyboardStylesPlugin(QObject *parent) :
31 QQmlExtensionPlugin(parent)
32{
33 volatile auto registration = &qml_register_types_QtQuick_VirtualKeyboard_Styles;
34 Q_UNUSED(registration);
35}
36
37void QtQuickVirtualKeyboardStylesPlugin::registerTypes(const char *uri)
38{
39 Q_UNUSED(uri);
40}
41
42void QtQuickVirtualKeyboardStylesPlugin::initializeEngine(QQmlEngine *engine, const char *uri)
43{
44 Q_UNUSED(uri);
45 engine->addImageProvider(QStringLiteral("qtvkbsvg"), new SvgImageProvider());
46}
47
48QT_END_NAMESPACE
49

source code of qtvirtualkeyboard/src/styles/qtquickvirtualkeyboardstylesplugin.cpp