Skip to content

HighlightBuilder

Defined in: map/highlight.ts:47

Builder handed to custom hover/highlight draw fns, scoped to ONE source drawable. Everything recorded lands in the overlay group (drawn on top, inheriting the source layer’s clipTo/sizeMode). World coordinates throughout. Geometry comes from the Scene’s already-projected subpaths/circles — no re-projection, no datum re-processing.

new HighlightBuilder(g, d, colors): HighlightBuilder

Defined in: map/highlight.ts:53

GroupBuilder

DrawableVector

PendingColor[]

HighlightBuilder

readonly anchor: [number, number] | null

Defined in: map/highlight.ts:49

The drawable’s glyph anchor, or a point feature’s projected center; null for plain paths.

defaultHighlight(): void

Defined in: map/highlight.ts:111

The hover: true default: a white outline for paths (fill stays transparent so translucent bases don’t compound); a stroked ring just outside circle drawables (circles themselves are fill-only so a ring is drawn separately).

void


path(draw, style?): void

Defined in: map/highlight.ts:95

Record an arbitrary path (standard PathContext: moveTo/lineTo/arc/rect/…). Note: a stroke is only visible when style.lineWidth > 0 (backends suppress zero-width strokes).

(ctx) => void

HighlightStyle = {}

void


point(x, y, radius, style?): void

Defined in: map/highlight.ts:102

A filled circle at world (x, y).

number

number

number

string

void


replay(style?): void

Defined in: map/highlight.ts:67

Re-emit the source drawable’s geometry with new styling. Omitted fill/stroke keep the source’s current colors (note: a translucent base fill re-drawn on top of itself compounds — pass an explicit fill to avoid that).

HighlightStyle = {}

void