aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMaximilian Goldstein <max.goldstein@qt.io>2022-02-17 17:13:56 +0100
committerMaximilian Goldstein <max.goldstein@qt.io>2022-02-21 10:03:00 +0100
commit3668bc40777b3d7a4606139b94ab0e02f13d8e6f (patch)
tree43b9882991560e6efb5ad6cd555549b6cb587e85
parent0c4610b58ee957180952c79c18c41ba6377b1fa4 (diff)
qquickinputmethod: Add documentation
Documents the InputMethod singleton since it wasn't documented in the change it was introduced. Change-Id: I1f5bafcb69dcd65c25c8e30e20aaeeff27ce704b Reviewed-by: Andrei Golubev <andrei.golubev@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
-rw-r--r--src/qml/qml/qqmlbuiltinfunctions.cpp2
-rw-r--r--src/quick/util/qquickinputmethod.cpp11
2 files changed, 13 insertions, 0 deletions
diff --git a/src/qml/qml/qqmlbuiltinfunctions.cpp b/src/qml/qml/qqmlbuiltinfunctions.cpp
index 37475dd2ee..9213bd7c2d 100644
--- a/src/qml/qml/qqmlbuiltinfunctions.cpp
+++ b/src/qml/qml/qqmlbuiltinfunctions.cpp
@@ -250,6 +250,8 @@ The following functions are also on the Qt object.
\qmlproperty object Qt::inputMethod
\since 5.0
+ It is the same as the \l InputMethod singleton.
+
The \c inputMethod object allows access to application's QInputMethod object
and all its properties and slots. See the QInputMethod documentation for
further details.
diff --git a/src/quick/util/qquickinputmethod.cpp b/src/quick/util/qquickinputmethod.cpp
index ddd117ec02..09f1e63016 100644
--- a/src/quick/util/qquickinputmethod.cpp
+++ b/src/quick/util/qquickinputmethod.cpp
@@ -43,6 +43,17 @@
QT_BEGIN_NAMESPACE
+/*!
+ \qmltype InputMethod
+ \inqmlmodule QtQuick.
+
+ \brief Provides access to \l QInputMethod for QML applications.
+
+ The InputMethod singleton allows access to application's \l QInputMethod object
+ and all its properties and slots. See the \l QInputMethod documentation for
+ further details.
+*/
+
QQuickInputMethod::QQuickInputMethod(QObject *parent) : QObject(parent)
{
QInputMethod *inputMethod = QGuiApplication::inputMethod();