MeeGo 1.2 Harmattan Developer Documentation Develop for the Nokia N9

QML MapImage Element

The MapImage element displays an image on a map. More...

This element was introduced in Mobility 1.2.

Properties

Detailed Description

The image loaded from source will be drawn offset.x and offset.y pixels away from the on-screen position of coordinate.

If source does not point to an image or coordinate is invalid nothing will be displayed.

The status of the image loading can be monitored via status.

An example of map image:

 MapImage {
     source:  "landmarkmapmobile/images/landmarkstar.png"
     coordinate: landmark.coordinate
 }

The MapImage element is part of the QtMobility.location 1.2 module.

Property Documentation

coordinate : Coordinate

This property holds the coordinate at which to anchor the image.

This property group was introduced in Mobility 1.2.


offset.x : int

offset.y : int

These properties hold the offset from the on-screen position of coordinate at which the image should be displayed.

They both default to 0.

This property group was introduced in Mobility 1.2.


source : url

This property holds the URL describing the location of the image to display.

The URL can be absolute or relative to where the QML file was loaded from, and can be a local file, a file embedded within a Qt Resource bundle, or a file retrieved from the network.

This property group was introduced in Mobility 1.2.


status : enumeration

This property holds the status of image loading. It can be one of:

  • MapImage.Null - no image has been set
  • MapImage.Ready - the image has been loaded
  • MapImage.Loading - the image is currently being loaded
  • MapImage.Error - an error occurred while loading the image

This property group was introduced in Mobility 1.2.


visible : bool

This property holds a boolean corresponding to whether or not the image is visible.

This property group was introduced in Mobility 1.2.


z : int

This property holds the z-value of the image.

Map objects are drawn in z-value order, and objects with the same z-value will be drawn in insertion order.

This property group was introduced in Mobility 1.2.