Maps API for JavaScript Developer's Guide

H.map.Icon.Options

Type Definition Summary

Options used to initialize an Icon object.

[ For full details, see the Type Definition Details ]

Property Summary

Table 1. Properties
Properties

size

The size in pixels of the icon, the default is the natural size of the bitmap

anchor

The anchorage point in pixels, the default is bottom-center

hitArea

The area to use for hit detection. If omitted the whole rectangular area of the icon is used. If specified, the top-left corner of the icon area is used as origin for the coordinates of the hitArea.

crossOrigin

The value to use for the crossOrigin attribute of the icon image, if omitted the attribute is set to "anonymous". For more details see MDN web docs.

Type Definition Description

Options used to initialize an Icon object.

Property Details

size: {H.math.ISize=} [optional]

The size in pixels of the icon, the default is the natural size of the bitmap

anchor: {H.math.IPoint=} [optional]

The anchorage point in pixels, the default is bottom-center

hitArea: {H.map.HitArea=} [optional]

The area to use for hit detection. If omitted the whole rectangular area of the icon is used. If specified, the top-left corner of the icon area is used as origin for the coordinates of the hitArea.

crossOrigin: {?string=} [optional]

The value to use for the crossOrigin attribute of the icon image, if omitted the attribute is set to "anonymous". For more details see MDN web docs.