Viadeo Twitter Google Bookmarks ! Facebook Digg del.icio.us MySpace Yahoo MyWeb Blinklist Netvouz Reddit Simpy StumbleUpon Bookmarks Windows Live Favorites 
Logo Documentation Qt ·  Page d'accueil  ·  Toutes les classes  ·  Toutes les fonctions  ·  Vues d'ensemble  · 

QGeoMapRouteObject Class Reference

The QGeoMapRouteObject class is a QGeoMapObject used to draw a route on a map. More...

 #include <QGeoMapRouteObject>

Inherits QGeoMapObject.

Properties

Public Functions

QGeoMapRouteObject ()
QGeoMapRouteObject ( const QGeoRoute & route )
~QGeoMapRouteObject ()
quint32 detailLevel () const
QPen pen () const
QGeoRoute route () const
void setDetailLevel ( quint32 detailLevel )
void setPen ( const QPen & pen )
void setRoute ( const QGeoRoute & route )

Reimplemented Public Functions

virtual QGeoMapObject::Type type () const

Signals

void detailLevelChanged ( quint32 detailLevel )
void penChanged ( const QPen & pen )
void routeChanged ( const QGeoRoute & route )

Additional Inherited Members

  • 1 public slot inherited from QObject
  • 1 public variable inherited from QObject
  • 4 static public members inherited from QObject
  • 7 protected functions inherited from QObject
  • 2 protected variables inherited from QObject

Detailed Description

The QGeoMapRouteObject class is a QGeoMapObject used to draw a route on a map.

The route is specified by a QGeoRoute object.

The route might be quite detailed, and so to improve performance the detail level can be set with QGeoMapRouteObject::detailLevel.

The route object draws the route as a series of lines with a minimum on-screen harmattan length equal to the detail level. This is done so that the small changes in direction of a road will be visible at high zoom levels but will not slow down the rendering at the lower zoom levels.

Property Documentation

detailLevel : quint32

This property holds this property holds the level of detail used to draw this object.

A QGeoRoute instance can contain a large amount of information about the path taken by the route. This property is used as a hint to help reduce the amount of information that needs to be drawn on the map.

The path taken by the route is represented as a list of QGeoCoordinate instances. This route object will draw lines between these coordinates, but will skip members of the list until the manhattan distance between the start point and the end point of the line is at least detailLevel.

The default value of this property is 6.

Access functions:

quint32 detailLevel () const
void setDetailLevel ( quint32 detailLevel )

Notifier signal:

void detailLevelChanged ( quint32 detailLevel )

pen : QPen

This property holds this property holds the pen that will be used to draw this object.

The pen is used to draw the route.

The pen will be treated like a cosmetic pen, which means that the width of the pen will be independent of the zoom level of the map.

Access functions:

QPen pen () const
void setPen ( const QPen & pen )

Notifier signal:

void penChanged ( const QPen & pen )

route : QGeoRoute

This property holds this property holds the which will be displayed.

The default value of this property is an empty route.

If QGeoRoute::path() returns a list of less than 2 valid QGeoCoordinates then the route object will not be displayed.

Access functions:

QGeoRoute route () const
void setRoute ( const QGeoRoute & route )

Notifier signal:

void routeChanged ( const QGeoRoute & route )

Member Function Documentation

QGeoMapRouteObject::QGeoMapRouteObject ()

Constructs a new route object.

QGeoMapRouteObject::QGeoMapRouteObject ( const QGeoRoute & route )

Constructs a new route object for the route route.

QGeoMapRouteObject::~QGeoMapRouteObject ()

Destroys this route object

void QGeoMapRouteObject::detailLevelChanged ( quint32 detailLevel ) [signal]

This signal is emitted when the level of detail used to draw this route object has changed.

The new value is detailLevel.

void QGeoMapRouteObject::penChanged ( const QPen & pen ) [signal]

This signal is emitted when the pen used to draw this route object has changed.

The new value is pen.

void QGeoMapRouteObject::routeChanged ( const QGeoRoute & route ) [signal]

This signal is emitted when the route drawn by this route object has changed.

The new value is route.

QGeoMapObject::Type QGeoMapRouteObject::type () const [virtual]

Reimplemented from QGeoMapObject::type().

X

Thank you for giving your feedback.

Make sure it is related to this specific page. For more general bugs and requests, please use the Qt Bug Tracker.

[0]; s.parentNode.insertBefore(ga, s); })();
Cette page est une traduction d'une page de la documentation de Qt, écrite par Nokia Corporation and/or its subsidiary(-ies). Les éventuels problèmes résultant d'une mauvaise traduction ne sont pas imputables à Nokia. Qt qtmobility-1.1
Copyright © 2012 Developpez LLC. Tous droits réservés Developpez LLC. Aucune reproduction, même partielle, ne peut être faite de ce site et de l'ensemble de son contenu : textes, documents et images sans l'autorisation expresse de Developpez LLC. Sinon, vous encourez selon la loi jusqu'à 3 ans de prison et jusqu'à 300 000 E de dommages et intérêts. Cette page est déposée à la SACD.
Vous avez déniché une erreur ? Un bug ? Une redirection cassée ? Ou tout autre problème, quel qu'il soit ? Ou bien vous désirez participer à ce projet de traduction ? N'hésitez pas à nous contacter ou par MP !
 
 
 
 
Partenaires

Hébergement Web