|
QGroundControl
Ground Control Station for MAVLink Drones
|
The QGCMapCircle represents a circular area which can be displayed on a Map control. More...
#include <QGCMapCircle.h>
Inheritance diagram for QGCMapCircle:
Collaboration diagram for QGCMapCircle:Signals | |
| void | dirtyChanged (bool dirty) |
| void | centerChanged (QGeoCoordinate center) |
| void | interactiveChanged (bool interactive) |
| void | showRotationChanged (bool showRotation) |
| void | clockwiseRotationChanged (bool clockwiseRotation) |
Public Member Functions | |
| QGCMapCircle (QObject *parent=nullptr) | |
| QGCMapCircle (const QGeoCoordinate ¢er, double radius, QObject *parent=nullptr) | |
| QGCMapCircle (const QGeoCoordinate ¢er, double radius, bool showRotation, bool clockwiseRotation, QObject *parent=nullptr) | |
| QGCMapCircle (const QGCMapCircle &other, QObject *parent=nullptr) | |
| const QGCMapCircle & | operator= (const QGCMapCircle &other) |
| bool dirty READ dirty WRITE setDirty NOTIFY | dirtyChanged (QGeoCoordinate center READ center WRITE setCenter NOTIFY centerChanged) 1(Fact *radius READ radius CONSTANT) 1(bool interactive READ interactive WRITE setInteractive NOTIFY interactiveChanged) 1(bool showRotation READ showRotation WRITE setShowRotation NOTIFY showRotationChanged) 1(bool clockwiseRotation READ clockwiseRotation WRITE setClockwiseRotation NOTIFY clockwiseRotationChanged) void saveToJson(QJsonObject &json) |
| bool | loadFromJson (const QJsonObject &json, QString &errorString) |
| bool | dirty (void) const |
| QGeoCoordinate | center (void) const |
| Fact * | radius (void) |
| bool | interactive (void) const |
| bool | showRotation (void) const |
| bool | clockwiseRotation (void) const |
| void | setDirty (bool dirty) |
| void | setCenter (QGeoCoordinate newCenter) |
| void | setInteractive (bool interactive) |
| void | setShowRotation (bool showRotation) |
| void | setClockwiseRotation (bool clockwiseRotation) |
Static Public Attributes | |
| static constexpr const char * | jsonCircleKey = "circle" |
The QGCMapCircle represents a circular area which can be displayed on a Map control.
Definition at line 10 of file QGCMapCircle.h.
| QGCMapCircle::QGCMapCircle | ( | QObject * | parent = nullptr | ) |
Definition at line 5 of file QGCMapCircle.cc.
| QGCMapCircle::QGCMapCircle | ( | const QGeoCoordinate & | center, |
| double | radius, | ||
| QObject * | parent = nullptr |
||
| ) |
| QGCMapCircle::QGCMapCircle | ( | const QGeoCoordinate & | center, |
| double | radius, | ||
| bool | showRotation, | ||
| bool | clockwiseRotation, | ||
| QObject * | parent = nullptr |
||
| ) |
Definition at line 15 of file QGCMapCircle.cc.
References radius().
| QGCMapCircle::QGCMapCircle | ( | const QGCMapCircle & | other, |
| QObject * | parent = nullptr |
||
| ) |
Definition at line 28 of file QGCMapCircle.cc.
|
inline |
Definition at line 43 of file QGCMapCircle.h.
Referenced by loadFromJson(), and GeoFenceManager::sendToVehicle().
|
signal |
Referenced by setCenter().
|
inline |
Definition at line 47 of file QGCMapCircle.h.
Referenced by setClockwiseRotation().
|
signal |
Referenced by setClockwiseRotation().
|
inline |
Definition at line 42 of file QGCMapCircle.h.
Referenced by setDirty().
|
signal |
| bool dirty READ dirty WRITE setDirty NOTIFY QGCMapCircle::dirtyChanged | ( | QGeoCoordinate center READ center WRITE setCenter NOTIFY | centerChanged | ) | & |
Saves the polygon to the json object.
| json | Json object to save to |
Referenced by setDirty().
|
inline |
Definition at line 45 of file QGCMapCircle.h.
Referenced by setInteractive().
|
signal |
Referenced by setInteractive().
| bool QGCMapCircle::loadFromJson | ( | const QJsonObject & | json, |
| QString & | errorString | ||
| ) |
Load a circle from json
| json | Json object to load from |
| errorString | Error string if return is false |
Definition at line 79 of file QGCMapCircle.cc.
References center(), errorString, jsonCircleKey, JsonHelper::loadGeoCoordinate(), setCenter(), and JsonHelper::validateKeys().
Referenced by QGCFenceCircle::loadFromJson().
| const QGCMapCircle & QGCMapCircle::operator= | ( | const QGCMapCircle & | other | ) |
Definition at line 41 of file QGCMapCircle.cc.
References setCenter(), and setDirty().
Referenced by QGCFenceCircle::operator=().
|
inline |
Definition at line 44 of file QGCMapCircle.h.
Referenced by QGCMapCircle(), and GeoFenceManager::sendToVehicle().
| void QGCMapCircle::setCenter | ( | QGeoCoordinate | newCenter | ) |
Definition at line 114 of file QGCMapCircle.cc.
References centerChanged(), and setDirty().
Referenced by loadFromJson(), and operator=().
| void QGCMapCircle::setClockwiseRotation | ( | bool | clockwiseRotation | ) |
Definition at line 144 of file QGCMapCircle.cc.
References clockwiseRotation(), and clockwiseRotationChanged().
| void QGCMapCircle::setDirty | ( | bool | dirty | ) |
Definition at line 59 of file QGCMapCircle.cc.
References dirty(), and dirtyChanged().
Referenced by operator=(), setCenter(), and GeoFenceController::setDirty().
| void QGCMapCircle::setInteractive | ( | bool | interactive | ) |
Definition at line 128 of file QGCMapCircle.cc.
References interactive(), and interactiveChanged().
Referenced by GeoFenceController::addInclusionCircle().
| void QGCMapCircle::setShowRotation | ( | bool | showRotation | ) |
Definition at line 136 of file QGCMapCircle.cc.
References showRotation(), and showRotationChanged().
|
inline |
Definition at line 46 of file QGCMapCircle.h.
Referenced by setShowRotation().
|
signal |
Referenced by setShowRotation().
|
staticconstexpr |
Definition at line 55 of file QGCMapCircle.h.
Referenced by loadFromJson().