StyleContainer

public struct StyleContainer
extension StyleContainer: Equatable

Allows main and dark styles to be set. If dark style is not provided, setting TomTomMap.styleMode has no effect.

Important

This is a Public Preview API. It may be changed or removed at any time.

Lifecycle

  • Creates a new instance that only provides a main style.

    Declaration

    Swift

    public init(mainStyle: StyleDefinition)

    Parameters

    style

    main style used by the map.

  • Creates a new instance with main and dark versions of the map style.

    Declaration

    Swift

    public init(mainStyle: StyleDefinition, darkStyle: StyleDefinition)

    Parameters

    mainStyle

    main style used by the map.

    darkStyle

    dark style used by the map.

Public

  • Defines a container containing a default light style and a default dark style.

    Declaration

    Swift

    public static let defaultStyle: StyleContainer
  • Defines a container containing a standard light driving style and a standard dark driving style.

    Declaration

    Swift

    public static let drivingStyle: StyleContainer

Equatable

  • Declaration

    Swift

    public static func == (lhs: StyleContainer, rhs: StyleContainer) -> Bool