The visual representation for any polyline overlay object.


class MKPolylineRenderer : MKOverlayPathRenderer


This renderer strokes the line only; it does not fill it. You can change the color and other drawing attributes of the polyline by modifying the properties inherited from the parent class. You typically use this class as is and do not subclass it.


Creating a Polyline Renderer

init(polyline: MKPolyline)

Initializes and returns a new overlay view using the specified polyline overlay object

Accessing the Polyline Overlay

var polyline: MKPolyline

The polyline overlay object that contains the information used to draw the overlay.


Conforms To

See Also


class MKPolyline

A shape consisting of one or more connected line segments.

class MKGeodesicPolyline

A line-based shape that follows the contours of the Earth to create the shortest path between the specified points.

class MKMultiPolyline

A collection of multipolyline shapes, each consisting of one or more connected line segments.

class MKMultiPolylineRenderer

The visual representation for multiple polyline objects.