mirror of
https://github.com/qgis/QGIS.git
synced 2025-12-15 00:07:25 -05:00
Expose QgsBearingUtils to QML
This commit is contained in:
parent
c004f40ee6
commit
ddd2c6ea3d
@ -21,11 +21,14 @@ Utilities for calculating bearings and directions.
|
||||
%TypeHeaderCode
|
||||
#include "qgsbearingutils.h"
|
||||
%End
|
||||
public:
|
||||
static const QMetaObject staticMetaObject;
|
||||
|
||||
public:
|
||||
|
||||
static double bearingTrueNorth( const QgsCoordinateReferenceSystem &crs,
|
||||
const QgsCoordinateTransformContext &transformContext,
|
||||
const QgsPointXY &point );
|
||||
const QgsCoordinateTransformContext &transformContext,
|
||||
const QgsPointXY &point );
|
||||
%Docstring
|
||||
Returns the direction to true north from a specified point and for a specified
|
||||
coordinate reference system. The returned value is in degrees clockwise from
|
||||
|
||||
@ -23,6 +23,7 @@ class QgsCoordinateTransformContext;
|
||||
class QgsPointXY;
|
||||
|
||||
#include "qgis_core.h"
|
||||
#include <QObject>
|
||||
|
||||
/**
|
||||
* \class QgsBearingUtils
|
||||
@ -32,6 +33,8 @@ class QgsPointXY;
|
||||
*/
|
||||
class CORE_EXPORT QgsBearingUtils
|
||||
{
|
||||
Q_GADGET
|
||||
|
||||
public:
|
||||
|
||||
/**
|
||||
@ -39,9 +42,9 @@ class CORE_EXPORT QgsBearingUtils
|
||||
* coordinate reference system. The returned value is in degrees clockwise from
|
||||
* vertical. An exception will be thrown if the bearing could not be calculated.
|
||||
*/
|
||||
static double bearingTrueNorth( const QgsCoordinateReferenceSystem &crs,
|
||||
const QgsCoordinateTransformContext &transformContext,
|
||||
const QgsPointXY &point );
|
||||
Q_INVOKABLE static double bearingTrueNorth( const QgsCoordinateReferenceSystem &crs,
|
||||
const QgsCoordinateTransformContext &transformContext,
|
||||
const QgsPointXY &point );
|
||||
|
||||
};
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user