diff options
author | Kai Koehne <kai.koehne@qt.io> | 2019-02-28 09:18:01 +0100 |
---|---|---|
committer | Shawn Rutledge <shawn.rutledge@qt.io> | 2019-03-01 05:10:44 +0000 |
commit | 25f24ae313ec5c69fe78593e19aa84f17c34edaf (patch) | |
tree | 8665267babfd4e797850c06ac17cf3713652387f /src/qml/doc/src/qmllanguageref/syntax/signals.qdoc | |
parent | f8c82616854984f05c737a1d3ef532108c6e0549 (diff) |
Doc: Fix use of \QtMinorVersion in snippets
Macros are in general not extended in \qml..\endqml code snippets.
You need to make it an explicit argument.
This fixes a regression introduced in fd3cf7a45ad5abf26.
Change-Id: Ic3a44d6c66b2301a12e051d647dfa6aebf8e8256
Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Diffstat (limited to 'src/qml/doc/src/qmllanguageref/syntax/signals.qdoc')
-rw-r--r-- | src/qml/doc/src/qmllanguageref/syntax/signals.qdoc | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/src/qml/doc/src/qmllanguageref/syntax/signals.qdoc b/src/qml/doc/src/qmllanguageref/syntax/signals.qdoc index b643f18154..cd73ccc025 100644 --- a/src/qml/doc/src/qmllanguageref/syntax/signals.qdoc +++ b/src/qml/doc/src/qmllanguageref/syntax/signals.qdoc @@ -59,9 +59,9 @@ receiving this signal should be \c onClicked. In the example below, whenever the button is clicked, the \c onClicked handler is invoked, applying a random color to the parent \l Rectangle: -\qml -import QtQuick 2.\QtMinorVersion -import QtQuick.Controls 2.\QtMinorVersion +\qml \QtMinorVersion +import QtQuick 2.\1 +import QtQuick.Controls 2.\1 Rectangle { id: rect @@ -87,8 +87,8 @@ these signals are written in the form \e on<Property>Changed, where For example, the \l MouseArea type has a \l {MouseArea::pressed}{pressed} property. To receive a notification whenever this property changes, write a signal handler named \c onPressedChanged: -\qml -import QtQuick 2.\QtMinorVersion +\qml \QtMinorVersion +import QtQuick 2.\1 Rectangle { id: rect @@ -116,9 +116,9 @@ received by the root \l Rectangle instead, by placing the \c onClicked handler in a \l Connections object that has its \l {Connections::target}{target} set to the \c button: -\qml -import QtQuick 2.\QtMinorVersion -import QtQuick.Controls 2.\QtMinorVersion +\qml \QtMinorVersion +import QtQuick 2.\1 +import QtQuick.Controls 2.\1 Rectangle { id: rect @@ -151,8 +151,8 @@ For example, \l{Component::completed}{Component.onCompleted} is an attached signal handler. It is often used to execute some JavaScript code when its creation process is complete. Here is an example: -\qml -import QtQuick 2.\QtMinorVersion +\qml \QtMinorVersion +import QtQuick 2.\1 Rectangle { width: 200; height: 200 @@ -195,9 +195,9 @@ root \l Rectangle object has an \c activated signal, which is emitted whenever t child \l TapHandler is \c tapped. In this particular example the activated signal is emitted with the x and y coordinates of the mouse click: -\qml +\qml \QtMinorVersion // SquareButton.qml -import QtQuick 2.\QtMinorVersion +import QtQuick 2.\1 Rectangle { id: root @@ -237,8 +237,8 @@ signal to be received by a method instead of a signal handler. Below, the \c messageReceived signal is connected to three methods using the \c connect() method: -\qml -import QtQuick 2.\QtMinorVersion +\qml \QtMinorVersion +import QtQuick 2.\1 Rectangle { id: relay @@ -289,8 +289,8 @@ Rectangle { By connecting signals to other signals, the \c connect() method can form different signal chains. -\qml -import QtQuick 2.\QtMinorVersion +\qml \QtMinorVersion +import QtQuick 2.\1 Rectangle { id: forwarder |