Class: MapWaypointHighlightIcon<T>
Defined in: src/garminsdk/components/map/MapWaypointIcon.ts:71
An icon for a highlighted waypoint. This icon embellishes a pre-existing ("base") icon with a surrounding ring and background.
Extends
Type Parameters
| Type Parameter |
|---|
T extends Waypoint |
Constructors
Constructor
new MapWaypointHighlightIcon<
T>(baseIcon,priority,options?):MapWaypointHighlightIcon<T>
Defined in: src/garminsdk/components/map/MapWaypointIcon.ts:97
Constructor.
Parameters
| Parameter | Type | Description |
|---|---|---|
baseIcon | AbstractMapWaypointIcon<T> | This icon's base waypoint icon. |
priority | number | Subscribable<number> | The render priority of this icon. Icons with higher priorities should be rendered above those with lower priorities. |
options? | MapWaypointHighlightIconOptions | Options with which to initialize this icon. |
Returns
MapWaypointHighlightIcon<T>
Overrides
AbstractMapWaypointIcon.constructor
Properties
anchor
readonlyanchor:Subscribable<Readonly<Omit<Float64Array<ArrayBufferLike>,"set"|"sort"|"copyWithin">>>
Defined in: src/sdk/components/map/MapWaypointIcon.ts:86
The anchor point of this icon, expressed relative to its width and height. [0, 0] is the top-left corner, and [1, 1] is the bottom-right corner.
Inherited from
AbstractMapWaypointIcon.anchor
bgColor
readonlybgColor:Subscribable<string>
Defined in: src/garminsdk/components/map/MapWaypointIcon.ts:88
The color of this icon's ring background.
offset
readonlyoffset:Subscribable<Readonly<Omit<Float64Array<ArrayBufferLike>,"set"|"sort"|"copyWithin">>>
Defined in: src/sdk/components/map/MapWaypointIcon.ts:89
The offset of this icon from the projected position of its associated waypoint, as [x, y] in pixels.
Inherited from
AbstractMapWaypointIcon.offset
outlineColor
readonlyoutlineColor:Subscribable<string>
Defined in: src/garminsdk/components/map/MapWaypointIcon.ts:85
The color of the outline for this icon's ring.
outlineWidth
readonlyoutlineWidth:Subscribable<number>
Defined in: src/garminsdk/components/map/MapWaypointIcon.ts:82
The width of the outline for this icon's ring, in pixels.
priority
readonlypriority:Subscribable<number>
Defined in: src/sdk/components/map/MapWaypointIcon.ts:77
The render priority of this icon. Icons with higher priorities will be rendered on top of icons with lower priorities.
Inherited from
AbstractMapWaypointIcon.priority
ringRadiusBuffer
readonlyringRadiusBuffer:Subscribable<number>
Defined in: src/garminsdk/components/map/MapWaypointIcon.ts:73
The buffer of the ring around this icon's base icon, in pixels.
size
readonlysize:Subscribable<Readonly<Omit<Float64Array<ArrayBufferLike>,"set"|"sort"|"copyWithin">>>
Defined in: src/sdk/components/map/MapWaypointIcon.ts:80
The size of this icon, as [width, height] in pixels.
Inherited from
strokeColor
readonlystrokeColor:Subscribable<string>
Defined in: src/garminsdk/components/map/MapWaypointIcon.ts:79
The color of the stroke for this icon's ring.
strokeWidth
readonlystrokeWidth:Subscribable<number>
Defined in: src/garminsdk/components/map/MapWaypointIcon.ts:76
The width of the stroke for this icon's ring, in pixels.
waypoint
readonlywaypoint:T
Defined in: src/sdk/components/map/MapWaypointIcon.ts:100
The waypoint associated with this icon.
Inherited from
AbstractMapWaypointIcon.waypoint
tempVec2
protectedreadonlystatictempVec2:Float64Array<ArrayBuffer>
Defined in: src/sdk/components/map/MapWaypointIcon.ts:74
Inherited from
AbstractMapWaypointIcon.tempVec2
Methods
draw()
draw(
context,mapProjection):void
Defined in: src/sdk/components/map/MapWaypointIcon.ts:113
Renders this icon to a canvas.
Parameters
| Parameter | Type | Description |
|---|---|---|
context | CanvasRenderingContext2D | The canvas 2D rendering context to which to render. |
mapProjection | MapProjection | The projection to use for rendering. |
Returns
void
Inherited from
drawIconAt()
protecteddrawIconAt(context,mapProjection,left,top):void
Defined in: src/garminsdk/components/map/MapWaypointIcon.ts:113
Draws the icon at the specified position.
Parameters
| Parameter | Type | Description |
|---|---|---|
context | CanvasRenderingContext2D | The canvas rendering context to use. |
mapProjection | MapProjection | The map projection to use. |
left | number | The x-coordinate of the left edge of the icon. |
top | number | The y-coordinate of the top edge of the icon. |
Returns
void