Positioning (QML)Location PositioningLocation data involves a precisely specified position on the Earth's surface — as provided by a latitude-longitude coordinate — along with associated data, such as:
This data can be extracted through a variety of methods. One of the most well known methods of positioning is GPS (Global Positioning System), a publicly available system that uses radiowave signals received from Earth-orbiting satellites to calculate the precise position and time of the receiver. Another popular method is 'Cell Identifier Positioning', which uses the cell identifier of the cell site that is currently serving the receiving device to calculate its approximate location. These and other positioning methods can all be used with the Location API; the only requirement for a location data source within the API is that it provides a latitude-longitude coordinate with a date/time value, with the option of providing the other attributes listed above. Example: Centering the Map on the Current PositionHere is an example of a client that uses a position source to center a map on the current position: Rectangle { import QtLocation 5.0 ... map : Map { // initialize map ... } PositionSource { onPositionChanged: { // center the map on the current position map.center = position.coordinate } } } Flickr ExampleThe Flickr Example uses the Location to download thumbnail images from Flickr relevant to the current location. Position QML Components
|