Marker Layer
You can add single point features - such as pins, labels, or markers - to maps using MarkerLayer
and Marker
s.
No more image only markers! Unlike other popular mapping libraries, we allow usage of any widget as the marker.
Excessive use of markers may create performance issues.
Consider using a clustering plugin to merge nearby markers together, reducing the work that needs to be done when rendering: Marker Clustering.
Alignment
The marker widget will be centered over the geographic coordinate by default. However, this can be changed with the alignment
argument, which aligns the widget relative to the point.
The center of rotation when rotate
is true
will be the point.
The default alignment for all Marker
s within a MarkerLayer
can be set by changing the same property on the MarkerLayer
.
Rotation
It is possible to enable the Marker
to automatically counter-rotate to the camera's rotation, to ensure it remains facing upwards, via the rotate
argument.
The default alignment for all Marker
s within a MarkerLayer
can be set by changing the same property on the MarkerLayer
.
There is no built-in support to rotate markers to a specific degree. However, this is easy to implement through a rotating widget, such as Transform.rotate
.
Handling Gestures
There is no built-in support to handle gestures on Marker
s, such as taps. However, this is easy to implement using a standard GestureDetector
.
Last updated