Layers
Last updated
Last updated
© flutter_map Authors & Maintainers
To display anything on the map, you'll need to include at least one "layer"!
Multiple layers can be used - similar to a Stack
- each one showing different data in different ways, from actual map tiles (Tile Layer) to shapes on top of them (Polygon Layer), and even just your own custom layers (Creating New Layers).
Each layer has its own configuration and handling, but can also access the map's state/configuration, as well as be controlled by it.
Layers are usually defined in the children
property of the FlutterMap
- as is with the TileLayer
, for example.
However, the nonRotatedChildren
property can be used for layers which shouldn't move with the map, but still require access to the map's state/configuration - for example, the AttributionLayer
s.
Do not use nonRotatedChildren
to enforce a non-rotatable map/TileLayer
.
Instead, use interactiveFlags
: . These apply to the entire map and all layers.