The QGeoMapRectangleObject class is a QGeoMapObject used to draw a rectangular region on a map. More...
#include <QGeoMapRectangleObject>
Inherits: QGeoMapObject.
This class was introduced in Qt Mobility 1.1.
QGeoMapRectangleObject () | |
QGeoMapRectangleObject ( const QGeoBoundingBox & boundingBox ) | |
QGeoMapRectangleObject ( const QGeoCoordinate & topLeft, const QGeoCoordinate & bottomRight ) | |
~QGeoMapRectangleObject () | |
QGeoCoordinate | bottomRight () const |
QGeoBoundingBox | bounds () const |
QBrush | brush () const |
QPen | pen () const |
void | setBottomRight ( const QGeoCoordinate & bottomRight ) |
void | setBounds ( const QGeoBoundingBox & bounds ) |
void | setBrush ( const QBrush & brush ) |
void | setPen ( const QPen & pen ) |
void | setTopLeft ( const QGeoCoordinate & topLeft ) |
QGeoCoordinate | topLeft () const |
virtual QGeoMapObject::Type | type () const |
void | bottomRightChanged ( const QGeoCoordinate & bottomRight ) |
void | brushChanged ( const QBrush & brush ) |
void | penChanged ( const QPen & pen ) |
void | topLeftChanged ( const QGeoCoordinate & topLeft ) |
The QGeoMapRectangleObject class is a QGeoMapObject used to draw a rectangular region on a map.
The rectangle is specified by either a valid QGeoBoundingBox instance or a pair of valid QGeoCoordinate instances which represent the top left and bottom right coordinates of the rectangle respectively.
This property holds the bottom right coordinate of the rectangle to be drawn by this rectangle object.
The default value of this property is an invalid coordinate. While the value of this property is invalid the rectangle object will not be displayed.
This property was introduced in Qt Mobility 1.1.
Access functions:
QGeoCoordinate | bottomRight () const |
void | setBottomRight ( const QGeoCoordinate & bottomRight ) |
Notifier signal:
void | bottomRightChanged ( const QGeoCoordinate & bottomRight ) |
This property holds the brush that will be used to draw this object.
The brush is used to fill in rectangle.
The outline around the perimeter of the rectangle is drawn using the QGeoMapRectangleObject::pen property.
This property was introduced in Qt Mobility 1.1.
Access functions:
QBrush | brush () const |
void | setBrush ( const QBrush & brush ) |
Notifier signal:
void | brushChanged ( const QBrush & brush ) |
This property holds the pen that will be used to draw this object.
The pen is used to draw an outline around the rectangle. The rectangle is filled using the QGeoMapRectangleObject::brush property.
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.
This property was introduced in Qt Mobility 1.1.
Access functions:
QPen | pen () const |
void | setPen ( const QPen & pen ) |
Notifier signal:
void | penChanged ( const QPen & pen ) |
This property holds the top left coordinate of the rectangle to be drawn by this rectangle object.
The default value of this property is an invalid coordinate. While the value of this property is invalid the rectangle object will not be displayed.
This property was introduced in Qt Mobility 1.1.
Access functions:
QGeoCoordinate | topLeft () const |
void | setTopLeft ( const QGeoCoordinate & topLeft ) |
Notifier signal:
void | topLeftChanged ( const QGeoCoordinate & topLeft ) |
Constructs a new rectangle object.
Constructs a new rectangle object based on the bounding box boundingBox.
This function was introduced in Qt Mobility 1.1.
Constructs a new rectangle object with the top left coordinate at topLeft and the bottom right coordinate at bottomRight.
This function was introduced in Qt Mobility 1.1.
Destroys this rectangle object.
This signal is emitted when the bottom right coordinate of this rectangle object has changed.
The new value is bottomRight.
This function was introduced in Qt Mobility 1.1.
Returns a QGeoBoundingBox instance which corresponds to the rectangle that will be drawn by this object.
This is equivalent to
QGeoMapRectangleObject *object; // setup object QGeoBoundingBox(object->topLeft(), object->bottomRight());
This function was introduced in Qt Mobility 1.1.
See also setBounds().
This signal is emitted when the brush used to fill in the interior of this rectangle object has changed.
The new value is brush.
This function was introduced in Qt Mobility 1.1.
This signal is emitted when the pen used to draw the perimeter of this rectangle object has changed.
The new value is pen.
This function was introduced in Qt Mobility 1.1.
Sets the rectangle that will be drawn by this object to bounds.
This is equivalent to
QGeoMapRectangleObject *object; // setup object object->setTopLeft(bounds.topLeft()); object->setBottomRight(bounds.bottomRight());
This function was introduced in Qt Mobility 1.1.
See also bounds().
This signal is emitted when the top left coordinate of this rectangle object has changed.
The new value is topLeft.
This function was introduced in Qt Mobility 1.1.
Reimplemented from QGeoMapObject::type().
This function was introduced in Qt Mobility 1.1.
© 2008-2011 Nokia Corporation and/or its subsidiaries. Nokia, Qt and their respective logos are trademarks of Nokia Corporation in Finland and/or other countries worldwide.
All other trademarks are property of their respective owners. Privacy Policy
Licensees holding valid Qt Commercial licenses may use this document in accordance with the Qt Commercial License Agreement provided with the Software or, alternatively, in accordance with the terms contained in a written agreement between you and Nokia.
Alternatively, this document may be used under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation.