ScaleBarSettingsBase

abstract class ScaleBarSettingsBase : ScaleBarSettingsInterface

Abstract settings class for ScaleBarPlugin.

This abstract class exposes all the required public APIs to configure the ScaleBarPlugin.

Constructors

ScaleBarSettingsBase
Link copied to clipboard
fun ScaleBarSettingsBase()

Functions

getSettings
Link copied to clipboard
open override fun getSettings(): ScaleBarSettings

Get current scalebar configuration.

updateSettings
Link copied to clipboard
open override fun updateSettings(block: ScaleBarSettings.() -> Unit)

Update scalebar configuration, the update will be applied to the plugin automatically.

Properties

borderWidth
Link copied to clipboard
open override var borderWidth: Float

Defines width of the border for the scale bar.

enabled
Link copied to clipboard
open override var enabled: Boolean

Whether the scale is visible on the map.

height
Link copied to clipboard
open override var height: Float

Defines height of the scale bar.

isMetricUnits
Link copied to clipboard
open override var isMetricUnits: Boolean

Whether the scale bar is using metric unit. True if the scale bar is using metric system, false if the scale bar is using imperial units.

marginBottom
Link copied to clipboard
open override var marginBottom: Float

Defines the margin to the bottom that the scale bar honors.

marginLeft
Link copied to clipboard
open override var marginLeft: Float

Defines the margin to the left that the scale bar honors.

marginRight
Link copied to clipboard
open override var marginRight: Float

Defines the margin to the right that the scale bar honors.

marginTop
Link copied to clipboard
open override var marginTop: Float

Defines the margin to the top that the scale bar honors.

position
Link copied to clipboard
open override var position: Int

Defines where the scale bar is positioned on the map

primaryColor
Link copied to clipboard
open override var primaryColor: Int

Defines primary color of the scale bar.

ratio
Link copied to clipboard
open override var ratio: Float

configures ratio of scale bar max width compared with MapView width, default is 0.5.

refreshInterval
Link copied to clipboard
open override var refreshInterval: Long

Configures minimum refresh interval, in millisecond, default is 15.

secondaryColor
Link copied to clipboard
open override var secondaryColor: Int

Defines secondary color of the scale bar.

showTextBorder
Link copied to clipboard
open override var showTextBorder: Boolean

Configures whether to show the text border or not, default is true.

textBarMargin
Link copied to clipboard
open override var textBarMargin: Float

Defines margin of the text bar of the scale bar.

textBorderWidth
Link copied to clipboard
open override var textBorderWidth: Float

Defines text border width of the scale bar.

textColor
Link copied to clipboard
open override var textColor: Int

Defines text color of the scale bar.

textSize
Link copied to clipboard
open override var textSize: Float

Defines text size of the scale bar.

useContinuousRendering
Link copied to clipboard
open override var useContinuousRendering: Boolean

If set to True scale bar will be triggering onDraw depending on ScaleBarSettings.refreshInterval even if actual data did not change. If set to False scale bar will redraw only on demand. Defaults to False and should not be changed explicitly in most cases. Could be set to True to produce correct GPU frame metrics when running gfxinfo command.

Inheritors

ScaleBarPluginImpl
Link copied to clipboard