summaryrefslogtreecommitdiff
path: root/src/imports/location/qdeclarativeroutemapitem.cpp
diff options
context:
space:
mode:
authorAlex Wilson <alex.wilson@nokia.com>2011-12-28 15:49:32 +1000
committerQt by Nokia <qt-info@nokia.com>2011-12-28 07:42:03 +0100
commit0960ad6b4ee2ac6e66f5ce06a395547cd7f34243 (patch)
tree2e4d1efeb42db6936f523c89efcc31aa2543d2b4 /src/imports/location/qdeclarativeroutemapitem.cpp
parentfe129bd8cbbfd8e411c5fe39059f9f062ab3375e (diff)
downloadqtlocation-0960ad6b4ee2ac6e66f5ce06a395547cd7f34243.tar.gz
Adding some docs for basic QML map items that have none
Docs for MapCircle, MapQuickItem, MapRectangle and MapRoute, as well as improvements to MapPolygon so that it appears in the list. Change-Id: I71e659f65ad3fe467893136acbec71db87f5ede5 Reviewed-by: Alex <alex.blasche@nokia.com>
Diffstat (limited to 'src/imports/location/qdeclarativeroutemapitem.cpp')
-rw-r--r--src/imports/location/qdeclarativeroutemapitem.cpp27
1 files changed, 27 insertions, 0 deletions
diff --git a/src/imports/location/qdeclarativeroutemapitem.cpp b/src/imports/location/qdeclarativeroutemapitem.cpp
index 5c50b51a..7eccf1a6 100644
--- a/src/imports/location/qdeclarativeroutemapitem.cpp
+++ b/src/imports/location/qdeclarativeroutemapitem.cpp
@@ -46,6 +46,16 @@
#include <QtDeclarative/QDeclarativeInfo>
#include <QtGui/QPainter>
+/*!
+ \qmlclass MapRoute QDeclarativeRouteMapItem
+ \inqmlmodule QtLocation 5
+ \ingroup qml-QtLocation5-maps
+ \since QtLocation 5.0
+
+ \brief The MapRoute element displays a route on the map.
+
+ \sa MapPolyline
+*/
static void updatePolyline(QPolygonF& points,const Map& map, const QList<QGeoCoordinate> &path, qreal& w, qreal& h)
{
@@ -116,6 +126,11 @@ void QDeclarativeRouteMapItem::setMap(QDeclarativeGeoMap* quickMap, Map *map)
}
}
+/*!
+ \qmlproperty GeoRoute MapRoute::route
+
+ Holds the route to be drawn.
+*/
QDeclarativeGeoRoute* QDeclarativeRouteMapItem::route() const
{
return route_;
@@ -159,6 +174,18 @@ QSGNode* QDeclarativeRouteMapItem::updatePaintNode(QSGNode* oldNode, UpdatePaint
return node;
}
+/*!
+ \qmlproperty int MapRoute::line.width
+ \qmlproperty color MapRoute::line.color
+
+ These properties hold the width and color used to draw the line.
+
+ The width is in pixels and is independent of the zoom level of the map.
+ The default values correspond to a black border with a width of 1 pixel.
+
+ For no line, use a width of 0 or a transparent color.
+*/
+
QDeclarativeMapLineProperties *QDeclarativeRouteMapItem::line()
{
return &line_;