QtPositioning QML Type

The QtPositioning global object provides useful functions for working with location-based types in QML. More...

Import Statement: import QtPositioning

Methods

Detailed Description

 import QtPositioning

 Item {
     property var coordinate: QtPositioning.coordinate(-27.5, 153.1)
 }

Method Documentation

geoCircle circle()

Constructs an invalid geoCircle.

See also geoCircle.

geoCircle circle(coordinate center, real radius)

Constructs a geoCircle centered at center with a radius of radius meters.

point coordToMercator(coordinate coord)

Converts a coordinate coord into a mercator coordinate and returns it.

See also mercatorToCoord.

coordinate coordinate()

Constructs an invalid coordinate.

coordinate coordinate(real latitude, real longitude, real altitude)

Constructs a coordinate with the specified latitude, longitude and optional altitude. Both latitude and longitude must be valid, otherwise an invalid coordinate is returned.

See also coordinate.

coordinate mercatorToCoord(point mercator)

Converts a mercator coordinate into a latitude-longitude coordinate.

See also coordToMercator.

geoPath path()

Constructs an empty geoPath.

See also geoPath.

geoPath path(list<coordinate> coordinates, real width)

Constructs a geoPath from coordinates and width.

See also geoPath.

geoPolygon polygon()

Constructs an empty polygon.

See also geoPolygon.

geoPolygon polygon(list<coordinate> coordinates)

Constructs a polygon from coordinates.

See also geoPolygon.

geoPolygon polygon(list<coordinate> perimeter, list<list<coordinate>> holes)

Constructs a polygon from coordinates for perimeter and inner holes.

See also geoPolygon.

geoRectangle rectangle()

Constructs an invalid geoRectangle.

See also geoRectangle.

geoRectangle rectangle(list<coordinate> coordinates)

Constructs a geoRectangle from the list of coordinates, the returned list is the smallest possible containing all the coordinates.

See also geoRectangle.

geoRectangle rectangle(coordinate topLeft, coordinate bottomRight)

Constructs a geoRectangle with its top left corner positioned at topLeft and its bottom right corner positioned at bottomRight.

See also geoRectangle.

geoRectangle rectangle(coordinate center, real width, real height)

Constructs a geoRectangle centered at center with a width of width degrees and a hight of height degrees.

See also geoRectangle.

geoShape shape()

Constructs an invalid geoShape.

See also geoShape.

geoCircle shapeToCircle(geoShape shape)

Converts shape to a geoCircle.

See also geoCircle.

geoPath shapeToPath(geoShape shape)

Converts shape to a geoPath.

See also geoPath.

geoPolygon shapeToPolygon(geoShape shape)

Converts shape to a polygon.

See also geoPolygon.

geoRectangle shapeToRectangle(geoShape shape)

Converts shape to a geoRectangle.

See also geoRectangle.