diff options
author | Lorn Potter <lorn.potter@nokia.com> | 2012-03-29 11:09:41 +1000 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-03-29 05:41:37 +0200 |
commit | 6c06a5536ad4dfe72423915c9bf99cd25a6c9b93 (patch) | |
tree | b15763bbd2784ee223e7eb5dbf7faae95d7413c0 /doc | |
parent | 2646629ea49cf808220ef54c77df613cc9fea474 (diff) | |
download | qtsensors-6c06a5536ad4dfe72423915c9bf99cd25a6c9b93.tar.gz |
fix up documentation according to the doc guys.
Change-Id: I417e3c57e986f9364f25d5a0e742bd31833de283
Reviewed-by: Lincoln Ramsay <lincoln.ramsay@nokia.com>
Reviewed-by: Lorn Potter <lorn.potter@nokia.com>
Diffstat (limited to 'doc')
-rw-r--r-- | doc/src/imports/qtsensors5.qdoc | 54 | ||||
-rw-r--r-- | doc/src/qtsensors.qdoc | 2 |
2 files changed, 19 insertions, 37 deletions
diff --git a/doc/src/imports/qtsensors5.qdoc b/doc/src/imports/qtsensors5.qdoc index c889868..5436ea2 100644 --- a/doc/src/imports/qtsensors5.qdoc +++ b/doc/src/imports/qtsensors5.qdoc @@ -32,49 +32,31 @@ \section1 Overview - The identifying string for this component is \e QtSensors. - Use this in the QML import statement, as such: \e import QtSensors 5.0 - The QML Sensors 5 Plugin provides an easy to use interface to the Sensors API. - It enables the receiving of sensor events and reading current values from the - sensors. + Mobile devices contains sensor hardware that allow detecting changes in various physical + properties of the device itself or its immediate environment. Examples of device properties + include the angle at which the device is held, whereas environmental properties include for + example the current level of ambient light. - The plugin contains many sensor types and properties to read values. - As an example, consider the tilt sensor. The \l {QML Qt Sensors example} - simply displays text on-screen to show the current tilt value. + These properties can be either actual values, such as the tilt angle in + degrees, or approximations, like the enumeration describing brightness in + relative terms using values such as AmbientLightSensor.Dark and AmbientLightSensor.Bright. - The QML code to read the value is quite simple. Below is a QML \l TiltSensor element - declared with an id of \e tilt. The sensor is started by setting the running - property to true. The element receives a signal when the x and y rotation - changes and it can be picked up by the onXRotationChanged and onYRotationChanged - slot. Now the xRotation and yRotation property of this element can be used to - extract the current tilt value so that it can be used for further calculations. + The latter type of value is also based on a natural phenomenon (in the case + of the ambient light sensor, the amount of visible light emitted by a source), but the value + itself is descriptive instead of using any effective unit of measurement, such as lumen. - \qml - TiltSensor { - id: tilt - enabled: false - unit: TiltSensor.Degrees - accuracy: 1.0 - } - \endqml + The identifying string for this component is \e QtSensors. + Use this in the QML import statement, as such: \e import QtSensors 5.0 - \qml - Text { - x:5 - y:160 - text: "X Rotation: " + tilt.xRotation - } - \endqml + Qt Sensors QML API provides an easy to use interface to the Qt Sensors API. + It enables the receiving of sensor events and reading current values from the + sensors. - \qml - Text { - x:5 - y:180 - text: "Y Rotation: " + tilt.yRotation - } + The emulator supports simulating the Ambient Light, Orientation, Compass and Proximity sensors. - \endqml + The \l {QML Qt Sensors example} contains code for using the the \l TiltSensor, \l AmbientLightSensor + and ProximitySensor elements. \section1 QML Elements diff --git a/doc/src/qtsensors.qdoc b/doc/src/qtsensors.qdoc index f67410c..925bc5a 100644 --- a/doc/src/qtsensors.qdoc +++ b/doc/src/qtsensors.qdoc @@ -31,7 +31,7 @@ \brief The Qt Sensors API provides access to sensors via QML and C++ interfaces. \ingroup technology-apis - The Qt Sensors API provides access to sensors via QML and C++ interfaces. + The Qt Sensors API provides access to sensor hardware via QML and C++ interfaces. \section1 Information for Application Writers |