QGeoCircle Class
The QGeoCircle class defines a circular geographic area. More...
Header: | #include <QGeoCircle> |
qmake: | QT += positioning |
Since: | Qt 5.2 |
Inherits: | QGeoShape. |
Public Functions
QGeoCircle() | |
QGeoCircle(const QGeoCoordinate & center, qreal radius = -1.0) | |
QGeoCircle(const QGeoCircle & other) | |
QGeoCircle(const QGeoShape & other) | |
~QGeoCircle() | |
QGeoCoordinate | center() const |
qreal | radius() const |
void | setCenter(const QGeoCoordinate & center) |
void | setRadius(qreal radius) |
void | translate(double degreesLatitude, double degreesLongitude) |
QGeoCircle | translated(double degreesLatitude, double degreesLongitude) const |
bool | operator!=(const QGeoShape & other) const |
bool | operator!=(const QGeoCircle & other) const |
QGeoCircle & | operator=(const QGeoCircle & other) |
bool | operator==(const QGeoShape & other) const |
bool | operator==(const QGeoCircle & other) const |
- 8 public functions inherited from QGeoShape
Detailed Description
The QGeoCircle class defines a circular geographic area.
The circle is defined in terms of a QGeoCoordinate which specifies the center of the circle and a qreal which specifies the radius of the circle in meters.
The circle is considered invalid if the center coordinate is invalid or if the radius is less than zero.
Member Function Documentation
QGeoCircle::QGeoCircle()
Constructs a new, invalid geo circle.
QGeoCircle::QGeoCircle(const QGeoCoordinate & center, qreal radius = -1.0)
Constructs a new geo circle centered at center and with a radius of radius meters.
QGeoCircle::QGeoCircle(const QGeoCircle & other)
Constructs a new geo circle from the contents of other.
QGeoCircle::QGeoCircle(const QGeoShape & other)
Constructs a new geo circle from the contents of other.
QGeoCircle::~QGeoCircle()
Destroys this geo circle.
QGeoCoordinate QGeoCircle::center() const
Returns the center coordinate of this geo circle.
See also setCenter().
qreal QGeoCircle::radius() const
Returns the radius in meters of this geo circle.
See also setRadius().
void QGeoCircle::setCenter(const QGeoCoordinate & center)
Sets the center coordinate of this geo circle to center.
See also center().
void QGeoCircle::setRadius(qreal radius)
Sets the radius in meters of this geo circle to radius.
See also radius().
void QGeoCircle::translate(double degreesLatitude, double degreesLongitude)
Translates this geo circle by degreesLatitude northwards and degreesLongitude eastwards.
Negative values of degreesLatitude and degreesLongitude correspond to southward and westward translation respectively.
QGeoCircle QGeoCircle::translated(double degreesLatitude, double degreesLongitude) const
Returns a copy of this geo circle translated by degreesLatitude northwards and degreesLongitude eastwards.
Negative values of degreesLatitude and degreesLongitude correspond to southward and westward translation respectively.
See also translate().
bool QGeoCircle::operator!=(const QGeoShape & other) const
Returns true if other is not equal to this geo circle; otherwise returns false.
bool QGeoCircle::operator!=(const QGeoCircle & other) const
Returns whether this geo circle is not equal to other.
QGeoCircle & QGeoCircle::operator=(const QGeoCircle & other)
Assigns other to this geo circle and returns a reference to this geo circle.
bool QGeoCircle::operator==(const QGeoShape & other) const
Returns true if other is equal to this geo circle; otherwise returns false.
bool QGeoCircle::operator==(const QGeoCircle & other) const
Returns whether this geo circle is equal to other.
© 2015 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.