Package-level declarations

Types

Link copied to clipboard

A state object that can be hoisted to control and observe the map's camera state. A CameraPositionState may only be used by a single YandexMap composable at a time as it reflects instance state for a single view of a map.

Link copied to clipboard
class CircleState(geometry: Circle)
Link copied to clipboard
data class ClusterGroup(val placemarks: ImmutableList<ClusterItem>, val icon: ImageProvider, val iconStyle: IconStyle = IconStyle(), val text: String? = null, val textStyle: TextStyle = TextStyle())
Link copied to clipboard
actual class ClusterImageProvider(size: <Error class: unknown class>, renderer: ComposeMapObjectRenderer, content: (<Error class: unknown class>) -> Unit)
Link copied to clipboard
data class ClusterItem(val geometry: Point, val data: Any? = null)
Link copied to clipboard
data class ClusterizingConfig(val clusterRadius: Double = DefaultClusterRadius, val minZoom: Int = DefaultMinZoom)
Link copied to clipboard
actual class ComposeMapObjectRenderer(density: <Error class: unknown class>)
Link copied to clipboard
data class MapConfig(val isNightModeEnabled: Boolean? = null, val poiLimit: Int? = null, val isFastTapEnabled: Boolean? = null, val isRotateGesturesEnabled: Boolean? = null, val isTiltGesturesEnabled: Boolean? = null, val isScrollGesturesEnabled: Boolean? = null, val isZoomGesturesEnabled: Boolean? = null, val mapType: MapType? = null, val use2dMode: Boolean? = null, val logo: MapLogoConfig = MapLogoConfig())

Config for Map that uses default configuration

Link copied to clipboard
data class MapLogoConfig(val alignment: LogoAlignment? = null, val padding: LogoPadding? = null)

Config to control Yandex logo object with Map.getLogo

Link copied to clipboard
class PlacemarkState(geometry: Point, direction: Float = 0.0f)
Link copied to clipboard
class PolygonState(geometry: Polygon)
Link copied to clipboard
Link copied to clipboard

Marks declarations that runs in custom MapComposition, outside compose-ui composition context.

Link copied to clipboard

Contains common implementation of MapWindow, that uses for controlling YandexMap

Link copied to clipboard

Marks declarations that are still experimental.

Properties

Functions

Link copied to clipboard
fun MapKit.bindToLifecycleOwner(lifecycleOwner: LifecycleOwner = LocalLifecycleOwner.current)

Bind calling MapKit.onStart and MapKit.onStop to LifecycleOwner and composition

Link copied to clipboard
fun Circle(state: CircleState, color: Color = DefaultFillColor, strokeColor: Color = DefaultStrokeColor, strokeWidth: Float = DefaultStrokeWidth, geodesic: Boolean = DefaultGeodesic, visible: Boolean = true, zIndex: Float = 0.0f, onTap: (Point) -> Boolean? = null)
Link copied to clipboard
fun ClusterGroup(points: List<Point>, icon: ImageProvider, iconStyle: IconStyle = IconStyle(), text: String? = null, textStyle: TextStyle = TextStyle()): ClusterGroup
Link copied to clipboard
Link copied to clipboard
fun Clustering(groups: ImmutableList<ClusterGroup>, icon: ClusterImageProvider, iconStyle: IconStyle = IconStyle(), config: ClusterizingConfig = ClusterizingConfig(), onItemTap: (ClusterItem) -> Boolean? = null, onClusterTap: (Cluster) -> Boolean? = null, visible: Boolean = true, zIndex: Float = 0.0f)
fun Clustering(groups: ImmutableList<ClusterGroup>, icon: ImageProvider, iconStyle: IconStyle = IconStyle(), config: ClusterizingConfig = ClusterizingConfig(), onItemTap: (ClusterItem) -> Boolean? = null, onClusterTap: (Cluster) -> Boolean? = null, visible: Boolean = true, zIndex: Float = 0.0f)
fun Clustering(group: ClusterGroup, icon: ClusterImageProvider, iconStyle: IconStyle = IconStyle(), config: ClusterizingConfig = ClusterizingConfig(), onItemTap: (ClusterItem) -> Boolean? = null, onClusterTap: (Cluster) -> Boolean? = null, visible: Boolean = true, zIndex: Float = 0.0f)
fun Clustering(group: ClusterGroup, icon: ImageProvider, iconStyle: IconStyle = IconStyle(), config: ClusterizingConfig = ClusterizingConfig(), onItemTap: (ClusterItem) -> Boolean? = null, onClusterTap: (Cluster) -> Boolean? = null, visible: Boolean = true, zIndex: Float = 0.0f)
fun Clustering(groups: ImmutableList<ClusterGroup>, contentSize: DpSize, iconStyle: IconStyle = IconStyle(), config: ClusterizingConfig = ClusterizingConfig(), onItemTap: (ClusterItem) -> Boolean? = null, onClusterTap: (Cluster) -> Boolean? = null, visible: Boolean = true, zIndex: Float = 0.0f, content: @Composable (Cluster) -> Unit)
fun Clustering(group: ClusterGroup, contentSize: DpSize, iconStyle: IconStyle = IconStyle(), config: ClusterizingConfig = ClusterizingConfig(), onItemTap: (ClusterItem) -> Boolean? = null, onClusterTap: (Cluster) -> Boolean? = null, visible: Boolean = true, zIndex: Float = 0.0f, content: @Composable (Cluster) -> Unit)
Link copied to clipboard
Link copied to clipboard
fun MapControllerEffect(controller: YandexMapController, dispose: (MapWindow) -> Unit = {}, block: (MapWindow) -> Unit)
fun MapControllerEffect(controller: YandexMapController, key1: Any?, dispose: (MapWindow) -> Unit = {}, block: (MapWindow) -> Unit)
fun MapControllerEffect(controller: YandexMapController, vararg keys: Any?, dispose: (MapWindow) -> Unit = {}, block: (MapWindow) -> Unit)
fun MapControllerEffect(controller: YandexMapController, key1: Any?, key2: Any?, dispose: (MapWindow) -> Unit = {}, block: (MapWindow) -> Unit)
fun MapControllerEffect(controller: YandexMapController, key1: Any?, key2: Any?, key3: Any?, dispose: (MapWindow) -> Unit = {}, block: (MapWindow) -> Unit)
Link copied to clipboard
fun MapEffect(key1: Any?, block: suspend CoroutineScope.(Map) -> Unit)

A side-effect backed by a LaunchedEffect which will launch block and provide the underlying managed YandexMap object into the composition's CoroutineContext. This effect will be re-launched when a different key1 is provided.

fun MapEffect(vararg keys: Any?, block: suspend CoroutineScope.(Map) -> Unit)

A side-effect backed by a LaunchedEffect which will launch block and provide the underlying managed YandexMap object into the composition's CoroutineContext. This effect will be re-launched when a different keys is provided.

fun MapEffect(key1: Any?, key2: Any?, block: suspend CoroutineScope.(Map) -> Unit)

A side-effect backed by a LaunchedEffect which will launch block and provide the underlying managed YandexMap object into the composition's CoroutineContext. This effect will be re-launched when a different key1 or key2 is provided.

fun MapEffect(key1: Any?, key2: Any?, key3: Any?, block: suspend CoroutineScope.(Map) -> Unit)

A side-effect backed by a LaunchedEffect which will launch block and provide the underlying managed YandexMap object into the composition's CoroutineContext. This effect will be re-launched when a different key1, key2 or key3 is provided.

Link copied to clipboard
fun Placemark(state: PlacemarkState, icon: ImageProvider, iconStyle: IconStyle = IconStyle(), onTap: (Point) -> Boolean? = null, visible: Boolean = true, draggable: Boolean = false, zIndex: Float = 0.0f, opacity: Float = 1.0f)
fun Placemark(state: PlacemarkState, contentSize: DpSize, iconStyle: IconStyle = IconStyle(), visible: Boolean = true, draggable: Boolean = false, zIndex: Float = 0.0f, opacity: Float = 1.0f, onTap: (Point) -> Boolean? = null, content: @Composable () -> Unit)
Link copied to clipboard
fun Polygon(state: PolygonState, color: Color = DefaultFillColor, strokeColor: Color = DefaultStrokeColor, strokeWidth: Float = DefaultStrokeWidth, geodesic: Boolean = DefaultGeodesic, pattern: ImageProvider? = null, patternScale: Float = 1.0f, visible: Boolean = true, zIndex: Float = 0.0f, onTap: (Point) -> Boolean? = null)
Link copied to clipboard
fun Polyline(state: PolylineState, strokeColor: Color = DefaultStrokeColor, strokeWidth: Float = DefaultStrokeWidth, gradientLength: Float = DefaultGradientLength, outlineWidth: Float = DefaulOutlineWidth, outlineColor: Color = DefaultOutlineColor, innerOutlineEnabled: Boolean = false, turnRadius: Float = DefaultTurnRadius, dashLength: Float = DefaultDashLength, gapLength: Float = DefaultGapLength, dashOffset: Float = DefaultDashOffset, visible: Boolean = true, zIndex: Float = 0.0f, onTap: (Point) -> Boolean? = null)
Link copied to clipboard

Remember global MapKit instance and initialize it on Android

Link copied to clipboard
inline fun rememberCameraPositionState(key: String? = null, crossinline init: CameraPositionState.() -> Unit = {}): CameraPositionState

Create and rememberSaveable a CameraPositionState using CameraPositionState.Saver. init will be called when the CameraPositionState is first created to configure its initial state.

Link copied to clipboard

Uses rememberSaveable to retain CircleState.geometry across configuration changes, for simple use cases.

Link copied to clipboard

Remember global MapKit instance

Link copied to clipboard
fun rememberPlacemarkState(geometry: Point, direction: Float = 0.0f, key: String? = null): PlacemarkState

Uses rememberSaveable to retain PlacemarkState.geometry and PlacemarkState.direction across configuration changes, for simple use cases.

Link copied to clipboard
Link copied to clipboard

Uses rememberSaveable to retain PolylineState.geometry across configuration changes, for simple use cases.

Link copied to clipboard

Create and remember YandexMapController. Don't pass to multiple YandexMap. Don't save it anywhere, contains native references.

Link copied to clipboard
fun TitledPlacemark(state: PlacemarkState, icon: ImageProvider, title: String, iconStyle: IconStyle = IconStyle(), titleStyle: TextStyle = TextStyle(), onTap: (Point) -> Boolean? = null, visible: Boolean = true, draggable: Boolean = false, zIndex: Float = 0.0f, opacity: Float = 1.0f)
Link copied to clipboard
Link copied to clipboard
fun <Error class: unknown class>.toUIImage(): <Error class: unknown class>
Link copied to clipboard
fun YandexMap(controller: YandexMapController = rememberYandexMapController(), modifier: Modifier = Modifier)
fun YandexMap(cameraPositionState: CameraPositionState = rememberCameraPositionState(), modifier: Modifier = Modifier, config: MapConfig = MapConfig(isNightModeEnabled = isSystemInDarkTheme()), content: @Composable () -> Unit = {})
fun YandexMap(locationState: UserLocationState, modifier: Modifier = Modifier, cameraPositionState: CameraPositionState = rememberCameraPositionState(), locationConfig: UserLocationConfig = UserLocationConfig(), config: MapConfig = MapConfig(isNightModeEnabled = isSystemInDarkTheme()), content: @Composable () -> Unit = {})