UserLocationViewStyles
public struct UserLocationViewStyles : Equatable
A struct containing information about the user location view style for each state.
-
The struct containing information about the user location view style for normal state.
Default is
UserLocationViewStateStyle()Declaration
Swift
public let normal: UserLocationViewStateStyle -
The struct containing information about the user location view style for stale state.
Default is
UserLocationViewStateStyle(foregroundColor: .gray, headingColor: .gray)Declaration
Swift
public let stale: UserLocationViewStateStyle -
The opacity for user location view when the user is out of the currently active level. Set any value between 0.0 and 1.0.
Default is
0.5Declaration
Swift
public let outOfActiveLevelOpacity: Float -
The color to use as the accuracy view color property.
Default is
.blueDeclaration
Swift
public let accuracyColor: UIColor -
The opacity of the accuracy view to a value from 0 to 1, where 0 means the accuracy view is completely transparent and 1 means the view is completely opaque.
Default is
0.15Declaration
Swift
public let accuracyAlpha: Float -
Enable or disable the pulsing circle.
Default is
falseDeclaration
Swift
public let pulseEnabled: Bool -
The color of the pulsing circle.
Default is
.blueDeclaration
Swift
public let pulseColor: UIColor -
The opacity of the pulsing circle. The expected range is 0 to 1. An opacity of 1 makes the layer fully visible.
Default is
0.4Declaration
Swift
public let pulseAlpha: Float -
init(normal:stale: outOfActiveLevelOpacity: accuracyColor: accuracyAlpha: pulseEnabled: pulseColor: pulseAlpha: ) Initializes a new user location view styles with the specified parameters.
Declaration
Swift
public init( normal: UserLocationViewStateStyle = .init(), stale: UserLocationViewStateStyle = .init(foregroundColor: .gray, headingColor: .gray), outOfActiveLevelOpacity: Float = 0.5, accuracyColor: UIColor = .blue, accuracyAlpha: Float = 0.15, pulseEnabled: Bool = false, pulseColor: UIColor = .blue, pulseAlpha: Float = 0.4 )Parameters
normalThe struct containing information about the user location view style for normal state. Default is
UserLocationViewStateStyle()staleThe struct containing information about the user location view style for stale state. Default is
UserLocationViewStateStyle(foregroundColor: .gray, headingColor: .gray)outOfActiveLevelOpacityThe opacity for user location view when the user is out of the currently active level. Set any value between 0.0 and 1.0. Default is
0.5accuracyColorThe color to use as the accuracy view color property. Default is
.blueaccuracyAlphaThe opacity of the accuracy view to a value from 0 to 1, where 0 means the accuracy view is completely transparent and 1 means the view is completely opaque. Default is
0.15pulseEnabledEnable or disable the pulsing circle. Default is
falsepulseColorThe color of the pulsing circle. Default is
.bluepulseAlphaThe opacity of the pulsing circle. The expected range is 0 to 1. An opacity of 1 makes the layer fully visible. Default is
0.4
View on GitHub