Other Enumerations
MGLAnnotationVerticalAlignment
enum MGLAnnotationVerticalAlignment : NSUInteger {}
The vertical alignment of an annotation within a map view. Used with
MGLMapView.userLocationVerticalAlignment
.
-
MGLAnnotationVerticalAlignmentCenter
Aligns the annotation vertically in the center of the map view.
Declaration
Objective-C
MGLAnnotationVerticalAlignmentCenter = 0
Swift
case center = 0
-
MGLAnnotationVerticalAlignmentTop
Aligns the annotation vertically at the top of the map view.
Declaration
Objective-C
MGLAnnotationVerticalAlignmentTop
Swift
case top = 1
-
MGLAnnotationVerticalAlignmentBottom
Aligns the annotation vertically at the bottom of the map view.
Declaration
Objective-C
MGLAnnotationVerticalAlignmentBottom
Swift
case bottom = 2
MGLAnnotationViewDragState
enum MGLAnnotationViewDragState : NSUInteger {}
These constants indicate the current drag state of an annotation view.
-
MGLAnnotationViewDragStateNone
The view is not involved in a drag operation.
Declaration
Objective-C
MGLAnnotationViewDragStateNone = 0
Swift
case none = 0
-
MGLAnnotationViewDragStateStarting
An action occurred that indicated the view should begin dragging.
The map view automatically moves draggable annotation views to this state in response to the dragging the view after pressing and holding on it.
Declaration
Objective-C
MGLAnnotationViewDragStateStarting
Swift
case starting = 1
-
MGLAnnotationViewDragStateDragging
The view is in the midst of a drag operation and is actively tracking the user’s gesture.
Declaration
Objective-C
MGLAnnotationViewDragStateDragging
Swift
case dragging = 2
-
MGLAnnotationViewDragStateCanceling
An action occurred that indicated the view should cancel the drag operation.
Declaration
Objective-C
MGLAnnotationViewDragStateCanceling
Swift
case canceling = 3
-
MGLAnnotationViewDragStateEnding
An action occurred that indicated the view was dropped by the user.
The map view automatically moves annotation views to this state in response to the user lifting their finger at the end of a drag gesture.
Declaration
Objective-C
MGLAnnotationViewDragStateEnding
Swift
case ending = 4
MGLAttributionInfoStyle
enum MGLAttributionInfoStyle : NSUInteger {}
The attribution info is represented in the longest format available.
-
MGLAttributionInfoStyleShort
Specifies a short attribution info style.
Declaration
Objective-C
MGLAttributionInfoStyleShort = 1
Swift
case short = 1
-
MGLAttributionInfoStyleMedium
Specifies a medium attribution info style.
Declaration
Objective-C
MGLAttributionInfoStyleMedium
Swift
case medium = 2
-
MGLAttributionInfoStyleLong
Specifies a long attribution info style.
Declaration
Objective-C
MGLAttributionInfoStyleLong
Swift
case long = 3
MGLCirclePitchAlignment
enum MGLCirclePitchAlignment : NSUInteger {}
Orientation of circle when map is pitched.
Values of this type are used in the MGLCircleStyleLayer.circlePitchAlignment
property.
-
MGLCirclePitchAlignmentMap
The circle is aligned to the plane of the map.
Declaration
Objective-C
MGLCirclePitchAlignmentMap
Swift
case map = 0
-
MGLCirclePitchAlignmentViewport
The circle is aligned to the plane of the viewport.
Declaration
Objective-C
MGLCirclePitchAlignmentViewport
Swift
case viewport = 1
MGLCircleScaleAlignment
enum MGLCircleScaleAlignment : NSUInteger {}
Controls the scaling behavior of the circle when the map is pitched.
Values of this type are used in the MGLCircleStyleLayer.circleScaleAlignment
property.
-
MGLCircleScaleAlignmentMap
Circles are scaled according to their apparent distance to the camera.
Declaration
Objective-C
MGLCircleScaleAlignmentMap
Swift
case map = 0
-
MGLCircleScaleAlignmentViewport
Circles are not scaled.
Declaration
Objective-C
MGLCircleScaleAlignmentViewport
Swift
case viewport = 1
MGLCircleTranslationAnchor
enum MGLCircleTranslationAnchor : NSUInteger {}
Controls the frame of reference for MGLCircleStyleLayer.circleTranslation
.
Values of this type are used in the MGLCircleStyleLayer.circleTranslationAnchor
property.
-
MGLCircleTranslationAnchorMap
The circle is translated relative to the map.
Declaration
Objective-C
MGLCircleTranslationAnchorMap
Swift
case map = 0
-
MGLCircleTranslationAnchorViewport
The circle is translated relative to the viewport.
Declaration
Objective-C
MGLCircleTranslationAnchorViewport
Swift
case viewport = 1
MGLDEMEncoding
enum MGLDEMEncoding : NSUInteger {}
The encoding formula used to generate the raster-dem tileset
-
MGLDEMEncodingMapbox
Raster tiles generated with the Mapbox encoding formula.
Declaration
Objective-C
MGLDEMEncodingMapbox = 0
Swift
case mapbox = 0
-
MGLDEMEncodingTerrarium
Raster tiles generated with the Mapzen Terrarium encoding formula.
Declaration
Objective-C
MGLDEMEncodingTerrarium
Swift
case terrarium = 1
MGLErrorCode
enum MGLErrorCode : NSInteger {}
Error constants for the Mapbox SDK.
-
MGLErrorCodeUnknown
An unknown error occurred.
Declaration
Objective-C
MGLErrorCodeUnknown = -1
Swift
case unknown = -1
-
MGLErrorCodeNotFound
The resource could not be found.
Declaration
Objective-C
MGLErrorCodeNotFound = 1
Swift
case notFound = 1
-
MGLErrorCodeBadServerResponse
The connection received an invalid server response.
Declaration
Objective-C
MGLErrorCodeBadServerResponse = 2
Swift
case badServerResponse = 2
-
MGLErrorCodeConnectionFailed
An attempt to establish a connection failed.
Declaration
Objective-C
MGLErrorCodeConnectionFailed = 3
Swift
case connectionFailed = 3
-
MGLErrorCodeParseStyleFailed
A style parse error occurred while attempting to load the map.
Declaration
Objective-C
MGLErrorCodeParseStyleFailed = 4
Swift
case parseStyleFailed = 4
-
MGLErrorCodeLoadStyleFailed
An attempt to load the style failed.
Declaration
Objective-C
MGLErrorCodeLoadStyleFailed = 5
Swift
case loadStyleFailed = 5
-
MGLErrorCodeSnapshotFailed
An error occurred while snapshotting the map.
Declaration
Objective-C
MGLErrorCodeSnapshotFailed = 6
Swift
case snapshotFailed = 6
-
MGLErrorCodeSourceIsInUseCannotRemove
Source is in use and cannot be removed
Declaration
Objective-C
MGLErrorCodeSourceIsInUseCannotRemove = 7
Swift
case sourceIsInUseCannotRemove = 7
-
MGLErrorCodeSourceIdentifierMismatch
Source is in use and cannot be removed
Declaration
Objective-C
MGLErrorCodeSourceIdentifierMismatch = 8
Swift
case sourceIdentifierMismatch = 8
-
MGLErrorCodeModifyingOfflineStorageFailed
An error occurred while modifying the offline storage database
Declaration
Objective-C
MGLErrorCodeModifyingOfflineStorageFailed = 9
Swift
case modifyingOfflineStorageFailed = 9
-
MGLErrorCodeSourceCannotBeRemovedFromStyle
Source is invalid and cannot be removed from the style (e.g. after a style change)
Declaration
Objective-C
MGLErrorCodeSourceCannotBeRemovedFromStyle = 10
Swift
case sourceCannotBeRemovedFromStyle = 10
-
MGLErrorCodeRenderingError
An error occurred while rendering
Declaration
Objective-C
MGLErrorCodeRenderingError = 11
Swift
case renderingError = 11
MGLFillExtrusionTranslationAnchor
enum MGLFillExtrusionTranslationAnchor : NSUInteger {}
Controls the frame of reference for
MGLFillExtrusionStyleLayer.fillExtrusionTranslation
.
Values of this type are used in the MGLFillExtrusionStyleLayer.fillExtrusionTranslationAnchor
property.
-
MGLFillExtrusionTranslationAnchorMap
The fill extrusion is translated relative to the map.
Declaration
Objective-C
MGLFillExtrusionTranslationAnchorMap
Swift
case map = 0
-
MGLFillExtrusionTranslationAnchorViewport
The fill extrusion is translated relative to the viewport.
Declaration
Objective-C
MGLFillExtrusionTranslationAnchorViewport
Swift
case viewport = 1
MGLFillTranslationAnchor
enum MGLFillTranslationAnchor : NSUInteger {}
Controls the frame of reference for MGLFillStyleLayer.fillTranslation
.
Values of this type are used in the MGLFillStyleLayer.fillTranslationAnchor
property.
-
MGLFillTranslationAnchorMap
The fill is translated relative to the map.
Declaration
Objective-C
MGLFillTranslationAnchorMap
Swift
case map = 0
-
MGLFillTranslationAnchorViewport
The fill is translated relative to the viewport.
Declaration
Objective-C
MGLFillTranslationAnchorViewport
Swift
case viewport = 1
MGLHillshadeIlluminationAnchor
enum MGLHillshadeIlluminationAnchor : NSUInteger {}
Direction of light source when map is rotated.
Values of this type are used in the MGLHillshadeStyleLayer.hillshadeIlluminationAnchor
property.
-
MGLHillshadeIlluminationAnchorMap
The hillshade illumination is relative to the north direction.
Declaration
Objective-C
MGLHillshadeIlluminationAnchorMap
Swift
case map = 0
-
MGLHillshadeIlluminationAnchorViewport
The hillshade illumination is relative to the top of the viewport.
Declaration
Objective-C
MGLHillshadeIlluminationAnchorViewport
Swift
case viewport = 1
MGLIconAnchor
enum MGLIconAnchor : NSUInteger {}
Part of the icon placed closest to the anchor.
Values of this type are used in the MGLSymbolStyleLayer.iconAnchor
property.
-
MGLIconAnchorCenter
The center of the icon is placed closest to the anchor.
Declaration
Objective-C
MGLIconAnchorCenter
Swift
case center = 0
-
MGLIconAnchorLeft
The left side of the icon is placed closest to the anchor.
Declaration
Objective-C
MGLIconAnchorLeft
Swift
case left = 1
-
MGLIconAnchorRight
The right side of the icon is placed closest to the anchor.
Declaration
Objective-C
MGLIconAnchorRight
Swift
case right = 2
-
MGLIconAnchorTop
The top of the icon is placed closest to the anchor.
Declaration
Objective-C
MGLIconAnchorTop
Swift
case top = 3
-
MGLIconAnchorBottom
The bottom of the icon is placed closest to the anchor.
Declaration
Objective-C
MGLIconAnchorBottom
Swift
case bottom = 4
-
MGLIconAnchorTopLeft
The top left corner of the icon is placed closest to the anchor.
Declaration
Objective-C
MGLIconAnchorTopLeft
Swift
case topLeft = 5
-
MGLIconAnchorTopRight
The top right corner of the icon is placed closest to the anchor.
Declaration
Objective-C
MGLIconAnchorTopRight
Swift
case topRight = 6
-
MGLIconAnchorBottomLeft
The bottom left corner of the icon is placed closest to the anchor.
Declaration
Objective-C
MGLIconAnchorBottomLeft
Swift
case bottomLeft = 7
-
MGLIconAnchorBottomRight
The bottom right corner of the icon is placed closest to the anchor.
Declaration
Objective-C
MGLIconAnchorBottomRight
Swift
case bottomRight = 8
MGLIconPitchAlignment
enum MGLIconPitchAlignment : NSUInteger {}
Orientation of icon when map is pitched.
Values of this type are used in the MGLSymbolStyleLayer.iconPitchAlignment
property.
-
MGLIconPitchAlignmentMap
The icon is aligned to the plane of the map.
Declaration
Objective-C
MGLIconPitchAlignmentMap
Swift
case map = 0
-
MGLIconPitchAlignmentViewport
The icon is aligned to the plane of the viewport.
Declaration
Objective-C
MGLIconPitchAlignmentViewport
Swift
case viewport = 1
-
MGLIconPitchAlignmentAuto
Automatically matches the value of
MGLSymbolStyleLayer.iconRotationAlignment
.Declaration
Objective-C
MGLIconPitchAlignmentAuto
Swift
case auto = 2
MGLIconRotationAlignment
enum MGLIconRotationAlignment : NSUInteger {}
In combination with MGLSymbolStyleLayer.symbolPlacement
, determines the
rotation behavior of icons.
Values of this type are used in the MGLSymbolStyleLayer.iconRotationAlignment
property.
-
MGLIconRotationAlignmentMap
When
symbolPlacement
is set toMGLSymbolPlacementPoint
, aligns icons east-west. WhensymbolPlacement
is set toMGLSymbolPlacementLine
orMGLSymbolPlacementLineCenter
, aligns icon x-axes with the line.Declaration
Objective-C
MGLIconRotationAlignmentMap
Swift
case map = 0
-
MGLIconRotationAlignmentViewport
Produces icons whose x-axes are aligned with the x-axis of the viewport, regardless of the value of
MGLSymbolStyleLayer.symbolPlacement
.Declaration
Objective-C
MGLIconRotationAlignmentViewport
Swift
case viewport = 1
-
MGLIconRotationAlignmentAuto
When
symbolPlacement
is set toMGLSymbolPlacementPoint
, this is equivalent toMGLIconRotationAlignmentViewport
. WhensymbolPlacement
is set toMGLSymbolPlacementLine
orMGLSymbolPlacementLineCenter
, this is equivalent toMGLIconRotationAlignmentMap
.Declaration
Objective-C
MGLIconRotationAlignmentAuto
Swift
case auto = 2
MGLIconTextFit
enum MGLIconTextFit : NSUInteger {}
The directions in which the icon stretches to fit around the text. If the icon image is a resizable image, the resizable areas may be stretched, while the cap insets are always drawn at the original scale.
Values of this type are used in the MGLSymbolStyleLayer.iconTextFit
property.
-
MGLIconTextFitNone
The icon is displayed at its intrinsic aspect ratio.
Declaration
Objective-C
MGLIconTextFitNone
Swift
case none = 0
-
MGLIconTextFitWidth
The icon is scaled in the x-dimension to fit the width of the text.
Declaration
Objective-C
MGLIconTextFitWidth
Swift
case width = 1
-
MGLIconTextFitHeight
The icon is scaled in the y-dimension to fit the height of the text.
Declaration
Objective-C
MGLIconTextFitHeight
Swift
case height = 2
-
MGLIconTextFitBoth
The icon is scaled in both x- and y-dimensions.
Declaration
Objective-C
MGLIconTextFitBoth
Swift
case both = 3
MGLIconTranslationAnchor
enum MGLIconTranslationAnchor : NSUInteger {}
Controls the frame of reference for MGLSymbolStyleLayer.iconTranslation
.
Values of this type are used in the MGLSymbolStyleLayer.iconTranslationAnchor
property.
-
MGLIconTranslationAnchorMap
Icons are translated relative to the map.
Declaration
Objective-C
MGLIconTranslationAnchorMap
Swift
case map = 0
-
MGLIconTranslationAnchorViewport
Icons are translated relative to the viewport.
Declaration
Objective-C
MGLIconTranslationAnchorViewport
Swift
case viewport = 1
MGLLightAnchor
enum MGLLightAnchor : NSUInteger {}
Whether extruded geometries are lit relative to the map or viewport.
-
MGLLightAnchorMap
The position of the light source is aligned to the rotation of the map.
Declaration
Objective-C
MGLLightAnchorMap
Swift
case map = 0
-
MGLLightAnchorViewport
The position of the light source is aligned to the rotation of the viewport.
Declaration
Objective-C
MGLLightAnchorViewport
Swift
case viewport = 1
MGLLineCap
enum MGLLineCap : NSUInteger {}
The display of line endings.
Values of this type are used in the MGLLineStyleLayer.lineCap
property.
-
MGLLineCapButt
A cap with a squared-off end which is drawn to the exact endpoint of the line.
Declaration
Objective-C
MGLLineCapButt
Swift
case butt = 0
-
MGLLineCapRound
A cap with a rounded end which is drawn beyond the endpoint of the line at a radius of one-half of the line’s width and centered on the endpoint of the line.
Declaration
Objective-C
MGLLineCapRound
Swift
case round = 1
-
MGLLineCapSquare
A cap with a squared-off end which is drawn beyond the endpoint of the line at a distance of one-half of the line’s width.
Declaration
Objective-C
MGLLineCapSquare
Swift
case square = 2
MGLLineJoin
enum MGLLineJoin : NSUInteger {}
The display of lines when joining.
Values of this type are used in the MGLLineStyleLayer.lineJoin
property.
-
MGLLineJoinBevel
A join with a squared-off end which is drawn beyond the endpoint of the line at a distance of one-half of the line’s width.
Declaration
Objective-C
MGLLineJoinBevel
Swift
case bevel = 0
-
MGLLineJoinRound
A join with a rounded end which is drawn beyond the endpoint of the line at a radius of one-half of the line’s width and centered on the endpoint of the line.
Declaration
Objective-C
MGLLineJoinRound
Swift
case round = 1
-
MGLLineJoinMiter
A join with a sharp, angled corner which is drawn with the outer sides beyond the endpoint of the path until they meet.
Declaration
Objective-C
MGLLineJoinMiter
Swift
case miter = 2
MGLLineTranslationAnchor
enum MGLLineTranslationAnchor : NSUInteger {}
Controls the frame of reference for MGLLineStyleLayer.lineTranslation
.
Values of this type are used in the MGLLineStyleLayer.lineTranslationAnchor
property.
-
MGLLineTranslationAnchorMap
The line is translated relative to the map.
Declaration
Objective-C
MGLLineTranslationAnchorMap
Swift
case map = 0
-
MGLLineTranslationAnchorViewport
The line is translated relative to the viewport.
Declaration
Objective-C
MGLLineTranslationAnchorViewport
Swift
case viewport = 1
MGLLoggingLevel
enum MGLLoggingLevel : NSInteger {}
Constants indicating the message’s logging level.
-
MGLLoggingLevelNone
None-level won’t print any messages.
Declaration
Objective-C
MGLLoggingLevelNone = 0
Swift
case none = 0
-
MGLLoggingLevelFault
Fault-level messages contain system-level error information.
Declaration
Objective-C
MGLLoggingLevelFault
Swift
case fault = 1
-
MGLLoggingLevelError
Error-level messages contain information that is intended to aid in process-level errors.
Declaration
Objective-C
MGLLoggingLevelError
Swift
case error = 2
-
MGLLoggingLevelWarning
Warning-level messages contain warning information for potential risks.
Declaration
Objective-C
MGLLoggingLevelWarning
Swift
case warning = 3
-
MGLLoggingLevelInfo
Info-level messages contain information that may be helpful for flow tracing but is not essential.
Declaration
Objective-C
MGLLoggingLevelInfo
Swift
case info = 4
-
MGLLoggingLevelVerbose
Verbose-level will print all messages.
Declaration
Objective-C
MGLLoggingLevelVerbose
Swift
case verbose = 6
MGLMapDebugMaskOptions
enum MGLMapDebugMaskOptions : NSUInteger {}
Options for enabling debugging features in an MGLMapView
instance.
-
MGLMapDebugTileBoundariesMask
Edges of tile boundaries are shown as thick, red lines to help diagnose tile clipping issues.
Declaration
Objective-C
MGLMapDebugTileBoundariesMask = 1 << 1
Swift
static var tileBoundariesMask: MGLMapDebugMaskOptions { get }
-
MGLMapDebugTileInfoMask
Each tile shows its tile coordinate (x/y/z) in the upper-left corner.
Declaration
Objective-C
MGLMapDebugTileInfoMask = 1 << 2
Swift
static var tileInfoMask: MGLMapDebugMaskOptions { get }
-
MGLMapDebugTimestampsMask
Each tile shows a timestamp indicating when it was loaded.
Declaration
Objective-C
MGLMapDebugTimestampsMask = 1 << 3
Swift
static var timestampsMask: MGLMapDebugMaskOptions { get }
-
MGLMapDebugCollisionBoxesMask
Edges of glyphs and symbols are shown as faint, green lines to help diagnose collision and label placement issues.
Declaration
Objective-C
MGLMapDebugCollisionBoxesMask = 1 << 4
Swift
static var collisionBoxesMask: MGLMapDebugMaskOptions { get }
-
MGLMapDebugOverdrawVisualizationMask
Each drawing operation is replaced by a translucent fill. Overlapping drawing operations appear more prominent to help diagnose overdrawing. - note: This option does nothing in Release builds of the SDK.
Declaration
Objective-C
MGLMapDebugOverdrawVisualizationMask = 1 << 5
Swift
static var overdrawVisualizationMask: MGLMapDebugMaskOptions { get }
MGLOrnamentPosition
enum MGLOrnamentPosition : NSUInteger {}
The position of scale bar, compass, logo and attribution in a map view. Used with
MGLMapView.scaleBarPosition
,
MGLMapView.compassViewPosition
,
MGLMapView.logoViewPosition
,
MGLMapView.attributionButtonPosition
.
-
MGLOrnamentPositionTopLeft
Place the ornament in the top left of the map view.
Declaration
Objective-C
MGLOrnamentPositionTopLeft = 0
Swift
case topLeft = 0
-
MGLOrnamentPositionTopRight
Place the ornament in the top right of the map view.
Declaration
Objective-C
MGLOrnamentPositionTopRight
Swift
case topRight = 1
-
MGLOrnamentPositionBottomLeft
Place the ornament in the bottom left of the map view.
Declaration
Objective-C
MGLOrnamentPositionBottomLeft
Swift
case bottomLeft = 2
-
MGLOrnamentPositionBottomRight
Place the ornament in the bottom right of the map view.
Declaration
Objective-C
MGLOrnamentPositionBottomRight
Swift
case bottomRight = 3
MGLOrnamentVisibility
enum MGLOrnamentVisibility : NSInteger {}
Constants indicating the visibility of different map ornaments.
-
MGLOrnamentVisibilityAdaptive
A constant indicating that the ornament adapts to the current map state.
Declaration
Objective-C
MGLOrnamentVisibilityAdaptive
Swift
case adaptive = 0
-
MGLOrnamentVisibilityHidden
A constant indicating that the ornament is always hidden.
Declaration
Objective-C
MGLOrnamentVisibilityHidden
Swift
case hidden = 1
-
MGLOrnamentVisibilityVisible
A constant indicating that the ornament is always visible.
Declaration
Objective-C
MGLOrnamentVisibilityVisible
Swift
case visible = 2
MGLRasterResamplingMode
enum MGLRasterResamplingMode : NSUInteger {}
The resampling/interpolation method to use for overscaling, also known as texture magnification filter
Values of this type are used in the MGLRasterStyleLayer.rasterResamplingMode
property.
-
MGLRasterResamplingModeLinear
(Bi)linear filtering interpolates point values using the weighted average of the four closest original source points creating a smooth but blurry look when overscaled
Declaration
Objective-C
MGLRasterResamplingModeLinear
Swift
case linear = 0
-
MGLRasterResamplingModeNearest
Nearest neighbor filtering interpolates point values using the nearest original source point creating a sharp but pointated look when overscaled
Declaration
Objective-C
MGLRasterResamplingModeNearest
Swift
case nearest = 1
MGLResourceKind
enum MGLResourceKind : NSUInteger {}
The type of resource that is requested.
-
MGLResourceKindUnknown
Unknown type
Declaration
Objective-C
MGLResourceKindUnknown
Swift
case unknown = 0
-
MGLResourceKindStyle
Style sheet JSON file
Declaration
Objective-C
MGLResourceKindStyle
Swift
case style = 1
-
MGLResourceKindSource
TileJSON file as specified in https://maplibre.org/maplibre-gl-js-docs/style-spec/#root-sources
Declaration
Objective-C
MGLResourceKindSource
Swift
case source = 2
-
MGLResourceKindTile
A vector or raster tile as described in the style sheet at https://maplibre.org/maplibre-gl-js-docs/style-spec/#sources
Declaration
Objective-C
MGLResourceKindTile
Swift
case tile = 3
-
MGLResourceKindGlyphs
Signed distance field glyphs for text rendering. These are the URLs specified in the style in https://maplibre.org/maplibre-gl-js-docs/style-spec/#root-glyphs
Declaration
Objective-C
MGLResourceKindGlyphs
Swift
case glyphs = 4
-
MGLResourceKindSpriteImage
Image part of a sprite sheet. It is constructed of the prefix in https://maplibre.org/maplibre-gl-js-docs/style-spec/#root-sprite and a PNG file extension.
Declaration
Objective-C
MGLResourceKindSpriteImage
Swift
case spriteImage = 5
-
MGLResourceKindSpriteJSON
JSON part of a sprite sheet. It is constructed of the prefix in https://maplibre.org/maplibre-gl-js-docs/style-spec/#root-sprite and a JSON file extension.
Declaration
Objective-C
MGLResourceKindSpriteJSON
Swift
case spriteJSON = 6
-
MGLResourceKindImage
Image data for a georeferenced image source. *
Declaration
Objective-C
MGLResourceKindImage
Swift
case image = 7
MGLSymbolPlacement
enum MGLSymbolPlacement : NSUInteger {}
Label placement relative to its geometry.
Values of this type are used in the MGLSymbolStyleLayer.symbolPlacement
property.
-
MGLSymbolPlacementPoint
The label is placed at the point where the geometry is located.
Declaration
Objective-C
MGLSymbolPlacementPoint
Swift
case point = 0
-
MGLSymbolPlacementLine
The label is placed along the line of the geometry. Can only be used on
LineString
andPolygon
geometries.Declaration
Objective-C
MGLSymbolPlacementLine
Swift
case line = 1
-
MGLSymbolPlacementLineCenter
The label is placed at the center of the line of the geometry. Can only be used on
LineString
andPolygon
geometries. Note that a single feature in a vector tile may contain multiple line geometries.Declaration
Objective-C
MGLSymbolPlacementLineCenter
Swift
case lineCenter = 2
MGLSymbolZOrder
enum MGLSymbolZOrder : NSUInteger {}
Controls the order in which overlapping symbols in the same layer are rendered
Values of this type are used in the MGLSymbolStyleLayer.symbolZOrder
property.
-
MGLSymbolZOrderAuto
If
MGLSymbolStyleLayer.symbolSortKey
is set, sort based on that. Otherwise sort symbols by their y-position relative to the viewport.Declaration
Objective-C
MGLSymbolZOrderAuto
Swift
case auto = 0
-
MGLSymbolZOrderViewportY
Specify this z order if symbols’ appearance relies on lower features overlapping higher features. For example, symbols with a pin-like appearance would require this z order.
Declaration
Objective-C
MGLSymbolZOrderViewportY
Swift
case viewportY = 1
-
MGLSymbolZOrderSource
Specify this z order if the order in which features appear in the source is significant.
Declaration
Objective-C
MGLSymbolZOrderSource
Swift
case source = 2
MGLTextAnchor
enum MGLTextAnchor : NSUInteger {}
Part of the text placed closest to the anchor.
Values of this type are used in the MGLSymbolStyleLayer.textAnchor
property.
-
MGLTextAnchorCenter
The center of the text is placed closest to the anchor.
Declaration
Objective-C
MGLTextAnchorCenter
Swift
case center = 0
-
MGLTextAnchorLeft
The left side of the text is placed closest to the anchor.
Declaration
Objective-C
MGLTextAnchorLeft
Swift
case left = 1
-
MGLTextAnchorRight
The right side of the text is placed closest to the anchor.
Declaration
Objective-C
MGLTextAnchorRight
Swift
case right = 2
-
MGLTextAnchorTop
The top of the text is placed closest to the anchor.
Declaration
Objective-C
MGLTextAnchorTop
Swift
case top = 3
-
MGLTextAnchorBottom
The bottom of the text is placed closest to the anchor.
Declaration
Objective-C
MGLTextAnchorBottom
Swift
case bottom = 4
-
MGLTextAnchorTopLeft
The top left corner of the text is placed closest to the anchor.
Declaration
Objective-C
MGLTextAnchorTopLeft
Swift
case topLeft = 5
-
MGLTextAnchorTopRight
The top right corner of the text is placed closest to the anchor.
Declaration
Objective-C
MGLTextAnchorTopRight
Swift
case topRight = 6
-
MGLTextAnchorBottomLeft
The bottom left corner of the text is placed closest to the anchor.
Declaration
Objective-C
MGLTextAnchorBottomLeft
Swift
case bottomLeft = 7
-
MGLTextAnchorBottomRight
The bottom right corner of the text is placed closest to the anchor.
Declaration
Objective-C
MGLTextAnchorBottomRight
Swift
case bottomRight = 8
MGLTextJustification
enum MGLTextJustification : NSUInteger {}
Text justification options.
Values of this type are used in the MGLSymbolStyleLayer.textJustification
property.
-
MGLTextJustificationAuto
The text is aligned towards the anchor position.
Declaration
Objective-C
MGLTextJustificationAuto
Swift
case auto = 0
-
MGLTextJustificationLeft
The text is aligned to the left.
Declaration
Objective-C
MGLTextJustificationLeft
Swift
case left = 1
-
MGLTextJustificationCenter
The text is centered.
Declaration
Objective-C
MGLTextJustificationCenter
Swift
case center = 2
-
MGLTextJustificationRight
The text is aligned to the right.
Declaration
Objective-C
MGLTextJustificationRight
Swift
case right = 3
MGLTextPitchAlignment
enum MGLTextPitchAlignment : NSUInteger {}
Orientation of text when map is pitched.
Values of this type are used in the MGLSymbolStyleLayer.textPitchAlignment
property.
-
MGLTextPitchAlignmentMap
The text is aligned to the plane of the map.
Declaration
Objective-C
MGLTextPitchAlignmentMap
Swift
case map = 0
-
MGLTextPitchAlignmentViewport
The text is aligned to the plane of the viewport.
Declaration
Objective-C
MGLTextPitchAlignmentViewport
Swift
case viewport = 1
-
MGLTextPitchAlignmentAuto
Automatically matches the value of
MGLSymbolStyleLayer.textRotationAlignment
.Declaration
Objective-C
MGLTextPitchAlignmentAuto
Swift
case auto = 2
MGLTextRotationAlignment
enum MGLTextRotationAlignment : NSUInteger {}
In combination with MGLSymbolStyleLayer.symbolPlacement
, determines the
rotation behavior of the individual glyphs forming the text.
Values of this type are used in the MGLSymbolStyleLayer.textRotationAlignment
property.
-
MGLTextRotationAlignmentMap
When
symbolPlacement
is set toMGLSymbolPlacementPoint
, aligns text east-west. WhensymbolPlacement
is set toMGLSymbolPlacementLine
orMGLSymbolPlacementLineCenter
, aligns text x-axes with the line.Declaration
Objective-C
MGLTextRotationAlignmentMap
Swift
case map = 0
-
MGLTextRotationAlignmentViewport
Produces glyphs whose x-axes are aligned with the x-axis of the viewport, regardless of the value of
MGLSymbolStyleLayer.symbolPlacement
.Declaration
Objective-C
MGLTextRotationAlignmentViewport
Swift
case viewport = 1
-
MGLTextRotationAlignmentAuto
When
symbolPlacement
is set toMGLSymbolPlacementPoint
, this is equivalent toMGLTextRotationAlignmentViewport
. WhensymbolPlacement
is set toMGLSymbolPlacementLine
orMGLSymbolPlacementLineCenter
, this is equivalent toMGLTextRotationAlignmentMap
.Declaration
Objective-C
MGLTextRotationAlignmentAuto
Swift
case auto = 2
MGLTextTransform
enum MGLTextTransform : NSUInteger {}
Specifies how to capitalize text.
Values of this type are used in the MGLSymbolStyleLayer.textTransform
property.
-
MGLTextTransformNone
The text is not altered.
Declaration
Objective-C
MGLTextTransformNone
Swift
case none = 0
-
MGLTextTransformUppercase
Forces all letters to be displayed in uppercase.
Declaration
Objective-C
MGLTextTransformUppercase
Swift
case uppercase = 1
-
MGLTextTransformLowercase
Forces all letters to be displayed in lowercase.
Declaration
Objective-C
MGLTextTransformLowercase
Swift
case lowercase = 2
MGLTextTranslationAnchor
enum MGLTextTranslationAnchor : NSUInteger {}
Controls the frame of reference for MGLSymbolStyleLayer.textTranslation
.
Values of this type are used in the MGLSymbolStyleLayer.textTranslationAnchor
property.
-
MGLTextTranslationAnchorMap
The text is translated relative to the map.
Declaration
Objective-C
MGLTextTranslationAnchorMap
Swift
case map = 0
-
MGLTextTranslationAnchorViewport
The text is translated relative to the viewport.
Declaration
Objective-C
MGLTextTranslationAnchorViewport
Swift
case viewport = 1
MGLTextWritingMode
enum MGLTextWritingMode : NSUInteger {}
The property allows control over a symbol’s orientation. Note that the property values act as a hint, so that a symbol whose language doesn’t support the provided orientation will be laid out in its natural orientation. Example: English point symbol will be rendered horizontally even if array value contains single ‘vertical’ enum value. The order of elements in an array define priority order for the placement of an orientation variant.
Values of this type are used in the MGLSymbolStyleLayer.textWritingModes
property.
-
MGLTextWritingModeHorizontal
If a text’s language supports horizontal writing mode, symbols with point placement would be laid out horizontally.
Declaration
Objective-C
MGLTextWritingModeHorizontal
Swift
case horizontal = 0
-
MGLTextWritingModeVertical
If a text’s language supports vertical writing mode, symbols with point placement would be laid out vertically.
Declaration
Objective-C
MGLTextWritingModeVertical
Swift
case vertical = 1
MGLTileCoordinateSystem
enum MGLTileCoordinateSystem : NSUInteger {}
Tile coordinate systems that determine how tile coordinates in tile URLs are interpreted.
-
MGLTileCoordinateSystemXYZ
The origin is at the top-left (northwest), and
y
values increase southwards.This tile coordinate system is used by Mapbox and OpenStreetMap tile servers.
Declaration
Objective-C
MGLTileCoordinateSystemXYZ = 0
Swift
case XYZ = 0
-
MGLTileCoordinateSystemTMS
The origin is at the bottom-left (southwest), and
y
values increase northwards.This tile coordinate system is used by tile servers that conform to the Tile Map Service Specification.
Declaration
Objective-C
MGLTileCoordinateSystemTMS
Swift
case TMS = 1
MGLWellKnownTileServer
enum MGLWellKnownTileServer : NSUInteger {}
Well-known tile servers
-
MGLMapTiler
-
MGLMapLibre
-
MGLMapbox