osm_flutter
osm_flutter copied to clipboard
MarkerIcon don't always render
Sometimes the marker icon wouldn't render and this is shown instead:
It is placed on the geopoint instead of the pin, so it moves when you interact with the map. This happens sometimes, but most of the time it shows the pin correctly. Even though sometimes it is more 50/50 if the pin renders correctly or not.
Here is what is what I used trying to render a pin when getting this bug. (The reason I use a column of two pins where the bottom is not visible is because of #421.
staticPoints: [
StaticPositionGeoPoint(
"id",
const MarkerIcon(
iconWidget: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Icon(
CupertinoIcons.map_pin,
size: iconSize,
),
Visibility(
visible: false,
maintainSize: true,
maintainAnimation: true,
maintainState: true,
child: Icon(
CupertinoIcons.map_pin,
size: iconSize,
),
),
],
),
),
[GeoPoint(latitude: widget.latitude, longitude: widget.longitude)],
),
],