Qt Mobility Reference Documentation

QGeoMapPolylineObject Class Reference

The QGeoMapPolylineObject class is a QGeoMapObject used to draw a segmented line on a map. More...

 #include <QGeoMapPolylineObject>

Inherits QGeoMapObject.


Properties

  • path : QList<QGeoCoordinate>
  • pen : QPen

Public Functions

QGeoMapPolylineObject ( QGeoMapObject * parent = 0 )
~QGeoMapPolylineObject ()
QList<QGeoCoordinate> path () const
QPen pen () const
void setPath ( const QList<QGeoCoordinate> & path )
void setPen ( const QPen & pen )

Signals

void pathChanged ( const QList<QGeoCoordinate> & path )
void penChanged ( const QPen & pen )

Detailed Description

The QGeoMapPolylineObject class is a QGeoMapObject used to draw a segmented line on a map.

The polyline is specified by a list of at least 2 valid QGeoCoordinate instances and a line will be drawn between every adjacent pairs of coordinates in the list.


Property Documentation

path : QList<QGeoCoordinate>

This property holds this property holds the ordered list of coordinates which define the segmented line to be drawn by this polyline object.

The default value of this property is an empty list of coordinates.

A line will be drawn between every pair of coordinates which are adjacent in the list.

Invalid coordinates in the list will be ignored, and if the list of coordinates contains less than 2 valid coordinates then the polyline object will not be displayed.

Access functions:

QList<QGeoCoordinate> path () const
void setPath ( const QList<QGeoCoordinate> & path )

Notifier signal:

void pathChanged ( const QList<QGeoCoordinate> & path )

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 polyline.

The pen will be treated as 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 )

Member Function Documentation

QGeoMapPolylineObject::QGeoMapPolylineObject ( QGeoMapObject * parent = 0 )

Constructs a new polyline object with the parent parent.

QGeoMapPolylineObject::~QGeoMapPolylineObject ()

Destroys this polyline object.

void QGeoMapPolylineObject::pathChanged ( const QList<QGeoCoordinate> & path ) [signal]

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

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.