BackgroundLayer

class BackgroundLayer(layerId: String) : Layer, BackgroundLayerDsl

The background color or pattern of the map.

See also

Parameters

layerId

the ID of the layer

Constructors

BackgroundLayer
Link copied to clipboard
fun BackgroundLayer(layerId: String)

Types

Companion
Link copied to clipboard
object Companion

Static variables and methods.

Functions

backgroundColor
Link copied to clipboard
open override fun backgroundColor(backgroundColor: Expression): BackgroundLayer
open override fun backgroundColor(@ColorInt backgroundColor: Int): BackgroundLayer
open override fun backgroundColor(backgroundColor: String): BackgroundLayer

The color with which the background will be drawn.

backgroundColorTransition
Link copied to clipboard
open override fun backgroundColorTransition(options: StyleTransition): BackgroundLayer

Set the BackgroundColor property transition options

open override fun backgroundColorTransition(block: StyleTransition.Builder.() -> Unit): BackgroundLayer
backgroundOpacity
Link copied to clipboard
open override fun backgroundOpacity(backgroundOpacity: Expression): BackgroundLayer
open override fun backgroundOpacity(backgroundOpacity: Double): BackgroundLayer

The opacity at which the background will be drawn.

backgroundOpacityTransition
Link copied to clipboard
open override fun backgroundOpacityTransition(options: StyleTransition): BackgroundLayer

Set the BackgroundOpacity property transition options

open override fun backgroundOpacityTransition(block: StyleTransition.Builder.() -> Unit): BackgroundLayer
backgroundPattern
Link copied to clipboard
open override fun backgroundPattern(backgroundPattern: Expression): BackgroundLayer
open override fun backgroundPattern(backgroundPattern: String): BackgroundLayer

Name of image in sprite to use for drawing an image background. For seamless patterns, image width and height must be a factor of two (2, 4, 8, ..., 512). Note that zoom-dependent expressions will be evaluated only at integer zoom levels.

backgroundPatternTransition
Link copied to clipboard
open override fun backgroundPatternTransition(options: StyleTransition): BackgroundLayer

Set the BackgroundPattern property transition options

open override fun backgroundPatternTransition(block: StyleTransition.Builder.() -> Unit): BackgroundLayer
bindTo
Link copied to clipboard
fun bindTo(delegate: StyleInterface)

Bind the layer to the Style.

open override fun bindTo(delegate: StyleInterface, position: LayerPosition?)

Bind the layer to the map controller.

maxZoom
Link copied to clipboard
open override fun maxZoom(maxZoom: Double): BackgroundLayer

The maximum zoom level for the layer. At zoom levels equal to or greater than the maxzoom, the layer will be hidden.

minZoom
Link copied to clipboard
open override fun minZoom(minZoom: Double): BackgroundLayer

The minimum zoom level for the layer. At zoom levels less than the minzoom, the layer will be hidden.

visibility
Link copied to clipboard
open override fun visibility(visibility: Visibility): BackgroundLayer

Whether this layer is displayed.

Properties

backgroundColor
Link copied to clipboard
val backgroundColor: String?

The color with which the background will be drawn.

backgroundColorAsColorInt
Link copied to clipboard
val backgroundColorAsColorInt: Int?

The color with which the background will be drawn.

backgroundColorAsExpression
Link copied to clipboard
val backgroundColorAsExpression: Expression?

The color with which the background will be drawn.

backgroundColorTransition
Link copied to clipboard
val backgroundColorTransition: StyleTransition?

Transition options for BackgroundColor.

backgroundOpacity
Link copied to clipboard
val backgroundOpacity: Double?

The opacity at which the background will be drawn.

backgroundOpacityAsExpression
Link copied to clipboard
val backgroundOpacityAsExpression: Expression?

The opacity at which the background will be drawn.

backgroundOpacityTransition
Link copied to clipboard
val backgroundOpacityTransition: StyleTransition?

Transition options for BackgroundOpacity.

backgroundPattern
Link copied to clipboard
val backgroundPattern: String?

Name of image in sprite to use for drawing an image background. For seamless patterns, image width and height must be a factor of two (2, 4, 8, ..., 512). Note that zoom-dependent expressions will be evaluated only at integer zoom levels.

backgroundPatternAsExpression
Link copied to clipboard
val backgroundPatternAsExpression: Expression?

Name of image in sprite to use for drawing an image background. For seamless patterns, image width and height must be a factor of two (2, 4, 8, ..., 512). Note that zoom-dependent expressions will be evaluated only at integer zoom levels.

backgroundPatternTransition
Link copied to clipboard
val backgroundPatternTransition: StyleTransition?

Transition options for BackgroundPattern.

layerId
Link copied to clipboard
open override val layerId: String
maxZoom
Link copied to clipboard
open override val maxZoom: Double?

The maximum zoom level for the layer. At zoom levels equal to or greater than the maxzoom, the layer will be hidden.

minZoom
Link copied to clipboard
open override val minZoom: Double?

The minimum zoom level for the layer. At zoom levels less than the minzoom, the layer will be hidden.

visibility
Link copied to clipboard
open override val visibility: Visibility?

Whether this layer is displayed.