LzAnnotationConfiguration
data class LzAnnotationConfiguration(val id: String, val coordinate: LatLng, val floorId: String? = null, val imageUrl: String? = null, val imageRef: String? = null, val imageBitmap: Bitmap? = null, val text: String? = null, val textColor: String? = null, val textFontSize: Float = 12.0f, val textPosition: TextPosition = TextPosition.TOP, val textHaloColor: String? = null, val textHaloWidth: Float = 1.0f, val textHaloBlur: Float = 0.0f, val textBackgroundColor: String? = null, val iconColor: String? = null, val iconSize: Float = 1.0f, val iconCornerRadius: Float = -1f, val borderColor: String? = null, val opacity: Float = 1.0f, val draggable: Boolean = false, val isFlat: Boolean = false, val rawBitmapSize: Boolean = false)Comprehensive configuration for a map annotation (marker), providing iOS-parity customization options for icon styling, text rendering, and behavior.
This class mirrors the iOS SDK’s LZAnnotationConfiguration, enabling full control over marker appearance including icon tinting, corner radius, background color, text halo effects, and opacity.
Use LzAnnotationConfigurationBuilder for a fluent construction API.
See also
| LzAnnotationConfigurationBuilder |
LazarilloMap.addAnnotationWith |
Constructors
LzAnnotationConfiguration | constructor(id: String , coordinate: LatLng, floorId: String ? = null, imageUrl: String ? = null, imageRef: String ? = null, imageBitmap: Bitmap ? = null, text: String ? = null, textColor: String ? = null, textFontSize: Float = 12.0f, textPosition: TextPosition = TextPosition.TOP, textHaloColor: String ? = null, textHaloWidth: Float = 1.0f, textHaloBlur: Float = 0.0f, textBackgroundColor: String ? = null, iconColor: String ? = null, iconSize: Float = 1.0f, iconCornerRadius: Float = -1f, borderColor: String ? = null, opacity: Float = 1.0f, draggable: Boolean = false, isFlat: Boolean = false, rawBitmapSize: Boolean = false) |
Types
| Name | Summary |
|---|---|
Companion | object Companion |
Properties
borderColor
val borderColor: String? = nullCSS-style hex color for a background drawn behind the icon.
coordinate
val coordinate: LatLngTypes: LatLng
Geographic coordinate where the annotation is placed.
draggable
val draggable: Boolean = falseWhether the annotation can be dragged by the user.
floorId
val floorId: String? = nullIndoor floor identifier. Null for outdoor or floor-independent annotations.
iconColor
val iconColor: String? = nullCSS-style hex color to tint the icon bitmap.
iconCornerRadius
val iconCornerRadius: FloatCorner radius for icon shape: -1=circle, 0=square, >0=rounded.
iconSize
val iconSize: Float = 1.0fScaling factor for the icon (1.0 = original size).
id
val id: StringUnique identifier for this annotation.
imageBitmap
val imageBitmap: Bitmap? = nullPre-created bitmap to use as the marker icon.
imageRef
val imageRef: String? = nullDrawable resource name to use as the marker icon.
imageUrl
val imageUrl: String? = nullURL to load a remote image for the marker icon.
isFlat
val isFlat: Boolean = falseWhether the annotation lies flat on the map surface.
opacity
val opacity: Float = 1.0fOpacity from 0.0 (transparent) to 1.0 (opaque).
rawBitmapSize
val rawBitmapSize: Boolean = falseWhen true, the imageBitmap is added to the map style at its original pixel size instead of being normalized to MapConstants.DEFAULT_ICON_SIZE. Use this for pre-rendered callout/tooltip bitmaps whose aspect ratio and resolution should be preserved exactly.
text
val text: String? = nullText label displayed alongside the marker.
textBackgroundColor
val textBackgroundColor: String? = nullCSS-style hex color for a solid background behind the text label. Rendered using a large text halo with zero blur to simulate a filled background. When set, overrides textHaloColor and textHaloWidth.
textColor
val textColor: String? = nullCSS-style hex color for the text label (e.g., “#000000”).
textFontSize
val textFontSize: Float = 12.0fFont size in pixels for the text label.
textHaloBlur
val textHaloBlur: Float = 0.0fBlur radius in pixels for the text halo.
textHaloColor
val textHaloColor: String? = nullCSS-style hex color for the text halo (outline).
textHaloWidth
val textHaloWidth: Float = 1.0fWidth in pixels of the text halo.
textPosition
val textPosition: TextPositionTypes: TextPosition
Position of the text label relative to the icon.