MapProxy

A read-only view onto the map's camera and geometry.

Safe to hand to a child composable or a view model that should read the map without mutating it: it exposes no setter and no method that changes map state. Camera writes go through the map view itself.

Read it fresh from WemapMapView.proxy when you need it — the values are a snapshot taken at access time, so storing a proxy buys nothing.

Snapshot capture and meters-per-pixel are deliberately left off: both are already reachable on the map view.

Properties

Link copied to clipboard

A snapshot of the map camera.

Link copied to clipboard

Whether the initial camera derived from the map data has been applied.

Link copied to clipboard
val visibleBounds: LatLngBounds

The coordinate bounds currently visible on screen.

Functions

Link copied to clipboard
fun cameraThatFits(bounds: LatLngBounds): MapCameraState?

Returns the camera that fits the given coordinate bounds, without moving the map.

Link copied to clipboard
fun fromScreenLocation(point: PointF): LatLng

Converts a point in the map view's coordinate system to a geographic coordinate.

Link copied to clipboard
fun toScreenLocation(coordinate: LatLng): PointF

Converts a geographic coordinate to a point in the map view's coordinate system.